Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000080Core InformRelationspublic2010-06-21 00:322010-10-28 00:30
Reporterjmcgrew 
Assigned Tograham 
PrioritynormalSeveritymildReproducibilityalways
StatusclosedResolutionfixed 
Platformx86OSWindowsOS Version7
Product Version6E59 
Target VersionFixed in Version6F95 
Summary0000080: Untyped relations are allowed but can't be used safely
DescriptionInform accepts "relation" or "relation of values to values" as the type of a global variable or property, but such a generic type breaks type safety (and is forbidden as the type of a local variable). The code below stores indexed text and numbers in the same domain, but the indexed text is treated as a number when printed.
Minimal Source Text To Reproduce
Home is a room.

Foo is a relation that varies.
A thing has a relation of values to values called bar.

When play begins:
	let X be indexed text;
	let X be "grunk";
	now foo relates 4 to X;
	show relation foo.
Additional InformationThe indexed text can still be pulled out with "the indexed text to which 4 relates by foo", but since the relation code doesn't know which values are block type, its lifetime won't be managed reliably when the relation is modified.

"list of values" is already forbidden as the type of a variable or property.
TagsNo tags attached.
Effect(mild) Compiler accepts invalid code
Attached Files

- Relationships

-  Notes
(0000611)
graham (administrator)
2010-09-29 01:52

I have finally sorted this out, and generally improved the problem messages in this area.

- Issue History
Date Modified Username Field Change
2010-06-21 00:32 jmcgrew New Issue
2010-06-21 00:32 jmcgrew Status new => acknowledged
2010-06-21 10:25 jmcgrew Additional Information Updated View Revisions
2010-06-21 12:27 EmacsUser Status acknowledged => confirmed
2010-09-29 01:52 graham Note Added: 0000611
2010-09-29 01:52 graham Status confirmed => resolved
2010-09-29 01:52 graham Resolution open => fixed
2010-09-29 01:52 graham Assigned To => graham
2010-10-25 21:14 jmcgrew Fixed in Version => 6F95
2010-10-28 00:30 jmcgrew Status resolved => closed


Copyright © 2000 - 2010 MantisBT Group
Powered by Mantis Bugtracker