Is there any way to know Val's value is known at compile-time or at runtime? I mean can I check that at IDE or somewhere? Since after I google it, there is no article talk about it. They just point out which is known at compile and which is known at runtime, but don't mention how to know that.
As far as I know, if I assign a primitive type or String to Val, its value will be known at compile time. Instead, if I assign a function or object(the value needs to be computed or reference from another place), its value will be known at runtime. But is there any way to verify that or to know that the value we assigned will be known at compile time or runtime(through IDE or decompile)?