Jump to content

  • Log In with Google      Sign In   
  • Create Account

- - - - -

Ref add-on cannot cast to compatible type


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 iraxef   Members   -  Reputation: 353

Like
0Likes
Like

Posted 14 August 2014 - 08:56 PM

When I have a ref and I want to cast<> it to a usable type to work with, I can only successfully cast<> to the type that was assigned to the ref and not necessarily something within the class hierarchy of what was assigned to ref. That is, if I stored a handle to an application-registered derived class, casting to the base class fails.

 

UPDATE: I see there's a TODO in CScriptHandle::Cast().


Edited by iraxef, 14 August 2014 - 09:13 PM.


Sponsor:

#2 Andreas Jonsson   Moderators   -  Reputation: 3366

Like
0Likes
Like

Posted 15 August 2014 - 07:49 AM


UPDATE: I see there's a TODO in CScriptHandle::Cast().

 

Exactly :)


AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

#3 iraxef   Members   -  Reputation: 353

Like
0Likes
Like

Posted 15 August 2014 - 10:44 AM

Do you think it would make sense to update http://www.angelcode.com/angelscript/sdk/docs/manual/doc_datatypes_ref.html with a TODO as well?






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS