Re: Trouble with IADs



* SvenC:
Hi Alf,

Don't use "bare" string literals with functions that expect
TCHAR's. Wrap literals with _T() macro.

In my humble opinion the "bare" strings are much, much better than
using those macros.

There is absolutely no good reason that I know of to use the _T
macros. They don't provide anything in modern Windows programming,
and I mean exactly zero, with regard to positive things. But there
are many good reasons to avoid them ...

How do you write code that compiles for Unicode as well as Ansi builds
without the _T macro?
What are you good reasons to avoid _T?

To quote myself from the article you responded to here (it's a good to read what you respond to, hint hint):

<q>
If compatibility with Windows 9x is required, consider using Microsoft's Layer for Unicode instead of the insane _T macros.
</q>

Why would you ever want an ANSI build (less efficient, loss of functionality)?

It doesn't make sense at all to me, but perhaps I haven't heard the argument you have in mind.


Cheers, & hth.,

- Alf

--
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?
.



Relevant Pages

  • Re: macro with variable length of argument
    ... Anyhow, I never found a compiler that did not understand inline (yes, a few ... maybe this is the reason you attribute 'macros are evil' to C++ since ... in C++ 'inline' is part of the language and constants can be used to ... so two possible reasons that you need them are gone. ...
    (comp.lang.c)
  • Re: Trouble with IADs
    ... They don't provide anything in modern Windows programming, ... What are you good reasons to avoid _T? ... Microsoft's Layer for Unicode instead of the insane _T macros. ...
    (microsoft.public.vc.language)
  • Re: Virus for Word
    ... contain executable code, called macros. ... reasons, which, fortunately, is becoming less and less. ... serious writing in TeX: ... creating Word documents so I do almost all of my original writing ...
    (microsoft.public.mac.office.word)
  • Re: Why avoid constants as macros?
    ... > what are some good reasons to avoid using macros to define constants, ... The same reason that macros should be avoided in general: ...
    (microsoft.public.vc.language)
  • Re: Why avoid constants as macros?
    ... > what are some good reasons to avoid using macros to define constants, ... Another reason you shouldn't use macros is they aren't debuggable. ... debugging because you can actually see what their values are. ...
    (microsoft.public.vc.language)

Loading