Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: tog on January 04, 2011, 11:36:25 am

Title: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: tog on January 04, 2011, 11:36:25 am
I can not use  ltoa() and strrev() functions in Code::Blocks ( under Windows). File stdlib.h has not them. How can I get them in Code::Blocks ?
Title: Re: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: Jenna on January 04, 2011, 11:39:03 am
By installing a compiler that has them included.

Be aware that C::B is not a compiler, it's just an IDE, that works with very many compilers available.
Title: Re: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: tog on January 04, 2011, 11:43:30 am
No compiler fits ! I tried to use all compilers in C::B...
Title: Re: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: Jenna on January 04, 2011, 11:50:28 am
No compiler fits ! I tried to use all compilers in C::B...
By installing a compiler that has them included.

Be aware that C::B is not a compiler, it's just an IDE, that works with very many compilers available.

Read my post carefully !
The only compiler that is (sometimes) shipped with C::B on windows is MinGW, but it is not part of C::B and it's only distributed for your convenience.
Title: Re: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: tog on January 04, 2011, 12:06:55 pm
I have C::B 10.05 version. It has many compilers: GNU GCC compiler, Visual C++ 2005/2008,Borland C++ compiler and many others....I downloaded all of them with C::B.
All compilers are into : Global compiler settings->Selected compiler. Functions ltoa() and strrev() are unstandard ! Before I compiled programms normally untill I tried to use ltoa(), strrev().
Title: Re: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: Jenna on January 04, 2011, 12:12:43 pm
I have C::B 10.05 version. It has many compilers: GNU GCC compiler, Visual C++ 2005/2008,Borland C++ compiler and many others....I downloaded all of them with C::B.
All compilers are into : Global compiler settings->Selected compiler. Functions ltoa() and strrev() are unstandard ! Before I compiled programms normally untill I tried to use ltoa(), strrev().

You should not ask questions about software in forums, if you can not accept the answer or if you believe you know it better than a longtime user and developer of the software you use.
Title: Re: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: tog on January 04, 2011, 12:21:47 pm
I just ask you...
Title: Re: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: rickg22 on January 07, 2011, 01:30:11 pm
Okay, just not to leave the question open...

The C::B distribution you downloaded is not bundled with a compiler. It allows you to choose from any compilers you might have installed. In the download section, there's a package which does included a bundled mingw compiler. Be reminded that C::B is not like Visual Basic which has everything installed and ready-to-go. You should at least download GCC and try a hello world C++ example with notepad to know how to use a compiler and linker. Then you can configure C::B and enjoy the IDE. See ya.
Title: Re: ltoa() and strrev() functions in stdlib.h of Code::Blocks
Post by: Mountaingod on January 07, 2011, 06:56:15 pm
For what it's worth,

1. http://www.cplusplus.com/reference/ (http://www.cplusplus.com/reference/) doesn't list either function, but http://linux.die.net/man (http://linux.die.net/man) describes both (under stdlib.h and string.h respectively). This suggests they might be somewhat platform-specific;

2. MinGW is a port of Linux's GCC. As a result of this, my copy of MinGW does in fact provide those functions. I don't know about other compilers however, especially Windows-only ones such as MSVC.