CREXX
CREXX copied to clipboard
Plugin ADDPROC has forbidden variable names.
I had in a plugin the definition
ADDPROC(parse_peg, "pegparser.pparse", "b", ".int", "input=.string");
which leads to strange behaviour when you call the plugin function:
Error in system_test.rexx @ 5:11 - #UNEXPECTED_ARGUMENT, 1, "(\'1-3+3\')"
Error in system_test.rexx @ 5:5 - #INTERNAL_ERROR_PARSING_IMPORT_AST, "pparse", "rx_system.rxplugin", "pparse(\'1-3+3\')"
Error in system_test.rexx @ 5:5 - #FUNCTION_NOT_FOUND, "pparse(\'1-3+3\')"
3 error(s) in source file
In the end, I found out, it was the ADDPROC function, which seemed to have reserved keywords. When I changed it to something else, it worked immediately. Now, I remember I had a similar issue with 'to=.string' a while ago.
Don't treat it as an error—just remember that when you write a plugin, there's no need to doubt your sanity!