www.digitalmars.com         C & C++   DMDScript  

c++ - Bug: sc.ini CFLAGS macro name length - Examples.txt

Description: If CFLAGS="-DMACRO_NAME=" is used in dm\bin\sc.ini; problems occur
when the macro name length is 44-46, 50, or 51 characters.  Nope, I didn't test
all cases of 1-1024 character lengths.  I just got, er, lucky with a macro name
that caused me to look a tad further.

Expected results:  Using CFLAGS="-Dmacro=" should be the same as setting the
macro from the command line.
E.g. This command works fine:  dmc -v2
-DMACRO_NAME_THATS_44_CHARACTERS_XXXXXXXXXXXXX= test.cpp
See \dm\html\ctg\ctgLanguageImplementation.html#cpp_language, under the heading
"Internal Limits"
\dm\html\ctg\smake.html, under the heading "Defining Macros"
The above 2 docs are not _exactly_ concerning dmc.exe; but I'll make reference
to them none the less.

How to replicate:

1. In sc.ini, set CFLAGS="-DMACRO_NAME_THATS_44_CHARACTERS_XXXXXXXXXXXXX="
2. dmc -v2 test.cpp

OS: XP w/ sp 2
Compiler: Digital Mars CD v 8.42, with cd843.zip

Apologia if this turns out to be user misunderstanding.


begin 0644 Examples.txt
M17AA;7!L92`Q. T*=VET:"!#1DQ!1U,](BU$34%#4D]?3D%-15]42$%44U\T
M-%]#2$%204-415)37UA86%A86%A86%A86% ]( T*#0H^9&UC("UV,B!T97-T
M+F-P<`T*<V-P<&X +41-04-23U].04U%7U1(05137S0T7T-(05)!0U1%4E-?
M6%A86%A86%A86%A86#T +78R(&QI8 T*1&EG:71A;"!-87)S($,O0RLK($-O
M;7!I;&5R(%9E<G-I;VX ."XT,RXV; T*0V]P>7)I9VAT("A#*2!$:6=I=&%L
M($UA<G, ,C`P,"TR,#`T+B` 06QL(%)I9VAT<R!297-E<G9E9"X-"E=R:71T
M96X 8GD 5V%L=&5R($)R:6=H=`T*=W=W+F1I9VET86QM87)S+F-O;0T*1F%T
M86P 97)R;W(Z('5N86)L92!T;R!O<&5N(&EN<'5T(&9I;&4 )VQI8B<-" T*
M#0I%>&%M<&QE(#(Z#0IW:71H($-&3$%'4STB+41-04-23U].04U%7U1(0513
M7S0V7T-(05)!0U1%4E-?6%A86%A86%A86%A86%A8/2(-" T*/F1M8R`M=C( 
M=&5S="YC<'`-"G-C<'!N("U$34%#4D]?3D%-15]42$%44U\T-E]#2$%204-4
M15)37UA86%A86%A86%A86%A86#T +78R(&(-"BXN+B!%>'1R82!L:6YE<R!R
M96UO=F5D("XN+ T*1F%T86P 97)R;W(Z('5N86)L92!T;R!O<&5N(&EN<'5T
M(&9I;&4 )V(G#0H-" T*17AA;7!L92`S. T*=VET:"!#1DQ!1U,](BU$34%#
M4D]?3D%-15]42$%44U\T-U]#2$%204-415)37UA86%A86%A86%A86%A86% ]
M( T*#0H^9&UC("UV,B!T97-T+F-P<`T*<V-P<&X +41-04-23U].04U%7U1(
M05137S0W7T-(05)!0U1%4E-?6%A86%A86%A86%A86%A86#T +78R('1E<W0N
M8W!P#0HN+BX 17AT<F$ ;&EN97, <F5M;W9E9"`N+BX-"FQI;FL =&5S="PL
M+'5S97(S,BMK97)N96PS,B]N;VD[#0H-" T*#0I%>&%M<&QE(#0Z#0IW:71H
M($-&3$%'4STB+41-04-23U].04U%7U1(05137S4Q7T-(05)!0U1%4E-?,C,T
M-38W.#ED,3(S-#4V-S Y93$]( T*#0H^9&UC("UV,B!T97-T+F-P<`T*<V-P
M<&X +41-04-23U].04U%7U1(05137S4Q7T-(05)!0U1%4E-?,C,T-38W.#ED
M,3(S-#4V-S Y93$]("UV,B`X.64Q/0T*+BXN($5X=')A(&QI;F5S(')E;6]V
M960 +BXN#0I&871A;"!E<G)O<CH =6YA8FQE('1O(&]P96X :6YP=70 9FEL
+92`G.#EE,3TG#0IA
`
end
May 13 2005