Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > The case insensitive #include statement horror...

Reply
Thread Tools

The case insensitive #include statement horror...

 
 
=?iso-8859-1?q?Kirit_S=E6lensminde?=
Guest
Posts: n/a
 
      11-30-2006

Stephan Kuhagen wrote:

> Victor Bazarov wrote:
>
> > You might want to ask in 'microsoft.public.vc.language'... Next time
> > please post all compiler-specific questions (and answers) to the right
> > newsgroup.

>
> Thanks for the advice, I did not know these groups and had no Idea, where to
> ask. - So I posted in microsoft.public.vc.language and related now, but did
> not get an answer. Maybe the problem has no solution. - Although I can not
> really accept that...


<ot>
The underlying NTFS system is case sensitive. I don't know about POSIX
compilers running on Windows (or even about POSIX support on current
Windows platforms), but if you run a POSIX C++ compiler on Windows then
it will have access to the case sensitive filenames (it is the Windows
API which is case in-sensitive, not the file system).

Maybe switching to a POSIX compiler or including one in your Windows
build will get your developers to use the right case. If you're (very)
lucky you may be able to run your Linux/Unix compiler directly under
Windows.
</ot>

I can't help but think though that if the discipline is so poor that
the developers are not able, or willing, to match case on the #includes
then this is simply the most visible of a whole raft of issues that are
in the code they produce.


K

 
Reply With Quote
 
 
 
 
Alf P. Steinbach
Guest
Posts: n/a
 
      11-30-2006
* Stephan Kuhagen:
> rossum wrote:
>
>> If code cannot compile without any errors or warnings, then it should
>> not be released. Maybe a change to your local standards is needed?

>
> The standards are this way, its the (Windows-)programmers brains that are
> not that way...


If the programmers can be required to use certain tools or drivers or
whatever, then they can certainly be required to e.g. use all lowercase
file names.


> If the code has compiler errors, it is not released of course. Getting rid
> of all warnings is impossible,


No, it's a management decision: do we deliver quality or not? Since it
seems that management is not interested in enforcing local standards, it
seems they're squarely in the "or not" camp. Then yes it might be
well-night impossible, futile and detrimental to one's career to strive
for quality, but technically impossible it's certainly not.


> if you have several millions lines of code
> which must compile on 3 platforms with 7 different compilers (WinXP/2k VC6,
> VC7, VC8, Linux GCC 4.0/4.1, MacOSX gcc 4.0 on PPC and i86)...


Right, the VC6 compiler should be removed from the list. That leaves
four compiler (versions) out of the seven.


--
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?
 
Reply With Quote
 
 
 
 
Stephan Kuhagen
Guest
Posts: n/a
 
      11-30-2006
Alf P. Steinbach wrote:

>> if you have several millions lines of code
>> which must compile on 3 platforms with 7 different compilers (WinXP/2k
>> VC6, VC7, VC8, Linux GCC 4.0/4.1, MacOSX gcc 4.0 on PPC and i86)...

>
> Right, the VC6 compiler should be removed from the list.


True, since I often have the feeling, that VC6 is not a C++ compiler at
all...

> That leaves
> four compiler (versions) out of the seven.


Nope, the MacOSX compilers are patched by Apple, so they behave slightly
different than gcc on Linux...

Regards
Stephan

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
check file exists with case sensitive on a case insensitive filesystem Xah Lee Perl Misc 4 04-05-2009 11:21 PM
string.indexof case insensitive Guoqi Zheng ASP .Net 4 01-25-2009 02:07 AM
case insensitive find on case sensitive stl map benhoefer@gmail.com C++ 1 04-06-2007 08:42 PM
how to case select with case-insensitive string ? Tee ASP .Net 3 06-23-2004 07:40 PM
searching lines case-insensitive James Hunt Perl 4 06-05-2004 06:13 PM



Advertisments