Jump to content
  • Advertisement
Sign in to follow this  

OPTIONALLY dynamic types using "var"/variant/dynamic keyword

This topic is 2925 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

though in almost all cases i specify data type of my variable, but in case of one or two variable (in few programs) i might not want to specify the data type.
is there:
1) a dynamic data type facility available (or in roadmap) in angelscript [this is independent question from question 2]
These days fully statically typed languages like C# and Scala have acquired "dynamic" keyword , which have SOME extremely important USECASES.
Groovy language itself also allows you since beginning to specify the data type or OPTIONALLY not specify the data type and be fully dynamically typed
among small languages (compared to lua), the jewelscript supports that
int i; //data type specified fully
var j; //dynamic type using var keyword.

if it is not available in angelscript, then whether exposing the C++ class "boost::any" or "boost::variant" to angelscript will be of any help.

2) is there type inferencing facility available [ this is independent question from question 1]

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!