Advertisement
Guest User

Untitled

a guest
Nov 21st, 2017
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.38 KB | None | 0 0
  1. /**
  2. * Grammaire de l'interpreteur
  3. * <SuiteDonnee> → <Donnee> | <SuiteDonnee><Donnee>
  4. * <Donnee> → <Decl>; | <Instr>; | <Directive>
  5. *
  6. * <Decl> → <TypeVar><Nom> = <Expr1>
  7. * <Instr> → <Nom> = <Expr1>
  8. *
  9. * <Directive> → <Directive2> { <SuiteDonnee> }
  10. * <Directive2> → <for> | <while> | <if> | <else>
  11. * <for> → for ( <Decl>; <Condition>; <Expr1>)
  12. * <while> → while (<Condition>)
  13. * <if> → if (<Condition>)
  14. * <else> → else
  15. *
  16. * <Condition> → <Condition2> | (<Condition>)
  17. * <Condition2> → <Condition3> | <Condition2> || <Condition> | <Condition2> && <Condition>
  18. * <Condition3> → <Expr1> < <Expr1> | <Expr1> <= <Expr1> | <Expr1> > <Expr1> | <Expr1> >= <Expr1> | <Expr1> == <Expr1>
  19. *
  20. * <Expr1> → <Expr2> | <Expr1> '|' <Expr2>
  21. * <Expr2> → <Expr3> | <Expr2> & <Expr3>
  22. * <Expr3> → <Terme> | <Expr3> + <Terme> | <Expr3> − <Terme>
  23. * <Terme> → <Opbinaire> | <Terme> * <Opbinaire> | <Terme> / <Opbinaire>
  24. * <Opbinaire> → <Facteur> | -<Facteur> | ~<Facteur>
  25. * <Facteur> → ( <Expr1> ) | <Data>
  26. *
  27. * <Data> → <Var> | <Nombre>
  28. * <Var> → <Nom> | ++<Nom> | <Nom>++ | --<Nom> | <Nom>--
  29. * <Nom> → <NomPredefini> | <Lettre> | <Nom><Caractere>
  30. * <Caractere> → <Lettre> | <Chiffre>
  31. *
  32. * <NomPredefini>→ C1 | C2 | C3 //TODO METTRE LES NOMS DE CAPTEURS & ACTUATEURS ATTENTION CAPTEUR ON PEUT PAS FAIRE C1 = 1 par exemple!!
  33. *
  34. * <Nombre> → <Decimal> | <Flottant> | 0x<HexaDecimal>
  35. * <Flottant> → <Decimal>.<Decimal>
  36. * <Decimal> → <Chiffre> | <Decimal><Chiffre>
  37. * <HexaDecimal> → <ChiffreHexa> | <HexaDecimal><ChiffreHexa>
  38. * <ChiffreHexa> → <Chiffre> | A | B | C | D | E | F
  39. * <Chiffre> → 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
  40. * <Lettre> → A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z | a | b | c | d | e | f | g | h | i | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | v | w | x | y | z
  41. * <TypeVar> → int | float
  42. *
  43. */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement