Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Not your everyday can't resolve uint32_t(type uint32_t could not be resolved)
Not your everyday can't resolve uint32_t [message #1772418] Fri, 08 September 2017 22:46 Go to next message
Steve Iribarne is currently offline Steve IribarneFriend
Messages: 3
Registered: September 2017
Junior Member
Hello all.

These files compile just fine.

So I get the dreaded red underline and marker in my main.c where I have uint32_t used as a parameter.

I know what the problem is, just not how to fix it.

I look in my CDT Global Build Console
and I see this....

#define __UINT32_TYPE__ long unsigned int

No I believe this is due to the fact that newlib-stdint.h is being included????

I'm not sure... that's my guess and I'm sticking to it...

I just don't know how to fix this.

Thanks.
-stv
Re: Not your everyday can't resolve uint32_t [message #1772605 is a reply to message #1772418] Wed, 13 September 2017 01:33 Go to previous message
David VavraFriend
Messages: 1426
Registered: October 2012
Senior Member
It depends on the compiler used.
unsigned int is compatible with long unsigned int with GCC but not with Visual Studio,

With GCC, uint32_t should be compatible with __UINT32_TYPE__;
It is defined in stdint.h but only if the dialect is c++11 or better
and then only if a long unsigned int is really 32 bits.

GCC example:
index.php/fa/30719/0/

If they are different types with your compiler you may be stuck unless you do a lot of type casting
https://stackoverflow.com/questions/11611467/type-of-unsigned-long-is-different-from-uint32-t-and-uint64-t-on-windows-vs2010

This is off-topic for this forum which is for CDT related problems.
You should address further questions to forums such as stackoverflow.

[Updated on: Wed, 13 September 2017 02:01]

Report message to a moderator

Previous Topic:How to Activate a Plugin when leaving the "New Project" Wizard
Next Topic:OpenOCD compatibility
Goto Forum:
  


Current Time: Fri Apr 26 23:19:33 GMT 2024

Powered by FUDForum. Page generated in 0.03165 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top