1 /*---------------------------------------------------------------------------* 2 3 Copyright (C) Nintendo. All rights reserved. 4 5 These coded instructions, statements, and computer programs contain 6 proprietary information of Nintendo of America Inc. and/or Nintendo 7 Company Ltd., and are protected by Federal copyright law. They may 8 not be disclosed to third parties or copied or duplicated in any form, 9 in whole or in part, without the prior written consent of Nintendo. 10 11 *---------------------------------------------------------------------------*/ 12 13 #ifndef _CAFE_GX2R_CPP_H_ 14 #define _CAFE_GX2R_CPP_H_ 15 16 #ifdef __cplusplus 17 18 /// @addtogroup GX2RGroup 19 /// @{ 20 21 /// \brief Allow GX2RResourceFlags flags to be combined without casting 22 GX2_INLINE GX2RResourceFlags operator |(GX2RResourceFlags x, GX2RResourceFlags y) { return (GX2RResourceFlags)((s32)x | (s32)y); } 23 GX2_INLINE GX2RResourceFlags operator |(GX2RResourceFlags x, s32 y) { return (GX2RResourceFlags)((s32)x | (s32)y); } 24 GX2_INLINE GX2RResourceFlags operator |(s32 x, GX2RResourceFlags y) { return (GX2RResourceFlags)((s32)x | (s32)y); } 25 26 GX2_INLINE GX2RDebugOptions operator |(GX2RDebugOptions x, GX2RDebugOptions y) { return (GX2RDebugOptions)((s32)x | (s32)y); } 27 28 29 /// @} 30 31 32 /// @addtogroup GX2UTGroup 33 /// @{ 34 35 namespace GX2UT 36 { 37 //TODO: C++ operators, templates 38 } 39 40 /// @} 41 42 #endif //__cplusplus 43 44 #endif 45