Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000887Core InformKinds and type checkingpublic2012-03-19 18:342014-05-07 07:34
Assigned Tograham 
Platformx86OSLinuxOS VersionAny
Product Version6G60 
Target VersionFixed in Version6L02 
Summary0000887: Cannot assign literal values to "description of K" variables
DescriptionIf a variable holds a description of K, trying to assign a literal description of K to it won't work. "Now" cannot be used as a workaround.
Minimal Source Text To Reproduce

There is room.

When play begins:
	Let D be a description of numbers;
	Let D be even numbers.
Additional InformationThe example also fails if "Let D be a description of numbers" is commented out, but the error message is less obviously wrong.

If this is a fundamental limitation of Inform, WI 21.2 should mention it; as-is, it explicitly states that "even numbers" is a value of kind "description of numbers", implying that this should work since "Let... be" expects a value and it is a value.
TagsNo tags attached.
Effect(serious) Compiler rejects valid code
Attached Files

- Relationships
related to 0000889closedgraham Tables of descriptions cannot be populated at compile-time 
related to 0000891closedgraham Description interpreted as object name 
child of 0000899closedgraham Umbrella issue: Inform rejects description literals in several cases 

-  Notes
NYKevin (reporter)
2012-03-19 19:41

Also happens with lists:

There is room.

The interesting list is a list of descriptions of numbers that varies.
The interesting list is {even numbers}.

IRRELEVANT technical info, included since extra issue was not(?) reproducible, follows.

Note that the above minus the last line will compile, but the first time I did so, Inform crashed. I have been unable to reproduce the problem reliably enough to report it for the time being, but I will leave these here for now: [^] -- initial crash output etc. [^] -- weirdness with I6 while trying to reproduce.

As the issue was initially a double free(), I tried running under Valgrind, but failed to reproduce the problem (and discovered that Valgrind is excessively slow).

I have given up on trying to reproduce this issue for now, but if anyone else sees it, feel free to report.
EmacsUser (manager)
2012-03-20 12:16
edited on: 2012-03-20 12:17

I feel like I've seen this before, but I'm not finding it in Mantis. In the meantime, a workaround is to add

- - - -
To let (t - an existing variable) be (u - a description of values)
    (assignment operation)
    (documented at ph_let):
    (- {-assignment}; -).
- - - -

to your source text.

EmacsUser (manager)
2012-03-20 12:25

The list bug is probably a separate issue, so I've split it off as 0000891. The crash also looks unrelated, and probably has more to do with what you were doing in the GUI than the source text.
graham (administrator)
2014-01-19 06:52

I've improved the problem message.

- Issue History
Date Modified Username Field Change
2012-03-19 18:34 NYKevin New Issue
2012-03-19 19:41 NYKevin Note Added: 0001607
2012-03-20 12:16 EmacsUser Note Added: 0001611
2012-03-20 12:17 EmacsUser Note Edited: 0001611 View Revisions
2012-03-20 12:23 EmacsUser Issue cloned 0000891
2012-03-20 12:25 EmacsUser Note Added: 0001612
2012-03-27 14:17 EmacsUser Relationship added related to 0000889
2012-03-27 14:18 EmacsUser Relationship added related to 0000891
2012-03-27 14:19 EmacsUser Reproducibility have not tried => always
2012-03-27 14:19 EmacsUser Status new => confirmed
2012-03-30 22:50 EmacsUser Relationship added related to 0000899
2012-03-31 19:57 jmcgrew Relationship replaced child of 0000899
2014-01-19 06:52 graham Note Added: 0002323
2014-01-19 06:52 graham Status confirmed => resolved
2014-01-19 06:52 graham Resolution open => fixed
2014-01-19 06:52 graham Assigned To => graham
2014-05-07 07:34 jmcgrew Fixed in Version => 6L02
2014-05-07 07:34 jmcgrew Status resolved => closed

Copyright © 2000 - 2010 MantisBT Group
Powered by Mantis Bugtracker