From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.5-pre1 (2020-06-20) on ip-172-31-74-118.ec2.internal X-Spam-Level: X-Spam-Status: No, score=0.8 required=3.0 tests=BAYES_50,LOTS_OF_MONEY autolearn=ham autolearn_force=no version=3.4.5-pre1 Date: 14 Jan 92 03:13:31 GMT From: csus.edu!wupost!spool.mu.edu!news.cs.indiana.edu!bronze!master.cs.rose-hu lman.edu!zoe.cs.rose-hulman.edu!eigenstr@ucdavis.ucdavis.edu (Todd R. Eigensch ink) Subject: Ada statement Message-ID: <1992Jan14.031331.18320@cs.rose-hulman.edu> List-Id: I'm taking CS404 here, the compilers class, and this quarter, we're compiling a subset of Ada (We're using the book _Crafting_A_Compiler_ by Charles Fischer and Richard LeBlanc, Jr., should anyone care.). I used Ada for two data structures classes last year, but never really thought about this then. And now...the $64,000 question.... Why the HELL is there the NULL statement????????????? There's only one use as far as I can tell...to fill an empty procedure/ function declaration so that the body isn't empty. So why not just allow an empty body? It's not like this is a big deal...compiling that is a piece of cake. Here's the code from my semantic routine to compile said statement: void null_statement(void) { smPopStack(TOSS); /* Remove the semicolon from the semantic stack and heave it. */ smPopStack(TOSS); /* Remove the NULL from the ss and do the same. */ } Hey, don't get on my case just 'cuz I'm writing it in C...I think Ada's tolerable, and I love generic packages, but I just find it a little too restrictive for someone who knows what HE's doing (so shoot me for being politically incorrect) and wants to get something done NOW. I'd be interested to know the reasons for NULL; being there...if you've got anything inflammatory to say, just email it and spare the net the grief. P.S. In case you've got anything nasty to say about writing it in C... we're having it compile to VAX/11 assembler code...Blech! :) Todd Eigenschink eigenstr@CS.Rose-Hulman.Edu /* Another victim of Rose-Hulman propaganda... * And ARA food service. (That rates another Blech!) * */