10.07.2015 Views

Analyse syntaxique - LAMP

Analyse syntaxique - LAMP

Analyse syntaxique - LAMP

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Analyse</strong> <strong>syntaxique</strong> par descente récursive<strong>Analyse</strong> <strong>syntaxique</strong> ascendanteGestion des erreurs<strong>Analyse</strong> <strong>syntaxique</strong> d’une grammaire non-contextuelleExemple : <strong>Analyse</strong>ur <strong>syntaxique</strong> EBNFGrammaires LL(1)L’élimination de la récursivité à gauche et la factorisation à gauchemarchent souvent, mais pas toujours.ExempleS = { A }.A = ident ":=" E.E = { ident }.On ne peut pas donner de grammaire LL(1) à ce langage. Mais ilest LL(2), c’est-à-dire qu’il peut être analysé avec 2 symboles lusen avance.De façon générale LL(k) est un sous-ensemble strict deLL(k+1).Mais LL(1) est le seul cas intéressant en pratique.<strong>Analyse</strong> <strong>syntaxique</strong> Martin Odersky 20 de 42

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!