Skip to content

#679 PLCgen: Add formal invoke options

Albert Hofkamp requested to merge 679-add-plcgen-invoke-options into develop

Adds the formal invoke options.

  • FormalInvokeArg* was actually about FormalInvokeParam* (the number of parameters of the function rather than the number of supplied arguments).

  • ModelTextGenerator is now an instance taking the values of the invoke option settings.

  • Comparing against cif2plc was messy as generated output is hugely different. In the end if grabbed function-like text of the form NAME(......, that is an all-uppercase name and a parenthesis, and then some text behind it to get the tell-tale := and then sorted on function use. See the attached output file for all combinations of the new option values. Also added the python script just in case.

    textoutput.txt find_funcs.py

  • It seems complicated to get the result I'd like. Possibly the notion of "std" differs between both programs, and/or the collection of allowed forms of expressions. Also how to decide between infix / non-formal prefix / formal prefix is likely different.

  • My current guess is that we need more precise options to better express the desired result. I'd like to do that not now though.

Addresses #679

Edited by Albert Hofkamp

Merge request reports