Reputation: 7440
I' learning the Opa (opalang.org). I am trying to find out how one can determine the type of a variable. This could be e.g. a function
typeof a // in javascript, this returns the type of a
The API-Documentation contains a description of OpaValue.typeof(a) but I can't find out how to use it.
Upvotes: 0
Views: 241
Reputation: 1094
Here is a short example :
int hello = 42
hello_type = OpaValue.typeof(hello)
Log.info("Hello type:", "{hello_type}")
However i am surprised you want to manipulate Opa types. What is your usage ?
Upvotes: 1