allow `cwatch` with `ADDRESS OF`, possibly `LENGTH OF`
It would be useful to be able to actually cwatch ADDRESS OF LINKAGE-VAR
(that's some of the rare places where we currently still need to fall back to "C" watching) [similar for BASED
items].
I think this should be allowed only for variables in LINKAGE
or BASED
- otherwise a code like ConditionalRaise("Variable {0} has a fixed address {1})"
seems reasonable - and for level 01/77 items, which may be tackled by something like ConditionalRaise("Variable {0} is level {1}, only ADDRESS OF variables on level 01/77 may be watched)"
.
LENGTH OF
could also vary and may be useful to watch, but that's a much more seldom case and still can be indirectly done with cwatch
of all DEPENDING ON
items, so no need for allowing watching that. One thing to consider here is that the current return "invalid syntax" is not ideal, ConditionalRaise("LENGTH OF may be watched by cwatch ODO item(s)")
, or similar would be nice (not necessary).