C preprocessor function macros with empty aguments

  • Thread starter Sabyasachi Basu
  • Start date
S

Sabyasachi Basu

You might be best off rewriting your macros, and thus the macro
calls, for portability. Remember that macros perform text
replacement, and that the components must be suitable language
components. You could put tests in the actual macros to
eliminate specific arguments, using #if statements. Then the
calls might be something like:

B(NULL, "Hello world");

How do I use #if directives to put tests in the actual macros? Arent
preprocessor directives disallowed within macro definitions?
 
C

Carl Daniel [VC++ MVP]

Jack said:
Not surprised.

According to VC team members I've talkd to, there's close to zero customer
interest in C99 conformance. The commonly mentioned exceptions being
variadic macro arguments and the standardized fixed-sized integer types.

-cd
 
R

Randy Howard

According to VC team members I've talkd to, there's close to zero customer
interest in C99 conformance. The commonly mentioned exceptions being
variadic macro arguments and the standardized fixed-sized integer types.

Interesting. I've been an MSDN subscriber for as long as the program has
been in place and I've never been asked once what I'd like to see in the
next release of any product. How do they know? Do you have to email some
spamtrap address at Microsoft to get this type of thing requested?
 
R

Ron Natalie

Randy Howard said:
Interesting. I've been an MSDN subscriber for as long as the program has
been in place and I've never been asked once what I'd like to see in the
next release of any product. How do they know? Do you have to email some
spamtrap address at Microsoft to get this type of thing requested?

I've never got asked either. But I've long contended both in the microsoft.*
forums and to any Microsoft employee who asked that standards compliance
is fairly high up there on my list of concerns.
 
A

Alexander Grigoriev

I wonder what valuable features except variadic macro arguments C99 gives? I
don't quite understand a reason for evolving C.
Want 'complex' type - go for C++, want variable-sized arrays - go for C++,
etc.
 
L

LibraryUser

Randy said:
(e-mail address removed) says...


Interesting. I've been an MSDN subscriber for as long as the
program has been in place and I've never been asked once what
I'd like to see in the next release of any product. How do they
know? Do you have to email some spamtrap address at Microsoft
to get this type of thing requested?

I suspect that the real meaning of "customer interest" is
"compliance doesn not enhance Microsoft domination" and/or
"compliance would encourage use of non-Microsoft software in the
marketplace".
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,078
Messages
2,570,572
Members
47,204
Latest member
MalorieSte

Latest Threads

Top