Hacker News new | ask | show | jobs
by arp242 741 days ago
I really really don't want to do type annotations. I just want to know about:

  variable = 1
  print(varaible)
It's been a while since I did Lua, but there's been a few cases where this caused massive confusion.

Last I checked I couldn't really find a good way to do that; but like I said: it's been a while.

3 comments

Luacheck will warn about unknown globals.
I think every lua linter warns about that. So does the Lua LSP, no annotations needed.
Well, yeah, you shouldn't name your variables so similarly, that's what's causing he confusion. Idunno, maybe varaible is set to "Let's groove, baby!" ? ;-)