Keeping track of templated classes
Is there a way to keep a list of templated classes? I'm attempting to write my own configuration file system. I'll be parsing configuration files for keywords such as "int" "float" etc. So when I'm parsing a file I want to be able to create a templated variable class "Variable<int>" and "Variable<float>". This isn't hard, but how can I keep a list of all of these when I cannot use a templated class as a list type?
Ah, of course. Thanks. I resorted to just parsing floats because I can't think of any way to create user-defined types with a script. I can't imagine including every file in my game that has a type definition in it and hard coding a string to match every single user type.
Quote:Original post by M4573R
I resorted to just parsing floats
Beware, most integer values cannot be represented by floats. Have you tried parsing the integer 123456789 as a float for example? ;)
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement