Up Next

1  Program

program   ::=  include_cocci * changeset +
include_cocci   ::=  using string
|using pathToIsoFile
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 use 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 string or a comment.


Up Next