RAD Studio
ContentsIndex
PreviousUpNext
reinterpret_cast (typecast Operator)

Category 

C++-Specific Keywords 

Syntax  

reinterpret_cast< T > (arg)

Description 

In the statement, reinterpret_cast< T > (arg), T must be a pointer, reference, arithmetic type, pointer to function, or pointer to member. 

A pointer can be explicitly converted to an integral type. 

An integral arg can be converted to a pointer. Converting a pointer to an integral type and back to the same pointer type results in the original value. 

A yet undefined class can be used in a pointer or reference conversion. 

A pointer to a function can be explicitly converted to a pointer to an object type provided the object pointer type has enough bits to hold the function pointer. A pointer to an object type can be explicitly converted to a pointer to a function only if the function pointer type is large enough to hold the object pointer.

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!