Re: LL(1) conflict resolution for parameters

jjan@cs.rug.nl (Beeblebrox)
19 Dec 1995 14:25:30 -0500

          From comp.compilers

Related articles
LL(1) conflict resolution for parameters CSPT@giraffe.ru.ac.za (Pat Terry) (1995-12-17)
Re: LL(1) conflict resolution for parameters jjan@cs.rug.nl (1995-12-19)
| List of all articles for this month |
From: jjan@cs.rug.nl (Beeblebrox)
Newsgroups: comp.compilers
Date: 19 Dec 1995 14:25:30 -0500
Organization: Dept. of Computing Science, Groningen University
References: 95-12-095
Keywords: LL(1), attribute

"Pat Terry" <CSPT@giraffe.ru.ac.za> wrote:
<part of syntax snipped>
      Parameter = ( "REF" | "VAL" ) VarIdent (* quite explicit *).
      Argument = Reference | Value .
    The above is not LL(1), because the alternatives for Argument both have
    identifier in their FIRST sets.
>
I would tell my students to use semantic knowledge to restrict Value
in the Argument rule to the correct type of parameter passing as
stored in a proc symbol table. That is you need a parser generator
capable of specifying attributed rules, at least capable of inserting
procedure calls to semantic routines that can do this semantic check.
--
Jan Jongejan email: jjan@cs.rug.nl
Dept. Comp.Sci.,
Univ. of Groningen, 8-{)
Netherlands.
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.