delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/07/02/07:01:48

Message-ID: <395F1910.C5F09372@earthlink.net>
From: Martin Ambuhl <mambuhl AT earthlink DOT net>
Organization: Nocturnal Aviation
X-Mailer: Mozilla 4.73 [en] (Win95; U)
X-Accept-Language: en
MIME-Version: 1.0
Newsgroups: comp.os.msdos.djgpp
Subject: Re: syntax E?r?r?o?r?
References: <go9tls4tdiruq2kv68c5m6f0otoerndr1a AT 4ax DOT com>
Lines: 41
Date: Sun, 02 Jul 2000 10:26:05 GMT
NNTP-Posting-Host: 63.23.142.170
X-Complaints-To: abuse AT earthlink DOT net
X-Trace: newsread2.prod.itd.earthlink.net 962533565 63.23.142.170 (Sun, 02 Jul 2000 03:26:05 PDT)
NNTP-Posting-Date: Sun, 02 Jul 2000 03:26:05 PDT
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com


Radical NetSurfer wrote:
> 
> OK! enough is quite enough for Crying Out Loud!
[ ... ]
> OK!  How is this a Compiler ERROR ?!!?!?!!?!?!?!?!!?!?!?

Which of your many errors did you have in mind:

#include <time.h>               /* mha - to fix illegal use of time_t,
                                   time() */
#include <stdlib.h>             /* mha - to fix incorrect use srand() */
int main(int argc, char **argv)
{
    int retv;
    time_t trnd;                /* mha - to fix illegal placement of
                                   declaration */
    time_t Rseed;               /* mha - to fix illegal use of
                                   undeclared variable */
    retv = 0;                   /* return value from functions */
 /*** Random Number Initialization **********/
    Rseed = time(&trnd);
    srand((unsigned)Rseed);
    return 0;                   /* mha - to fix (C89 illegal, C99 bad
                                   idea) failure to return a value from 
                                   main. */
}

> sheesh! and golly g-willikurs!

I agree.  Your code really is bad, isn't it?


-- 
Martin Ambuhl	mambuhl AT earthlink DOT net

What one knows is, in youth, of little moment; they know enough who
know how to learn. - Henry Adams

A thick skin is a gift from God. - Konrad Adenauer

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019