Path: csiph.com!optima2.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!peer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!news.iecc.com!.POSTED!nerds-end From: Gene Wirchenko Newsgroups: comp.compilers Subject: Re: lex - how to get current file position of parser file Date: Thu, 03 Sep 2015 18:19:01 -0700 Organization: A noiseless patient Spider Lines: 50 Sender: news@iecc.com Approved: comp.compilers@iecc.com Message-ID: <15-09-003@comp.compilers> References: <15-08-019@comp.compilers> <15-09-001@comp.compilers> NNTP-Posting-Host: news.iecc.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit X-Trace: miucha.iecc.com 1441338643 71665 2001:470:1f07:1126:0:676f:7373:6970 (4 Sep 2015 03:50:43 GMT) X-Complaints-To: abuse@iecc.com NNTP-Posting-Date: Fri, 4 Sep 2015 03:50:43 +0000 (UTC) Keywords: parse, yacc Posted-Date: 03 Sep 2015 23:50:43 EDT X-submission-address: compilers@iecc.com X-moderator-address: compilers-request@iecc.com X-FAQ-and-archives: http://compilers.iecc.com X-Received-Bytes: 2697 X-Received-Body-CRC: 2903459948 Xref: csiph.com comp.compilers:1598 On Tue, 1 Sep 2015 14:19:33 +0000 (UTC), Kaz Kylheku wrote: >On 2015-09-01, Jens Kallup wrote: >> Hello, >> >> I used flex, and bison under Linux. But how can I handle multiple >> input files? When I follow the examples of the documentation, I fail >> to handle tokens after include file. >> >> Example: >> >> PRINT "Before" >> SET PROCEDURE TO testproc >> PRINT "After" > >> this is a abstract language, which does (should) open a file called >> "testproc". > >I think that in a dBase-type language, SET PROCEDURE doesn't necessarily have >to open the file at parse time. According to current documentation that It does not have to, but if compiling a project, it will be compiled as well. >I'm able to find, it's actually become a complex module-loading command, and >not parse-time textual inclusion. It can load compiled files, not only text, Yes. >and cause non-persistent files to be unloaded. Loaded files have a refcount so >that if you invoke SET PROCEDURE on some file N times, you have to CLOSE >PROCEDURE that many times before it is unloaded. No. At least, this is not the case in Microsoft Visual FoxPro 9.0. You can not add a procedure file more than once. If you do, it is just ignored. I tried using just the filename and then with the path. The two were recognised as being the same. And, yes, I was using the ADDITIVE keyword. CLOSE PROCEDURE releases *all* of the procedure files. SET PROCEDURE's exact meaning is determined by file contents at run-time. [snip] Sincerely, Gene Wirchenko