thanx David. that did it.
>From: David McKen <ci...@ya...>
>Reply-To: ci...@ya...
>To: dev...@so...
>Subject: Re: [Dev-C++] newbie problem
>Date: Tue, 9 Apr 2002 22:41:46 -0700 (PDT)
>
>I got it to work by moving the declaration above the implementation
>
>all you have to do is move
> > extern "C"
> > {
> > int CeFunction();
> > }
>to just above
> > int CeFunction()
> > {
> > printf("In C mode.\n");
> > return 0;
> > }
>
>--- Kenneth Armstrong <dig...@ho...> wrote:
> > i tried to make a program that uses both c and c++ commands. well,
> > i'm new
> > to this so it didn't work. the error that i got was "call of
> > overloaded
> > 'CeFunction()' is ambiguous". here's my code:
> >
> > #include <stdio.h>
> > #include <iostream.h>
> >
> > int CeFunction()
> > {
> > printf("In C mode.\n");
> > return 0;
> > }
> >
> > extern "C"
> > {
> > int CeFunction();
> > }
> >
> > int main()
> > {
> > cout << "In C++ mode.\n";
> > CeFunction();
> > cout << "Back in C++ mode.\n";
> > return 0;
> > }
> >
> > if someone could explain what i did wrong here i would be very
> > thankful. go
> > easy on me please, i'm a newb. :)
> >
> >
> >
> > _________________________________________________________________
> > Join the worlds largest e-mail service with MSN Hotmail.
> > http://www.hotmail.com
> >
> >
> > _______________________________________________
> > Dev-cpp-users mailing list
> > Dev...@li...
> > https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
>
>
>__________________________________________________
>Do You Yahoo!?
>Yahoo! Tax Center - online filing with TurboTax
>http://taxes.yahoo.com/
>
>_______________________________________________
>Dev-cpp-users mailing list
>Dev...@li...
>https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
_________________________________________________________________
Send and receive Hotmail on your mobile device: http://mobile.msn.com
|