Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

OCCI - using 64-bit values with occi::Number on Linux and Windows

User_AIPO5Dec 8 2021

I'm trying to read a 64bit value from an occi::Number. Fortunately occi::Number provides cast operators, which are nice to use:
unsigned long value = (unsigned long)myOcciNumber;

Unfortunately they're using native integer types, which are not the same on different systems. Unsigned long is 64bit on Linux, but 32bit on Windows. I would like to use the same code on both systems, which works really good for everything else.
I would prefer not to manually pick apart the occi::Number via bytes. If everything else fails I'll have to.

Is there any way to get a 64bit value with the same code on both systems?

Comments

Post Details

Added on Dec 8 2021
0 comments
167 views