RE: BUG in EUPHORIA PARSER

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

So you are saying that they should both cause errors?  It appears that 
inc1() only returns 'ctrl' and stops executing the function because 
adding the following loop to the program (and commenting out function 
'inc2') just prints a bunch of zeros.

for i = 1 to 10 do
  ? inc1()
end for


Bernie Ryan wrote:
> 
> 
> 
> integer ctrl ctrl = 0
> 
> -- THIS WILL PARSE AND WORK PROPERLY
> function inc1() return ctrl = ctrl + 1 end function
> 
> -- THIS WILL NOT PARSE CAUSES AN ERROR at the += 
> function inc2() return ctrl += 1 end function
> 
> 
> 
> Bernie

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

Search



Quick Links

User menu

Not signed in.

Misc Menu