Normal program languages have a lot of data types and the variable cannot change the type of it.
I think that's possible to make such multi-types-data as:
a = {table = {1,2}, bool = true, integer = 4, double = 1.33, string ="some text", type = "integer"}
And the value of it will be called as
value (a) = a[a.type].
Of coarse other types are empty.