Oracle® Solaris Studio 12.4: Debugging a Program With dbx

Exit Print View

Updated: January 2015
 
 

Relaxing the Scope Lookup Rules

To relax the scope lookup rules for static symbols and C++ member functions, set the dbxenv variable scope_look_aside to on:

dbxenv scope_look_aside on

You can also use the “double backquote” prefix:

stop in ``func4            func4 may be static and not in scope

    If the dbxenv variable scope_look_aside is set to on, dbx looks for the following:

  • Static variables defined in other files if not found in current scope. Files from libraries in /usr/lib are not searched.

  • C++ member functions without class qualification.

  • Instantiations of C++ inline member functions in other files if a member function is not instantiated in current file.

The which command tells you which symbol dbx would choose. In the case of ambiguous names, the overload display list indicates that dbx has not yet determined which occurrence of two or more names it would use. dbx lists the possibilities and waits for you to choose one.