mirror of
https://github.com/rubyjs/therubyracer
synced 2023-03-27 23:21:42 -04:00
19 lines
287 B
C
19 lines
287 B
C
|
#ifndef RR_UINT32
|
||
|
#define RR_UINT32
|
||
|
|
||
|
namespace rr {
|
||
|
|
||
|
class UInt32 : public Equiv {
|
||
|
public:
|
||
|
UInt32(VALUE val) : Equiv(val) {}
|
||
|
UInt32(uint32_t ui) : Equiv(UINT2NUM(ui)) {}
|
||
|
|
||
|
inline operator uint32_t() {
|
||
|
return RTEST(value) ? NUM2UINT(value) : 0;
|
||
|
}
|
||
|
};
|
||
|
|
||
|
}
|
||
|
|
||
|
#endif
|