In C++ the field is imported as an enum.
A enum is a number and a bitmask is a number... don't really understand your problem.