Re: [AD] END_OF_MAIN, again |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
- To: alleg-developers@xxxxxxxxxx
- Subject: Re: [AD] END_OF_MAIN, again
- From: Chris <chris.kcat@xxxxxxxxxx>
- Date: Tue, 9 Aug 2005 18:54:13 -0700
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:from:to:subject:date:user-agent:references:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:message-id; b=KtY3iKRqCTm6EPmsEiIPeJuTcNdgWxE71CyiqbZEFueJAu1VKB2OlMfTRZsoZuDAe2L8aEu+80UVzHZhg6TMQZZkMyrzz6FpLnFW0xS1Z+yPKgjin0v+yjlSWZqXp0HeP1xnIvdOfSZVYL1svLykqiKHi+1DcTIKy2wYx2mvgN8=
On Tuesday 09 August 2005 12:18 am, Hrvoje Ban wrote:
> If current language is C++ (#ifdef __cplusplus) it will
> declare _mangled_main(int, char **) as extern "C".
But the user won't be declaring _mangled_main as extern "C", so it'll still be
a regular C++ symbol. And you'd need three, if not four, cppmain.cpp files.
Each one for:
int main();
int main(int argc);
int main(int argc, char **argv);
and possibly:
int main(int argc, char **argv, char **argz);
They'll all produce different symbols in C++, unlike C, so you need to account
for them.