MantisBT - Core Inform
View Issue Details
0000825Core InformPhrases and functional programmingpublic2011-12-21 13:392014-05-07 07:34
EmacsUser 
graham 
normalseriousalways
closedfixed 
x86Mac OS X10.6
6G60 
6L02 
(serious/mild) Game compiles but misbehaves
0000825: Within one phrase, only the first occurrence of a particular dynamic dispatch is compiled to a resolver
The identical invocations in the attached source produce different I6; the latter case bypasses the resolver routine.
There is a room.
To dispatch based on (X - a thing): say "Fail."
To dispatch based on (X - a thing that is yourself): say "Pass."
When play begins:
dispatch based on yourself;
dispatch based on yourself.
! When play begins:
[ R_742 ;
  ! phrase 1
  ! [1: dispatch based on yourself]
  (Resolver_0(selfobj,"source", 16));
  ! phrase 2
  ! [2: dispatch based on yourself]
  (PHR_740_r4 (selfobj));
 rfalse;
];
No tags attached.
Issue History
2011-12-21 13:39EmacsUserNew Issue
2011-12-21 13:39EmacsUserReproducibilitysometimes => always
2011-12-21 13:39EmacsUserAdditional Information Updatedbug_revision_view_page.php?rev_id=606#r606
2012-03-31 20:48jmcgrewStatusnew => confirmed
2014-01-19 03:26grahamNote Added: 0002317
2014-01-19 03:26grahamStatusconfirmed => resolved
2014-01-19 03:26grahamResolutionopen => fixed
2014-01-19 03:26grahamAssigned To => graham
2014-05-07 07:34jmcgrewFixed in Version => 6L02
2014-05-07 07:34jmcgrewStatusresolved => closed

Notes
(0002317)
graham   
2014-01-19 03:26   
An important one to fix. There are no Resolver routines any more (dynamic dispatch is done inline instead), but the underlying fault was still there; it was to do with a substitution made to the logical proposition "a thing that is yourself" the first time the call is made, which was intended to be temporary, but which instead persisted and changed the reading of the phrase on subsequent calls.