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
cazador
Apprentice


Joined: 08 Dec 2005
Posts: 108

PostPosted: Wed Apr 01, 2009 12:15 pm   

feature requests
 
1. zscript to have anonymous functions. This makes it easy to do a call a function like @var[function](params) where function can be a variable. Might be implementable by using lua tables, lua already has this ability.
2. I really like the perl =~s and =~m operators. It would be nice to have similar operators in zmud. Including the ability to specify captures. ex. $var=~s/(This is a test) so is this/$1/
3. It would be nice if the package library would have the notion of required packages needed for a package to run.
Reply with quote
Rahab
Wizard


Joined: 22 Mar 2007
Posts: 2320

PostPosted: Wed Apr 01, 2009 1:53 pm   
 
Number 3 may not be a good idea. Zugg has said many times that he intended packages to be complete and modular, not depending on any other packages. This really is the best practice. Some have found it necessary to put in package dependencies, but I'm not sure it would be a good idea to encourage the practice.
Reply with quote
Tech
GURU


Joined: 18 Oct 2000
Posts: 2733
Location: Atlanta, USA

PostPosted: Wed Apr 01, 2009 2:59 pm   
 
I was never a big fan of anonymous functions, so I don't really agree with being built into zScript. Without having actually tested it, I'm sure you could probably do this similar to how you would do indirect variable references, or at the very least with %exec or #EXECUTE.

Number two can easily be handled by the %grep, %match and %regex functions. You can even do pattern matching in a #IF experssion using '=~'.
_________________
Asati di tempari!
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD Beta Forum All times are GMT
Page 1 of 1

 
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