Add support for ADR and REF functions #373
Labels
compatibility-oscat
syntax or semantics which are not necessarily part of the standard, but seen in the oscat-libraries
enhancement
New feature or request
language feature (norm)
a missing language feature according to iec61131-3
Milestone
Is your feature request related to a problem? Please describe.
the
REF
function is defined in the norm to return a pointer to the given value.REF
will only return a correct datatype reference (Not an address)Calling
REF
on temporary or function variables is not supported.The
ADR
function is used in Codesys and similar systems to create a pointer.We can repurpose it to return a pointer size type (not
DWORD
as it is now)This newly defined pointer type should be tracked in #353
The result of the
ADR
function should be assignable to/from a reference.Additional context
We currently use the & operator as a
REF
, we should free that operator to be used as AND later as described in the norm.The text was updated successfully, but these errors were encountered: