I want to check syntax for multiple defrules. How should I implement this operation?
I know (check-syntax <construct-or-function-string>)
can check one rule, but it does not support multiple rules in one string.
Example (in clips cli):
CLIPS> (check-syntax "(defrule output1 => (printout t \"test for check-syntax 1\")
)")
FALSE
CLIPS> (check-syntax "(defrule output1 => (printout t \"test for check-syntax 1\")
) (defrule output2 => (printout t \"test for check-syntax 2\")
)")
EXTRANEOUS-INPUT-AFTER-LAST-PARENTHESIS
If there is a string containing multiple rules,do I have to split it as a single rule for check-syntax?