Previous Topic Next topic Print topic


COBCH1608 Illegal USAGE in this context

The specified USAGE type has been used out of context.

Certain USAGE types cannot be used in the procedure division header. For example:

class-id myClass1.
      
indexer-id string.
procedure division using i1 as COMP-3. *> this is incorrect
    getter.
    set property-value to i1.
end indexer.
end class.

class-id myClass2.
indexer-id string.
procedure division using i2 as binary-double. *> this is correct
    getter.
    set property-value to i2
end indexer.
end class.
Previous Topic Next topic Print topic