Skip to main content

##lit

Preserves the content of its argument in literal form.

Description

This macro preprocessor function preserves the content of its argument in literal form:

##lit(content)

where content is a string that is valid ObjectScript expression. The ##lit preprocessor function ensures that the string it receives is not evaluated, but that it is treated as literal text.

For example, the following code:

 #define Macro1 "Row 1 Value"
 #define Macro2 "Row 2 Value"
   ##lit(;;) Column 1 Header ##lit(;) Column 2 Header
   ##lit(;;) Row 1 Column 1  ##lit(;) $$$Macro1
   ##lit(;;) Row 2 Column 1  ##lit(;) $$$Macro2 

creates a set of lines that form a table in .int code:

 ;; Column 1 Header ; Column 2 Header
 ;; Row 1 Column 1  ; "Row 1 Value"
 ;; Row 2 Column 1  ; "Row 2 Value"  

By using the ##lit preprocessor function, macros are evaluated and are delimited by the semicolons in the .int code

FeedbackOpens in a new tab