www.digitalmars.com         C & C++   DMDScript  

c++.windows.32-bits - Previous Definition Different

reply "Stephen De Chellis" <steve hmtk.com> writes:
Hello,

    I'm trying to re-use some of my code in a new app and I've hit a snag
early on...

    I'm getting the "Previous Definition Different" error code when I add in
my common dlg file i/o functions.

    Any help would be much appreciated!
--
Thank You
Stephen De Chellis
steve hmtk.com

www.hmtk.com for HMTK information
www.kenzerco.com for HackMaster information


begin 666 program.zip
M4$L#!!0````(`#!09RW+=8/+_P4``(00```'````9F%I<GDN8ZU7;6_;-A#^
MW +[#]<.Z^S.2]QL+89F&2!+2BU4LCU)J=,% 2%+M,5%%C61SEO7_[ZC1,FR
M+6?[,"9PS'OCO3QW9(Y?_R_KF^??/ =<YP'-'X["<J.S["&GRUC 2;]_`IX 
M64Q2, CH,4D2RJ76OYK^3^M8FOJ6IF&RC C\>D?3B-WQH_BW)C5DJU64+'>H
M J[(-NGEN>,2SM9YB(R73=D%%SD)5CL6*&LE<Q%1MD]+Z'R/F-.T= O)$5G0
ME(!AN9KON] Q#'OFFIHQ=2W?A+]![I%IZO[8_=R5*L?'\"%A\R"!VR"GP3PA
M')8,8I(3R0[C( ?^J&79*%B1JS?]:S #W[STH8.1^A]?=D^54%$])=2_+CZ0
M15.A"NL_9&2?^I$FR3[5IK<MLCY6YB9I84Q)D+'TS2'&2<4HHO5CPDDCV) E
M$8B80!2(`!8Y6S5V%"54?-)_MBC,7OVT$Z",8L+P*Z\DFEP9S6&NBNJP (X(
MV:$KE\KPBIR_W7C48+E!NBR*UL+S$';I4L17;]NX!EF0E*/C#HOH I*\74P3
M( AOGI89K5=SDK-%*<O;A;R,A#1(FIEM-E66,\$$5H!O-U6!P7.LTE&X19:%
M*R3+'$ZMD3:Q8$I3)Z I=(;6R/.UD6Y";*5<!&E(>M  3G)R6S/*>;2[)A[V
M%W_45Y&-'=<#>0S%G1>S.VRL+TIK.!T9M4Y\ET9PJCB.]V%C;<67-0,U=%OS
MO&*#&F$2< ZGU92L24=</"2D-G$&NC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6Z\V\>M/_&E:S0QS1YFFWIRV0G-+'G+Q I_H0YP#)MJL*X"?59[!_KEH8
MT3DV8 9=G3?Y*YQJ9MF8`5U:^=G>/<3148L^Q+9"#:5XA^3 F874G9?1#T6#
MA G[MX =L102O_BW4"HVAA"7=!<IU:PO ]>47.&Z7\A"$V:\T.K;SRW9Y VD
MX,ZM\!*K<'7>^ !02P$"% `4````" `P4&<MRW6#R_\%``"$$ ``!P``````
M```!`" `MH$`````9F%I<GDN8U!+`0(4`!0````(``I"9RW01$IHD ```&0!
M```,``````````$`( "V 20&``!&35)E<V]U<F-E+FA02P$"% `4````" "[
M06<M$/BZO/L```!T` ``" `````````!`" `MH'>! ``1F%I<GDN<F-02P$"
M% `4````" #X1F<M\EW[X1X#``#1# ``! `````````!`" `MH'_!P``9FEL
M92YH4$L!`A0`% ```` `T4QG+>S6KT^"` ``10D```H``````````0` `+:!
M00L``$9-5$M&:6QE+F-02P$"% `4````" !$4&<M,IFZ).<```#Q`0``# ``
M```````!`" `MH'K#0``<')O=&]T>7!E<RYH4$L%! `````&``8`2P$``/P.
$````````
`
end
Nov 07 2002
parent reply "Walter" <walter digitalmars.com> writes:
That message usually means you have the same name defined twice.

"Stephen De Chellis" <steve hmtk.com> wrote in message
news:aqdvne$1j0g$1 digitaldaemon.com...
 Hello,

     I'm trying to re-use some of my code in a new app and I've hit a snag
 early on...

     I'm getting the "Previous Definition Different" error code when I add
in
 my common dlg file i/o functions.

     Any help would be much appreciated!
 --
 Thank You
 Stephen De Chellis
 steve hmtk.com

 www.hmtk.com for HMTK information
 www.kenzerco.com for HackMaster information
Nov 07 2002
parent reply "Stephen De Chellis" <steve hmtk.com> writes:
I understand about defining the same name twice, what I can not figure out
is what I am defining twice! The code is exactly the same as from where I
harvested it from, and I'm not aware of having anything defined!


--
Thank You
Stephen De Chellis
steve hmtk.com

www.hmtk.com for HMTK information
www.kenzerco.com for HackMaster information
"Walter" <walter digitalmars.com> wrote in message
news:aqe42k$1nfv$1 digitaldaemon.com...
 That message usually means you have the same name defined twice.

 "Stephen De Chellis" <steve hmtk.com> wrote in message
 news:aqdvne$1j0g$1 digitaldaemon.com...
 Hello,

     I'm trying to re-use some of my code in a new app and I've hit a
snag
 early on...

     I'm getting the "Previous Definition Different" error code when I
add
 in
 my common dlg file i/o functions.

     Any help would be much appreciated!
 --
 Thank You
 Stephen De Chellis
 steve hmtk.com

 www.hmtk.com for HMTK information
 www.kenzerco.com for HackMaster information
Nov 07 2002
parent reply "Walter" <walter digitalmars.com> writes:
The error message says the name that is defined multiple times. Try grepping
the source code and .h files for the name. -Walter

"Stephen De Chellis" <steve hmtk.com> wrote in message
news:aqefh2$23bu$1 digitaldaemon.com...
 I understand about defining the same name twice, what I can not figure out
 is what I am defining twice! The code is exactly the same as from where I
 harvested it from, and I'm not aware of having anything defined!


 --
 Thank You
 Stephen De Chellis
 steve hmtk.com

 www.hmtk.com for HMTK information
 www.kenzerco.com for HackMaster information
 "Walter" <walter digitalmars.com> wrote in message
 news:aqe42k$1nfv$1 digitaldaemon.com...
 That message usually means you have the same name defined twice.

 "Stephen De Chellis" <steve hmtk.com> wrote in message
 news:aqdvne$1j0g$1 digitaldaemon.com...
 Hello,

     I'm trying to re-use some of my code in a new app and I've hit a
snag
 early on...

     I'm getting the "Previous Definition Different" error code when I
add
 in
 my common dlg file i/o functions.

     Any help would be much appreciated!
 --
 Thank You
 Stephen De Chellis
 steve hmtk.com

 www.hmtk.com for HMTK information
 www.kenzerco.com for HackMaster information
Nov 07 2002
parent reply "Rajiv Bhagwat" <dataflow vsnl.com> writes:
Stephen, you are compiling both fairy.c and fmtkfile.c: This is not
required, as you are including fmtkfile.c inside fairy.c. Just compile
fairy.c, the multiple defn error vanishes.
ie instead of:
sc -mn -cpp fairy.c fmtkfile.c
Just use:
sc -mn -cpp fairy.c

Ideally, avoid such includes.
Also, it is not a good practice to put function source inside a header file,
as you have done in 'file.h'. You will land up in similar trouble if this
header is included in multiple sources. (Such a thing should only be done
for 'inline' or 'template' functions.)
- Rajiv


"Walter" <walter digitalmars.com> wrote in message
news:aqf8sg$2s9n$1 digitaldaemon.com...
 The error message says the name that is defined multiple times. Try
grepping
 the source code and .h files for the name. -Walter

 "Stephen De Chellis" <steve hmtk.com> wrote in message
 news:aqefh2$23bu$1 digitaldaemon.com...
 I understand about defining the same name twice, what I can not figure
out
 is what I am defining twice! The code is exactly the same as from where
I
 harvested it from, and I'm not aware of having anything defined!


 --
 Thank You
 Stephen De Chellis
 steve hmtk.com

 www.hmtk.com for HMTK information
 www.kenzerco.com for HackMaster information
 "Walter" <walter digitalmars.com> wrote in message
 news:aqe42k$1nfv$1 digitaldaemon.com...
 That message usually means you have the same name defined twice.

 "Stephen De Chellis" <steve hmtk.com> wrote in message
 news:aqdvne$1j0g$1 digitaldaemon.com...
 Hello,

     I'm trying to re-use some of my code in a new app and I've hit a
snag
 early on...

     I'm getting the "Previous Definition Different" error code when
I
 add
 in
 my common dlg file i/o functions.

     Any help would be much appreciated!
 --
 Thank You
 Stephen De Chellis
 steve hmtk.com

 www.hmtk.com for HMTK information
 www.kenzerco.com for HackMaster information
Nov 07 2002
parent "Stephen De Chellis" <steve hmtk.com> writes:
Ahhh.... That explains it to me.

I'm rather new at all this, only about 1 year.


--
Thank You
Stephen De Chellis
steve hmtk.com

www.hmtk.com for HMTK information
www.kenzerco.com for HackMaster information
"Rajiv Bhagwat" <dataflow vsnl.com> wrote in message
news:aqfl80$74s$1 digitaldaemon.com...
 Stephen, you are compiling both fairy.c and fmtkfile.c: This is not
 required, as you are including fmtkfile.c inside fairy.c. Just compile
 fairy.c, the multiple defn error vanishes.
 ie instead of:
 sc -mn -cpp fairy.c fmtkfile.c
 Just use:
 sc -mn -cpp fairy.c

 Ideally, avoid such includes.
 Also, it is not a good practice to put function source inside a header
file,
 as you have done in 'file.h'. You will land up in similar trouble if this
 header is included in multiple sources. (Such a thing should only be done
 for 'inline' or 'template' functions.)
 - Rajiv


 "Walter" <walter digitalmars.com> wrote in message
 news:aqf8sg$2s9n$1 digitaldaemon.com...
 The error message says the name that is defined multiple times. Try
grepping
 the source code and .h files for the name. -Walter

 "Stephen De Chellis" <steve hmtk.com> wrote in message
 news:aqefh2$23bu$1 digitaldaemon.com...
 I understand about defining the same name twice, what I can not figure
out
 is what I am defining twice! The code is exactly the same as from
where
 I
 harvested it from, and I'm not aware of having anything defined!


 --
 Thank You
 Stephen De Chellis
 steve hmtk.com

 www.hmtk.com for HMTK information
 www.kenzerco.com for HackMaster information
 "Walter" <walter digitalmars.com> wrote in message
 news:aqe42k$1nfv$1 digitaldaemon.com...
 That message usually means you have the same name defined twice.

 "Stephen De Chellis" <steve hmtk.com> wrote in message
 news:aqdvne$1j0g$1 digitaldaemon.com...
 Hello,

     I'm trying to re-use some of my code in a new app and I've hit
a
 snag
 early on...

     I'm getting the "Previous Definition Different" error code
when
 I
 add
 in
 my common dlg file i/o functions.

     Any help would be much appreciated!
 --
 Thank You
 Stephen De Chellis
 steve hmtk.com

 www.hmtk.com for HMTK information
 www.kenzerco.com for HackMaster information
Nov 08 2002