mario@108: (* Test whether the keyword XXXX may be used as an identifier for: mario@108: * IL label name/identifier mario@108: * mario@108: * The XXXX names in the following code are merely a placeholder. mario@108: * They will be replaced by several identifiers before actual testing mario@108: * of the compiler. mario@108: *) mario@108: mario@108: (* The identifiers that will replace the XXXX mario@108: * must be placed on a line starting with # mario@108: * All identifiers preceded by # are ignored! mario@108: * The identifier list must be placed inside an IEC 61131-3 comment. mario@108: *) mario@108: (* mario@108: #IL_operators #ANDN #CAL #CALC #CALCN #CD #CLK #CU #IN #JMP #JMPC #JMPCN mario@108: #IL_operators #LD #LDN #ORN #PT #PV #R #R1 #RET #RETC #RETCN #S #S1 #ST #STN #XORN mario@108: #SFC_qualifiers D DS L N P #R #S SD SL mario@108: NOTE: R and S are identical to IL operators!! mario@108: #Task_initialisers PRIORITY SINGLE INTERVAL mario@108: *) mario@108: mario@108: (* NOTE: Currently the matiec compiler does not yet support mario@108: * the use of identifiers identical to IL operators mario@108: * in IL code. In ther words, in IL code we cannot use mario@108: * identifiers identical to IL operators to identify variables, mario@108: * functions, etc... mario@108: * Identifiers identical to IL operators are therefore mario@108: * commented out. mario@108: *) mario@108: mario@108: mario@108: mario@108: mario@108: mario@108: function foo : int mario@108: var mario@108: e, f : bool; mario@108: end_var mario@108: mario@108: XXXX: R e mario@108: JMP XXXX mario@108: end_function mario@108: mario@108: mario@108: mario@108: function bar : int mario@108: var mario@108: e, f : bool; mario@108: end_var mario@108: mario@108: JMP XXXX mario@108: XXXX: R e mario@108: end_function mario@108: mario@108: mario@108: mario@108: mario@108: mario@108: mario@108: mario@108: (* Checking whether the use of XXXX will confuse any other mario@108: * normal and correct IL or ST code. mario@108: *) mario@108: {#include "basic_code.test" } mario@108: