TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Jonathan de Boyne Pollar
from: Paul Marchildon
date: 1995-10-21 03:34:00
subject: Borland Bashing

JP> PE>
JP>   > E.g. how many people don't see 3 things in
JP>   > the following program that make it non-ISO?
JP>   >
JP>   > // Print hello world!
JP>   >
JP>   > void main(int argc, char **argv, char **envp)
JP>   > {
JP>   >     printf("hello world\n");
JP>   > }
JP> PE>
JP> 
JP>   Three ?  I see at least five.
JP> 
JP>   ( Wrong return type for `main', POSIX 1003 extension for environment
JP>     pointer, lack of a return statement in `main', lack of inclusion of
JP>     the  header, and use of C++ comments in a C program. )

PMFJI, but, there is no particular reason why this is C code as
opposed to C++ code. While it does not use ostream_withassign (cout)
for output but rather, the C function printf(...) this is perfectly
valid in C++, since C++ incorporates such C-isms. Perhaps I'm missing
something in the thread.

___
 X KWQ/2 1.2i X If at first you don't succeed, put out another version (KWQ 1.2i)

--- Maximus/2 3.00
* Origin: Sol 3 * Toronto * V.32 * (905)858-8488 (1:259/414)
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: 259/414 400 99 229/2 3615/50 396/1 270/101 712/515 711/808 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™.