Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD Beta Forum Goto page Previous  1, 2
JQuilici Posted: Tue Nov 06, 2007 4:39 pm
Questions on scoping and the current class
JQuilici
Adept


Joined: 21 Sep 2005
Posts: 250
Location: Austin, TX

PostPosted: Fri Nov 16, 2007 3:48 am   
 
There's one case that is not specifically explored by the test currently: If we had a //ScopeTest01/Class01/showScopeTest01a alias (with the same code as showScopeTest01), it should find //ScopeTest01/Class01/testVar first, then...
  1. //ScopeTest01/testVar (in the parent of the defining class), then //ScopeTest/testVar (in the current window); OR
  2. //ScopeTest/testVar (in the current window), then //ScopeTest01/testVar (in the parent of the defining class

I believe that #1 is the desired behavior - we want to check the defining class, and all of its parents to the root of the defining module, THEN the current class in the current module (e.g the session window) and all of its parents to the root of the current module, THEN back to the defining module to look through the rest of the classes, and so on.

Other than that, I agree. Mission accomplished. Go team!
_________________
Come visit Mozart Mud...and tell an imm that Aerith sent you!
Reply with quote
Zugg
MASTER


Joined: 25 Sep 2000
Posts: 23379
Location: Colorado, USA

PostPosted: Fri Nov 16, 2007 3:52 am   
 
#1 is the correct behavior and is how it works in 2.12 right now.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD Beta Forum All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net