The pragmas Metashell provides
Metashell provides a number of pragmas controlling the shell. Note that these
pragmas are available only from the shell's command prompt. If you put them in a
header file and include that header, these pragmas will be ignored.
The pragmas accepted by Metashell begin with #pragma metashell. Since this is
a long prefix to type, Metashell accepts shorter versions as well. Here is the
complete list of accepted forms. All of them are equivalent:
#pragma metashell#pragma msh#metashell#msh
Metashell supports the following pragmas:
-
#msh echo <text>
Display a comment containing. -
#msh environment
Displays the entire content of the environment. -
#msh environment add <code>
Appends code to the environment. Use this if Metashell thinks about the code that it is an evaluation. -
#msh environment pop
Pops the last environment from the environment stack. -
#msh environment push
Pushes the current environment to the environment stack. -
#msh environment reload
Re-reads the included header files from disc. -
#msh environment reset
Resets the environment to its initial state. It does not change the environment stack. -
#msh environment save <path>
Saves the environment into a file. This is disabled by default. It can be enabled using the --enable_saving command line argument. -
#msh environment stack
Displays the size of the environment stack. -
#msh evaluate <code>
Evaluates code as a metaprogram. Use this if Metashell thinks about the code that it is an addition to the environment. -
#msh help [<command>]
Displays a help message. -
#msh macro names
Displays the names of the defined macros -
#msh macros
Displays the macro definitions -
#msh mdb [-full] [<type>]
Starts the metadebugger. For more information see evaluate in the Metadebugger command reference. -
#msh metaprogram evaluation [on|1|off|0]
Turns evaluation of metaprograms on or off. When no arguments are used, it displays if evaluation of metaprograms is turned on. -
#msh metaprogram mode
Set Metashell to metaprogram mode -
#msh pp <exp>
Displays the preprocessed expression. -
#msh precompiled_headers [on|1|off|0]
Turns precompiled header usage on or off. When no arguments are used, it displays if precompiled header usage is turned on. -
#msh preprocessed echo [on|1|off|0]
Turns display preprocessed commands on or off. When no arguments are used, it displays if display preprocessed commands is turned on. -
#msh preprocessor mode
Set Metashell to preprocessor mode -
#msh quit
Terminates the shell. -
#msh show cpp_errors [on|1|off|0]
Turns display C++ errors on or off. When no arguments are used, it displays if display C++ errors is turned on. -
#msh verbose [on|1|off|0]
Turns verbose mode on or off. When no arguments are used, it displays if verbose mode is turned on.