Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000808Core InformUnderstandingpublic2011-11-21 08:452014-05-07 07:34
Reporterzarf 
Assigned Tograham 
PrioritynormalSeverityseriousReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version6G60 
Target VersionFixed in Version6L02 
Summary0000808: Scope test in a parse_name causes the parser to hang
DescriptionIn the sample below, "x anne" sends the parser into an infinite loop. (Not an infinite recursion, mind you.) A generated Parse_Name_ routine gets stuck in a while(true).

The parse_name routine of the crowd does a visibility test, which means a scope test; that invokes PlaceInScope. The first line of PlaceInScope resets wn. Thus the parse_name routine never makes progress through the input buffer.

I'd say the fix was to remove that line from PlaceInScope, but I really have no idea what it's doing there. Maybe it's important and the fix should be something else.

Forum threads:
http://www.intfiction.org/forum/viewtopic.php?f=7&t=3129 [^]
http://www.intfiction.org/forum/viewtopic.php?f=7&t=3175 [^]
http://www.intfiction.org/forum/viewtopic.php?f=7&t=3730 [^]
Minimal Source Text To Reproduce
Main Road is a room.

Anne is a woman. Understand "woman" as Anne.

The Dummy is a thing.

The crowd is a plural-named person, here.

Understand "Anne" as the crowd when the player cannot see Anne.

After deciding the scope of the player (this is the place dummy in scope rule): place dummy in scope.

TagsNo tags attached.
Effect(serious/mild) Game compiles but misbehaves
Attached Files

- Relationships

-  Notes
(0001465)
soukie (reporter)
2011-11-21 09:03

Calling the rule "place dummy in scope" which coincides with the command to be executed makes it look like a recursion. I know you are not saying:
After deciding the scope of the player (this is the place dummy in scope rule): follow the place dummy in scope rule.
But it's confusingly close.
(0002295)
graham (administrator)
2014-01-15 10:19

PlaceInScope now saves wn and restores it after the call terminates; I can't believe it was ever intended to change the state of wn other than for its own private purposes, so this seems safe enough. It fixes the problem.

- Issue History
Date Modified Username Field Change
2011-11-21 08:45 zarf New Issue
2011-11-21 09:03 soukie Note Added: 0001465
2011-11-22 12:36 EmacsUser Status new => confirmed
2012-06-11 02:25 infoqw Note Added: 0001682
2012-06-11 02:26 infoqw Note Edited: 0001682
2012-06-11 05:40 EmacsUser Note Deleted: 0001682
2012-06-11 14:55 EmacsUser Note Revision Dropped: 1682: 0000694
2014-01-15 10:19 graham Note Added: 0002295
2014-01-15 10:19 graham Status confirmed => resolved
2014-01-15 10:19 graham Resolution open => fixed
2014-01-15 10:19 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