Line Comment Alt case sensitive even if Nocase

Syntax highlighting, code folding, brace matching, code indenting, and function list

Line Comment Alt case sensitive even if Nocase

Postby PaoloFCantoni » Tue May 01, 2007 10:33 am

Is it my imagination or is the Line Comment Alt case sensitive even if Nocase marked for the language?

Can anyone confirm this, before I report the bug?

TIA,

Paolo
User avatar
PaoloFCantoni
Power User
Power User
 
Posts: 113
Joined: Sun May 01, 2005 11:00 pm
Location: Perth, Western Australia

Re: Line Comment Alt case sensitive even if Nocase

Postby Mofi » Tue May 01, 2007 5:22 pm

Yes, the alternate line comment is case-sensitive as all other comment specifications too. For an explanation read the ultimate test for invalid words macro which I have posted today.
User avatar
Mofi
Grand Master
Grand Master
 
Posts: 4054
Joined: Thu Jul 29, 2004 11:00 pm
Location: Vienna

Re: Line Comment Alt case sensitive even if Nocase

Postby PaoloFCantoni » Tue May 01, 2007 7:04 pm

Hi Mofi,
I searched the post and could NOT find:

1) Specific mention of the case sensitivity of Comment specifications
2) A reason for why this is so (in the case of a Nocase language specification)

Thanks for confirming the observation. However, why is it NOT a bug It seems inconsistent to me.

(BTW: Great posting!)
Paolo
User avatar
PaoloFCantoni
Power User
Power User
 
Posts: 113
Joined: Sun May 01, 2005 11:00 pm
Location: Perth, Western Australia

Re: Line Comment Alt case sensitive even if Nocase

Postby Mofi » Wed May 02, 2007 6:54 am

A text file is parsed first for lines, then comments, then strings and then words with the delimiter set which are always not case sensitive. The words are then according to Nocase compared with strcmp or stricmp (or however the C++ function names are for string comparison) or convert every string to lowercase before comparing strings which I think UE really does.

The line termination, comments, strings and delimiter characters are normally not letters and so case sensitivity is not important.

When Nocase should be also active before splitting the files into comments, strings and words then a program like UE has according to this setting convert all its strings in its buffers to lowercase and also the content of the file while parsing it.

Well, that would be possible, but is currently not the case. You can interpret it as a bug. That's up to you. Sent a bug report email to IDM support. If the developers share your point of view, they will maybe change it.
User avatar
Mofi
Grand Master
Grand Master
 
Posts: 4054
Joined: Thu Jul 29, 2004 11:00 pm
Location: Vienna

Re: Line Comment Alt case sensitive even if Nocase

Postby PaoloFCantoni » Wed May 02, 2007 10:21 am

Mofi wrote:The line termination, comments, strings and delimiter characters are normally not letters and so case sensitivity is not important.

This isn't true of the various Basic dialects also many SQL dialects.

I will report a bug and hope for the best...

Thanks again Mofi,
Paolo
User avatar
PaoloFCantoni
Power User
Power User
 
Posts: 113
Joined: Sun May 01, 2005 11:00 pm
Location: Perth, Western Australia


Return to Syntax Highlighting