FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Multiple assignments/var decls.

 
Post new topic   Reply to topic     Forum Index -> MiniD
View previous topic :: View next topic  
Author Message
JarrettBillingsley



Joined: 20 Jun 2006
Posts: 457
Location: Pennsylvania!

PostPosted: Tue Jun 09, 2009 12:36 am    Post subject: Multiple assignments/var decls. Reply with quote

I finally gave in to allowing Lua-style multiple assignments and variable declarations.

http://www.dsource.org/projects/minid/wiki/LanguageSpec2/Statements#Assignments

You can now initialize multiple variables like "local x, y = 1, 2". Normal assignments can be multiple as well, like "x, y = 1, 2", or my favorite, "x, y = y, x", which performs a swap Smile

Yay.
Back to top
View user's profile Send private message
maustin



Joined: 15 Jun 2009
Posts: 10

PostPosted: Mon Jun 15, 2009 11:39 pm    Post subject: Reply with quote

Yay!
Back to top
View user's profile Send private message
maustin



Joined: 15 Jun 2009
Posts: 10

PostPosted: Mon Oct 12, 2009 6:39 pm    Post subject: Re: Multiple assignments/var decls. Reply with quote

Did I mention, yay!??
Back to top
View user's profile Send private message
JarrettBillingsley



Joined: 20 Jun 2006
Posts: 457
Location: Pennsylvania!

PostPosted: Mon Oct 12, 2009 8:11 pm    Post subject: Reply with quote

Double yay!
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> MiniD All times are GMT - 6 Hours
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


Powered by phpBB © 2001, 2005 phpBB Group