C Board  

Go Back   C Board > General Programming Boards > C Programming

Reply
 
LinkBack Thread Tools Display Modes
Old 11-08-2009, 12:04 AM   #1
Registered User
 
Join Date: Nov 2009
Posts: 1
IDE Dev-C++

I am using the dev-c++ compiler and going through a C programing cd bu Mark Virtue that is quite good.

The problem I am having is I am at a point where I am checking the value of a variable and on the CD he is using a single quote around it as the value of the variable is a single character.

Now I am using the same compiler as he is (Dev-C++) but it is a different version. His version will highlight single quotes and everything in between it but mine only does this with double quotes. Also when I do compile with single quote I get the following error on the line with the single quote around a character.

[Warning] comparison between pointer and integer

any ideas???

I have tried to use double quotes but it does not work either.
bongo264 is offline   Reply With Quote
Old 11-08-2009, 12:34 AM   #2
Registered User
 
Join Date: Oct 2006
Location: Canada
Posts: 848
Its probably easier if you just post the small piece of code, than explain it in English. Are you doing something like this?
Code:
    char* str="a";

    if ( str == 'a')
Which will result in the warning your seeing. If not, again, post your code.
nadroj is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
IDE djnorthyy C++ Programming 6 03-31-2008 11:56 AM
Whats better, C-Free or Dev C++?? i_can_do_this Tech Board 10 07-07-2006 04:34 AM
New to Dev C++/<windows.h>... Cilius C++ Programming 3 02-23-2005 01:05 AM
Glut and Dev C++, Programs not Quitting? Zeusbwr Game Programming 13 11-29-2004 08:43 PM
HD on IDE 2 W.Churchill A Brief History of Cprogramming.com 3 03-13-2002 08:53 PM


All times are GMT -6. The time now is 07:50 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.0 RC2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22