stdint.h in MSVS

Hi all,

for a certain project, I'm forced to use MS Visual Studio and it's compiler.
From linux and microcontroller programming, I'm used to the C99 stdint.h definitions (uint8_t etc.) to avoid portability problems between architectures.

I read that VS does not support the C99 definitions and will not do so in the (near) future.
As far as I understood, the implementation of the C99 types e.g. in stdint.h partly depends on machine-specific information, which needs to come from the compiler. It is not so easy to port e.g. the gnu stdint.h such that it can be used with VS.

My question is now how do you handle this?

Background:
The project is about a scientific code which binds together several libraries (we e.g. use parts of boost, openCV, Xerces, sqlite, hdf5, ...).
These libraries partly define their own datatypes.
I therefore would like to have an 'interfacing layer' of partable datatypes which allows to pass data from one library to the other.

I'm unsure about the best practice.

Thx
Alex
Try here (Right down the bottom of the page).
http://en.wikipedia.org/wiki/Stdint.h
Depending on what version of VS you're using, you'll find that __int8, __int32 and __int64 are defined. You can make up typedefs for your project based on these types.
Topic archived. No new replies allowed.