Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0001156Core InformAssertions and creationspublic2013-12-12 11:522014-05-07 07:33
Assigned Tograham 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version6L02 
Summary0001156: Declaring a kind "always improper-named" can cause errors
DescriptionThe code below produces this error:

Problem. You wrote 'Matching key of locker is red key' , but in another sentence 'A key is always improper-named' : red key therefore has to have two contradictory states of the same property at once, which is impossible. When a kind's definition says that something is 'always' true, there is no way to override that for particular things of the kind.

The "Matching key..." declaration is the first mention of the red key, and it's named without "the". Therefore, the compiler thinks that the red key must be proper-named. That's not unreasonable. But then the "always" declaration for keys blows it up.

(A more specific declaration, "The red key is improper-named," works correctly. In fact it allows the "always" declaration to go through without error, which I guess is not surprising.)

This is a somewhat contrived example, but I don't think it's *too* contrived.
Minimal Source Text To Reproduce
The Kitchen is a room.

A key is a kind of thing.
A key is always improper-named.

The locker is a locked container in the Kitchen.
Matching key of locker is red key.

The red key is a key in the Kitchen.
TagsNo tags attached.
Effect(serious) Compiler rejects valid code
Attached Files

- Relationships

-  Notes
zarf (developer)
2013-12-12 11:59

More generally, I'm uncomfortable with the idea that the very first mention of an object is privileged in this way (creating an implicit proper-named declaration).

I know that "X is a key" and "The foo of Y is X" are both relation-declarations about X, but can there be more nuance about which one to take as *the* declaration of X's existence? I realize this is a fuzzy area, and maybe adding complexity will only degrade things, but I feel the need to ask.
graham (administrator)
2014-05-04 02:50

Fixed; the result is an improper-named red key. Inform only infers proper-named from a lack of article at the level of "likely", whereas "A key is always improper-named" results in an inference considered "certain", so there's a clear winner. This was just a bug in the code reconciling that.

- Issue History
Date Modified Username Field Change
2013-12-12 11:52 zarf New Issue
2013-12-12 11:59 zarf Note Added: 0002176
2013-12-14 11:56 EmacsUser Status new => confirmed
2014-05-04 02:50 graham Note Added: 0002651
2014-05-04 02:50 graham Status confirmed => resolved
2014-05-04 02:50 graham Resolution open => fixed
2014-05-04 02:50 graham Assigned To => graham
2014-05-07 07:32 jmcgrew Fixed in Version => 6L02
2014-05-07 07:33 jmcgrew Status resolved => closed

Copyright © 2000 - 2010 MantisBT Group
Powered by Mantis Bugtracker