paulcuth / starlight

A Lua to ES6 transpiler.
MIT License
186 stars 23 forks source link

Bug on function call on expression #17

Closed Etiene closed 8 years ago

Etiene commented 8 years ago

Hello, I found an odd behaviour! :)

local function test()
    return true
end

print(test()) -- true
print(test() and true) -- true
print(true and test()) -- userdata 
paulcuth commented 8 years ago

Hi Etiene, Sorry for the delay on this.

I can't repeat it; I think it was fixed in https://github.com/paulcuth/starlight/commit/ad546a362f1662455f168525004c602617b96b96. I'm going to close this, please feel free to reopen if you think it's still an issue.

PC.

Etiene commented 8 years ago

Ok! I'll give it another try with the most recent version as soon as I have the time and let you know! thanks