hhu-stups / prob-issues

ProB issues (for probcli, ProB Tcl/Tk, ProB2, ProB2UI)
6 stars 0 forks source link

Strange behaviour when Definition clashes with record field #326

Open leuschel opened 12 months ago

leuschel commented 12 months ago

The behaviour of the parser here is not really consistent:

MACHINE DefNameAsRecordField
DEFINITIONS
  aa == 1;
  yy == 2
CONSTANTS myrec
PROPERTIES
 myrec = rec(xx:aa,yy:2) &  // <- Parse error
 myrec = rec(xx:aa,`yy`:2)  // <- Ok
ASSERTIONS
  yy = 2;   // <- Ok
  `yy` = 2  // <- Ok
END

Maybe we should allow yy as record field also without quotes? Or we should try and improve the error message.