Reputation: 571
> print(type(X))
nil
> print(type(type(X)))
string
> print(type(nil))
nil
>
Why are the last two prints having different results?
Upvotes: 2
Views: 55
Reputation: 422
The type
of the type
of anything will be a string because type
always results in a string.
See: https://www.lua.org/pil/2.html
Upvotes: 1