proc catalog cat=work.sasmacr;contents;run;
Contents of Catalog Work.SASMacr
# Name Type Create Date Modified Date Description
1 LOWCASE MACRO 12Sep10:10:36:57 12Sep10:10:36:57 C:SASv9sasdev
mva-v930shellauto
MAUTOSOURCE System Option
Specifies whether the autocall feature is available.
Valid in: Configuration file, OPTIONS window, OPTIONS statement, SAS invocation
Category: Macro
PROC OPTIONS
GROUP=
MACRO
Type: System option
Default: MAUTOSOURCE
Syntax
MAUTOSOURCE | NOMAUTOSOURCE
Required Arguments
MAUTOSOURCE
causes the macro processor to search the autocall libraries for a member with the
requested name when a macro name is not found in the Work library.
NOMAUTOSOURCE
prevents the macro processor from searching the autocall libraries when a macro
name is not found in the Work library.
Details
When the macro facility searches for macros, it searches first for macros compiled in the
current SAS session. If the MSTORED option is in effect, the macro facility next
searches the libraries containing compiled stored macros. If the MAUTOSOURCE
option is in effect, the macro facility next searches the autocall libraries.
MCOMPILE System Option
Specifies whether to allow new definitions of macros.
Valid in: Configuration file, OPTIONS window, OPTIONS statement, SAS invocation
Category: Macro
PROC OPTIONS
GROUP=
MACRO
MCOMPILE System Option 359
Type: System option
Default: MCOMPILE
Syntax
MCOMPILE | NOMCOMPILE
Required Arguments
MCOMPILE
allows new macro definitions.
NOMCOMPILE
disallows new macro definitions.
Details
The MCOMPILE system option allows new definitions of macros.
The NOMCOMPILE system option prevents new definitions of macros. It does not
prevent the use of existing stored compiled or autocall macros.
MCOMPILENOTE System Option
Issues a NOTE to the SAS log. The note contains the size and number of instructions upon the completion
of the compilation of a macro.
Valid in: Configuration file, OPTIONS window, OPTIONS statement, SAS invocation
Category: Macro
PROC OPTIONS
GROUP=
MACRO
Type: System option
Default: NONE
Syntax
MCOMPILENOTE=NONE | NOAUTOCALL | ALL
Required Arguments
NONE
prevents any NOTE from being written to the log.
NOAUTOCALL
prevents any NOTE from being written to the log for AUTOCALL macros, but does
issue a NOTE to the log upon the completion of the compilation of any other macro.
ALL
issues a NOTE to the log. The note contains the size and number of instructions upon
the completion of the compilation of any macro.
360 Chapter 20 System Options for Macros
Details
The NOTE confirms that the compilation of the macro was completed. When the option
is on and the NOTE is issued, the compiled version of the macro is available for
execution. A macro can successfully compile, but still contain errors or warnings that
will cause the macro to not execute as you intended.
Example: Using MCOMPILENOTE System Option
A macro can actually compile and still contain errors. Here is an example of the NOTE
without errors:
option mcompilenote=noautocall;
%macro mymacro;
%mend mymacro;
Output to the log:
NOTE: The macro MYMACRO completed compilation without errors.
Here is an example of the NOTE with errors:
%macro yourmacro;
%end;
%mend yourmacro;
Output to the log:
ERROR: There is no matching %DO statement for the %END statement.
This statement will be ignored.
NOTE: The macro YOURMACRO completed compilation with errors.
MCOVERAGE System Options
Enables the generation of coverage analysis data.
Valid in: Configuration file, OPTIONS window, OPTIONS statement, SAS invocation
Category: Macro
PROC OPTIONS
GROUP=
Macro
Type: System option
Default: NOMCOVERAGE
Requirement: Must use MCOVERAGELOC= system option
Syntax
MCOVERAGE | NOMCOVERAGE
Required Arguments
MCOVERAGE
enables the generation of coverage analysis data.
NOMCOVERAGE
prevents the generation of coverage analysis data.
MCOVERAGE System Options 361
Details
MCOVERAGE system option controls the generation of coverage analysis data, which
is information needed to ensure proper testing of SAS Solutions products before their
release.
The format of the coverage analysis data is a space delimited flat text file that contains
three types of records. Each record begins with a numeric record type. The line numbers
in the data are relative line numbers based on the %MACRO keyword used to define the
macro. You must use the MCOVERAGELOC= system option to specify the location of
the coverage analysis data file. See “MCOVERAGELOC= System Option” on page 365.
Note: Because nested macro definitions are stored as model text with line breaks
collapsed, it is recommended that nested macro definitions not be used in macro
definitions that will later be analyzed for execution coverage.
Below are explanations for each of the three record types.
Record type 1:
1 n n macroname
1
record type
n
first line number
n
last line number
macroname
macro name
Record type 1 indicates the beginning of the execution of a macro. Record type 1
appears once for each invocation of a macro.
Record type 2:
2 n n macroname
2
record type
n
first line number
n
last line number
macroname
macro name
Record type 2 indicates the lines of a macro that have executed. A single line of a macro
might cause more than one record to be generated.
Record type 3:
3 n n macroname
3
record type
n
first line number
n
last line number
362 Chapter 20 System Options for Macros
macroname
macro name
Record type 3 indicates which lines of the macro cannot be executed because no code
was generated from them. These lines might be either commentary lines or lines that
cause no macro code to be generated.
The following is a sample program log:
MCOVERAGE System Options 363
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset