473,320 Members | 1,691 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

valid names for pre-processor defines

I dont have the ANSI spec in front of me, can someone please tell the
definition of a valid name for C preprocessor defines?

ie. is it ONLY alphanumerical charactaers and the underscore symbol, or can
I use "-" and other symbols as well?

I'm trying to figure out if a new compiler is behaving itself or not!

Thanks,
Brett.

Jul 23 '05 #1
1 1156
brett wrote:
I dont have the ANSI spec in front of me, can someone please tell the
definition of a valid name for C preprocessor defines?

ie. is it ONLY alphanumerical charactaers and the underscore symbol, or
can I use "-" and other symbols as well?
The rules are the same as for any other identifier: It must start with a
letter or an underscore, followed by letters, underscores and/or numbers.
However, it must not start with an underscore followed by an uppercase
letter or contain two consecutive underscores, since such identifiers are
reserved.
I'm trying to figure out if a new compiler is behaving itself or not!


What's it doing?

Jul 23 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

22
by: MJR | last post by:
Hi, just wondering what options I would have if I wanted to use Python to produce real-time graphs. Is there any plotting package suitable for this. Thanks, Mike
2
by: piraticman | last post by:
Hi. I have some code for a javascript jump menu... It validated with HTML 4.0 but now does not validate with XHTML strict 1.0. I have used name atributes in my code which aparantly are not...
38
by: Jukka K. Korpela | last post by:
As well all know, valid markup is important... but when trying to find a convincing modern argument in favor of this, I found pages like http://www.htmlhelp.com/tools/validator/reasons.html which...
13
by: ima | last post by:
Where can I find a list of valid names for Navigator.AppName?
2
by: Michael Kuzminski | last post by:
I have some xml from a company that usees the same xml tag underneath different nodes. The xml is valid, but ADO.net complains when I try to load it into a dataset. It gives me the error: ...
3
by: Chris | last post by:
Hi, In C# I tried to save a file from a generated file name. Just before launching the dialog I check for a valid file name to be sure. There for I used the method ValidateNames from the save...
4
by: Todd Perkins | last post by:
Hello all, surprisingly enough, this is my first newsgroup post, I usually rely on google. So I hope I have enough info contained. Thank you in advance for any help! Problem: I am getting...
9
by: Alberto | last post by:
Eh unfortunately Google groups does not provide any longer a way to reply to the group for older posts (though the one I am referring to is not older than one month), and I happen to come back to...
6
by: Marcus Kwok | last post by:
I am designing a GUI (my question is not about GUIs) and I have named my variables using a regular naming scheme. However, in order to simplify the code using these variables, I have created an...
16
by: per9000 | last post by:
Hi, I recently started working a lot more in python than I have done in the past. And I discovered something that totally removed the pretty pink clouds of beautifulness that had surrounded my...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.