## 1 Program

program | ::= | include_cocci * changeset +
include_cocci | ::= | #include string
| | | using string
| | | using pathToIsoFile
| | | virtual id (, id) *
changeset | ::= | metavariables transformation
| | | script_metavariables script_code

script_code is any code in the chosen scripting language. Parsing of the semantic patch does not check the validity of this code; any errors are first detected when the code is executed. Furthermore, @ should not be used in this code. Spatch scans the script code for the next @ and considers that to be the beginning of the next rule, even if @ occurs within e.g., a comment.

virtual keyword is used to declare virtual rules. Virtual rules may be subsequently used as a dependency for the rules in the SmPL file. Whether a virtual rule is defined or not is controlled by the -D option on the command line.