A functional perform is where a parameterized section is executed to provide a resulting value to a local variable.
In certain circumstances - for example, where reference modification is involved and the length is not expressed as a literal - the Compiler for native COBOL code cannot produce valid code.
Where this occurs, you may be able to work around it by separating out the functional perform(s) into separate statements. Take the follow example, which will not compile cleanly to native COBOL code, due to the func(1) and func(2) arguments supplied within the reference modification:
move src(func(1):2) to tgt(func(2):4)
(func(1) and func(2) are sections that take an argument and return an integer.)
You could recode the example to use local variables within the reference modification operation:
declare len1 as binary-long = func(1) declare len2 as binary-long = func(2) move src(len1:2) to tgt(len2:4)