22 Commits

Author SHA1 Message Date
Pierre-Marie de Rodat
ed8a12c302 Fix language name casings in manage.py scripts
... and do the necessary adjustments in the rest of the codebase.
2021-09-24 12:07:42 +02:00
Pierre-Marie de Rodat
45445a1544 Enable warnings by default in Libpythonlang and Liblktlang
TN: TC14-031
2020-12-15 14:28:46 +01:00
Raphaël AMIARD
e21ff492fa T511-017: make stylechecks work with pycodestyle 2020-06-02 13:22:02 +02:00
Pierre-Marie de Rodat
2b9b33d6a0 Remove __future__ imports and adjust stylechecks
TN: T511-017
2020-05-26 12:33:48 +02:00
Pierre-Marie de Rodat
0e2868fd02 dsl_unparse: stop relying on the string_escape encoding
That encoding is no longer available in Python3, so roll our own
temporary implementation (before we can get rid of dsl_unparse). Also
remove useless backslashes in the Python grammar.

TN: T511-017
2020-05-26 12:33:48 +02:00
Pierre-Marie de Rodat
8817669523 Revert "contrib/python: do not use Ignore in the lexer"
This reverts commit 8d8137610a.

This change had unintended consequences: the indentation tracking
machinery interacts interfers with the trivia production for
whitespaces, breaking Python code parsing. Revert for now, until we have
a plan to more forward. This change was mostly cosmetic anyway (no real
need to preserve whitespaces for the Python parser).

TN: T107-050
2020-01-08 11:58:04 +01:00
Pierre-Marie de Rodat
8d8137610a contrib/python: do not use Ignore in the lexer
TN: T107-050
2020-01-07 17:52:01 +01:00
Pierre-Marie de Rodat
3dd788055d Sort imported entitities in all Python scripts
TN: S425-011
2019-04-25 14:39:56 +02:00
Romain Beguet
0dd1f1bbd6 S418-018: Refactor add_to_env.
- "env_assoc"s now take themselves the dest_env and the metadata info.
- Add add_to_env_kv and new_env_assoc to simplify common usage.
2019-04-25 11:51:59 +02:00
Pierre-Marie de Rodat
5ac1a19c20 contrib/python: do not use the Eof lexer matcher
TN: R913-030
2019-02-08 17:54:23 +01:00
Pierre-Marie de Rodat
1b48a52d2d Replace Quex with our own lexer generator
TN: R913-030
2019-02-07 17:44:36 +01:00
Romain Beguet
42a7dacb91 S121-011: Revise enum node definition mechanism.
Instead of using Python's inheritance mechanism to define enum nodes,
the new mechanism requires adding enum_node = True to the class' body.
Inheritance can now be used to make the enum node derive from any
subclass of ASTNode instead ASTNode itself.
2019-02-07 12:54:10 +01:00
Pierre-Marie de Rodat
cc63ebf2c0 contrib/python: make BinOp abstract instead of synthetic
TN: S121-029
2019-01-25 17:48:42 +01:00
Pierre-Marie de Rodat
a50ba54b6d contrib/python: fix a compilation warning
TN: R807-033
2018-08-16 12:16:02 +02:00
Pierre-Marie de Rodat
86c9702c5b contrib/python: remove obsolete List() keyword argument
TN: R807-033
2018-08-16 12:16:02 +02:00
Raphael Amiard
d70b094f44 Simplify python tree #11 no-tn-check
Change-Id: I8ad7b67d65a71fdf0348e29746dbf05a11c7b62e
2018-02-06 17:04:53 +01:00
Raphael Amiard
eff6f179c2 Update python engine #11 no-tn-check
Change-Id: I0789d223ad0439ffbcd0425a68c11115d8fecbc2
2018-02-06 17:04:53 +01:00
Pierre-Marie de Rodat
b06154a326 contrib/python: update parser to use token nodes only
TN: R125-040
2018-01-29 12:09:56 +01:00
Pierre-Marie de Rodat
abb941feec Parsers: keep parsed tokens by default
Also simplify token parsers throughout all the testsuite.

TN: R125-040
2018-01-29 12:09:07 +01:00
Pierre-Marie de Rodat
37926039ed contrib/python: minor refactoring
(no-tn-check)
2018-01-29 12:09:07 +01:00
Pierre-Marie de Rodat
2098fe35e9 contrib/python: turn plain boolean into EnumNode qualifiers
TN: R125-011
2018-01-25 17:57:08 +01:00
Raphael Amiard
026ae0310e Add python parser in contrib/ - #11 no-tn-check
Change-Id: I7d46014caccbf45d4a23a6b46b90193d5139dcfc
2018-01-21 14:51:15 +01:00