Swap and pass-by-reference

new topic     » topic index » view thread      » older message » newer message

G'day

I just had a quick look into the past and saw a discussion in late 2009 about pass by reference. Has the situation changed at all? Reason I ask regards the RosettaCode question 'Generic Swap'; an Euphoria solution would seem to require pass by reference (or else something uniquely Euphorian that I'm ignorant of.)

The pass-by-value semantics means that that this

procedure swap( object a, object b ) 
	object x 
	x = a 
	a = b 
	b = x 
end procedure 

doesn't work.

Kind regards, Bruce

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu