Warning: The macro ‘{name}’ is defined in the body of method ‘{method}’, which only the methods compiled after it see
A #define in one method’s body is used from another method. IRIS compiles a class’s
methods in name order into one routine and keeps a body’s definitions for the rest of it,
so the macro reaches the methods after it alphabetically and no other, and renaming either
method changes what compiles. Define it in an include file the class Includes.
IRIS compiles the example.
Class Demo.MacroFromMethodBody
{
ClassMethod Greet() As %String
{
#define GREETING "Hello"
Quit $$$GREETING
}
ClassMethod Shout() As %String
{
Quit $$$GREETING_"!" //! A3904
}
}