HaxeFoundation / HaxeFoundation/haxe
Unnecessary output emitted for lua
Open
discussion
enhancement
platform-lua
- Dominant language
- Haxe
- Stars
- 6.9k
- Forks
- 715
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 11
Description
This is really only cosmetic but as the snippet below shows, the generated output unnecessarily has ';' and also the return statement is unnecessarily encapsulated in do ... end
Its not 100% but often
```lua
Date.fromTime = function(t)
local d = _hx_e();
_G.setmetatable(d, _hx_o({__fields__={__index=true},__index=Date.prototype}));
d.t = t / 1000;
d.d = _G.os.date("*t", Std.int(d.t));
do return d end;
end
```
Contributor guide
Assessment
This issue has not been assessed yet.