I am working on a C ++ program in Eclipse (3.8.1) CDT. I use the gcc compiler on Debian 8. I also use an open source library called opendnp3 written in C ++, which requires uint32_t to be allowed as a parameter in several method calls and constructors.
In opendnp objects, intellisense does not list
__uint32_t however, permission is permitted.
The type is defined in <cstdint>( <cstdint>resolves just fine). I can open the declaration and see " using ::uint32_t;" there.
In my search, I added -std=c++11to โAll Settingsโ under โC / C ++ Build -> Settings -> Tool Settings -> GCC C ++ Compiler", and I also rebuilt the project index and restarted Eclipse, but it still doesn't allow it.
Here's the code: Edited in a simple HelloWorld project to help diagnose the problem
#include <iostream>
#include <cstdint> //has uint32_t defined
using namespace std;
int main() {
__uint32_t t = 0;
uint32_t i = 0;
auto x = "123";
cout << "Foo!" << endl;
return 0;
}
CDT console after attempting to build:
23:10:52 **** Incremental Build configuration Debugging for the FOO project **** do everything make: nothing needs to be done for "everyone".
23:10:52 Build Finished (took 133 ms)
source
share