🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: net.bugs
Article #326

What gives with Lex(1) & structures

#326
From: george
Date: Thu, 25 Oct 1984 01:45
42 lines
1596 bytes
While using Lex(1), I have noticed the following:

If you make a declaration of the form

------------------------------------------------------------------------
extern decls
%%
   struct ident {
      char name[32];
      .
      .
      .
      struct ident *link;
   } struct ident *header;
rules     actions
%%
Whatever else is needed.
EOF
------------------------------------------------------------------------

Lex(1) will generate a C program with the folowing in it.




------------------------------------------------------------------------
exern decls
   struct ident {
      char name[32];
      .
      .
      .
      struct ident *link;
   }
+the rest of the standard Lex(1) program.

------------------------------------------------------------------------
What happens to the "struct ident *header;" portion of the declaration?

     If anybody has had the same problem please post your experiences.

george [in real life Gregg Wonderly]@okstate
Technical Details
Message-ID: <25600002@okstate.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!ulysses!mhuxj!ihnp4!inuxc!pur-ee!uiucdcs!okstate!george

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: Notesfiles $Revision: 1.6.2.17 $; site okstate.UUCP
Path: arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!ulysses!mhuxj!ihnp4!inuxc!pur-ee!uiucdcs!okstate!george
From: george@okstate.UUCP
Newsgroups: net.bugs
Subject: What gives with Lex(1) & structures
Message-ID: <25600002@okstate.UUCP>
Date: Wed, 24-Oct-84 20:45:00 EST
Article-I.D.: okstate.25600002
Posted: Wed Oct 24 20:45:00 1984
Date-Received: Sun, 28-Oct-84 06:55:39 EST
Lines: 43
Nf-ID: #N:okstate:25600002:000:967
Nf-From: okstate!george    Oct 24 14:45:00 1984