Inspect Manual

Inspect Concepts
Inspect Manual429164-006
2-16
Code Locations
Code Locations
A code location is a symbolic reference to a specific location in the object code of a
program. Although the syntax used to specify a code location varies slightly for each
source language, the general syntax is the same for all languages.
scope-path
specifies the scope path to the scope unit containing the code location. When
used alone (the first option in the main syntax), scope-path specifies the primary
entry point of the last scope unit named in the scope path.
[ scope-path. ] code-reference
specifies a named or numbered location in the scope unit defined by the given
scope path (or the current scope path if no scope path is given). The exact form of
code-reference varies from language to language, but options shown in the
previous diagram are generally available.
scope-unit [ FROM source-file ]
specifies the primary entry point of the scope unit. scope-unitmust be the
same as the last scope unit named in scope-path (or in the current scope
path).
The FROM clause identifies the scope unit by the source file in which it is
found; therefore, Inspect can distinguish between scope units that have the
same name, but reside in different modules.
{ scope-path }
{ } [ code-offset [1] [2] [3]
{ [ scope-path. ] code-reference }
code-reference: one of
scope-unit [ FROM source-file ]
label [ FROM source-file ]
#line-number [ (source-file) ]
code-offset:
{ + | - } num-units [ code-unit ]
{ + | - } num-units [ code-unit ]
{ + | - } num-units [ code-unit ]
code-unit: one of
INSTRUCTION[S] STATEMENT[S] VERB[S]