TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Paul Edwards
from: Philipp Thomas
date: 1995-10-08 19:16:40
subject: C Set ++

Thursday October 05 1995 22:04, you wrote to Murray Lesser:

Paul,

 PE> There is no requirement for this, unless they interfere with the
 PE> namespace of the resultant executable.

If you take ANSI Standard seriously, it is required that non ansi library
functions be marked as such.

MS C, when compiling with MS extensions, implicitly links in oldnames.lib
which just comtains function aliases to map the names to their underscore
form. When compiling strict ANSI, you have to write the functions in their
underscore form.

CSET uses pragmas to map the names to their underscore form.

Borland doesn't seem to do any, but at least 3.1 (the last BC I used) was
so stubborn to simply put the non ansi prototypes in ifdefs that make them
disappear when compiling ansi conforming (with an ifdef __STDC__) and the
Borland programmers topped that with a comment in the headers "who
uses these functions doesn't write standard C anyway, so let's keep the
name space clean".

You can't imagine how I was cursing when trying to port some GNU stuff,
because for most *NIX code, __STDC__ has to be defined to get prototypes
and/or headers like stdlib.h included. I went through all BC headers and
eliminated all these stupid ifdefs.

Compared to this behaviour, I vastly prefer the approach of MSC or CSET.


                                                     Philipp


... But he who knows, and knows that he knows, is a wise man. Follow him.

--- GoldED/2 2.50.Beta6+
* Origin: Time Bandit, watch your Time or ... (2:2437/221)
SEEN-BY: 270/101 620/243 711/401 409 410 413 430 807 808 809 934 955 712/407
SEEN-BY: 712/515 628 704 713/888 800/1 7877/2809
@PATH: 2437/221 200 501 2461/200 24/999 2/777 396/1 270/101 712/515 711/808
@PATH: 711/809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.