Re: a question about foreach construct

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

Foreach in euphoria will work only to read itens from a sequence. Because Euphoria's copy on change, we cant modify the fields of a loop variable:

foreach monster in monsters do 
  monster[X] += 1; --will not work 
end foreach 

So foreach in euphoria is a bit useless...

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

Search



Quick Links

User menu

Not signed in.

Misc Menu