[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Lua syntax gotcha
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Mon, 26 Oct 2009 15:06:24 -0200
> Yes, I can see myself spending time tracking down such a thing. I'll try
> to remember to use a semicolon when I add debug code like that:
> function test2()
This code does not compile: "return" must be the last statement in the block.
So you need to use this instead: "do return end". No semicolon is needed.