|View Issue Details [ Jump to Notes ] ||[ Issue History ] [ Print ] |
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0001067||Core Inform||Properties||public||2013-01-22 12:33||2014-05-07 07:33|
|Assigned To||graham|| |
|Product Version|| |
|Target Version||Fixed in Version||6L02|| |
|Summary||0001067: Compiler overzealous in disallowing anonymous references to properties of non-objects|
|Description||The source code below should compile, but it does not. The compiler chokes on the instruction to set the property of the anonymous figure-name:|
"In the sentence 'now the y-offset of F is 10' , you seem to be looking up the 'y-offset' property, but 'figure name' is not allowed to have that property."
There *is* a figure-name with this property, and the compiler should realize this, as it does in the identical case of an object property. Swap in an anonymous object (e.g., the commented code) for the figure-name to see the difference in behavior.
|Minimal Source Text To Reproduce|
Test is a room. A plumb bob is in Test.
Figure of Testing is the file "Testing.png".
The figure of testing has a number called the y-offset.
The plumb bob has a number called the y-offset.
When play begins:
let F be a random figure-name[thing in Test];
if F provides the property y-offset:
now the y-offset of F is 10.
|Tags||No tags attached.|
|Effect||(serious) Compiler rejects valid code|