TatSu 5.6.0 released

2021-03-21 Thread Juancarlo Añez
竜 TatSu is a tool that takes grammars in a variation of EBNF as input, and
outputs memoizing (Packrat) PEG parsers in Python.
竜 TatSu inspired the PEG parser in Python 3.9.

New in 竜 TatSu 5.6.0

*   Several important refactorings in ``contexts.ParseContext``
*   Make ``ignorecase`` settings apply to defined ``@@keywords``
*   Move checking of keywords used as names into ``ParseContext``
*   Output of generated parsers again matches that of model parsers
*   Improve *"expecting one of:"* messages so elements are in declaration
order
*   Stop code generation if there are closures over possibly empty
expressions
*   Preserve name declaration order in returned ``AST``
*   Update the bootstrap parser (``tatsu/bootstrap.py``) to the generated
parser
*   Now generated parser's ``main()`` only outputs the JSON for the parse
``AST``
*   Minor version bumped in case the many fixes break
backwards-compatibility
*   Minor documentation issues fixed
*   All tests run with Python 3.8, 3.9, 3.10

https://pypi.org/project/tatsu/
https://tatsu.readthedocs.io/en/stable/
https://github.com/neogeny/TatSu

---
___
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/
Member address: arch...@mail-archive.com


[Python-announce] TatSu 5.7.0

2021-12-06 Thread Juancarlo Añez
TatSu 5.7.0 is now available.

   - https://pypi.org/project/TatSu/5.7.0/
   - https://tatsu.readthedocs.io/
   - https://github.com/neogeny/TatSu


竜 TatSu is a tool that takes grammars in a variation of EBNF as input, and
outputs memoizing (Packrat) PEG parsers in Python.

竜 TatSu can compile a grammar stored in a string into a
tatsu.grammars.Grammar object that can be used to parse any given input,
much like the *re* module does with regular expressions, or it can generate
a Python module that implements the parser.

竜 TatSu supports left-recursive rules in PEG grammars using the algorithm
by Laurent and Mens. The generated AST has the expected left associativity.

CHANGELOG:

   - Now ``config: ParserConfig`` is used in ``__init__()`` and ``parse()``
   methods of ``contexts.ParseContext``, ``grammars.Grammar``, and elsewhere
   to avoid long parameter lists. ``ParserConfig` also provides clean and
   clear ways of overriding a group of settings
   - All names defined in the successful choice in a rule are now defined
   in the resulting AST. Names within optionals that did not match will have
   their values set to ``None``, and closures that did not match will be set
   to ``[]`
   - Moved build configuration from ``setup.py`` in favor of ``setup.cfg``
   and ``pyproject.toml`` (@KOLANICH_)
   - ``Node.children()`` is now computed only when required, and cached
   - Classes in generated object models are now ``@dataclass``
   - Optimize and get rid of bugs and annoyances while keeping backwards
   compatibility
   - Drop support for Python < 3.10
___
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/
Member address: arch...@mail-archive.com


[Python-announce] TatSu 5.8.0 released

2022-03-15 Thread Juancarlo Añez
竜 TatSu is a tool that takes grammars in a variation of EBNF as input, and
outputs memoizing (Packrat) PEG parsers in Python.

竜 TatSu can compile a grammar stored in a string into a
tatsu.grammars.Grammar object that can be used to parse any given input,
much like the re module does with regular expressions, or it can generate a
Python module that implements the parser.

竜 TatSu supports left-recursive rules in PEG grammars using the algorithm
by Laurent and Mens. The generated AST has the expected left associativity.

This release adds optimizations and solves obscure bugs and
backwards-compatibility issues.

See the changelog at:

https://github.com/neogeny/TatSu/releases/tag/v5.8.0

--
Juancarlo Añez
mailto:apal...@gmail.com
___
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/
Member address: arch...@mail-archive.com


[Python-announce] 竜 TatSu 5.8.1

2022-07-11 Thread Juancarlo Añez
竜 TatSu is a tool that takes grammars in a variation of EBNF as input, and
outputs memoizing (Packrat) PEG parsers in Python.

This release provides a set of bug fixes, optimizations, and code
modernizations.

   - https://github.com/neogeny/TatSu
   - https://tatsu.readthedocs.io/en/stable/

--
Juancarlo Añez
mailto:apal...@gmail.com
___
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/
Member address: arch...@mail-archive.com


[Python-announce] TatSu v5.9.0 - PEG parser generator

2023-10-22 Thread Juancarlo Añez
竜 TatSu is a tool that takes grammars in a variation of EBNF as input, and
outputs memoizing (Packrat) PEG parsers in Python.

Why use a PEG parser? Because regular languages (those parsable with
Python's `re` package) "cannot count". Any input with nested structures or
with balancing of demarcations requires more than regular expressions to be
parsed.

竜 TatSu can compile a grammar stored in a string into a
`tatsu.grammars.Grammar` object that can be used to parse any given input,
much like the `re` module does with regular expressions, or it can generate
a Python module that implements the parser.

On this release:


   - validate with Python 3.12 (#313
   <https://github.com/neogeny/TatSu/pull/313>)
   - drop support for Python 3.10 (#313
   <https://github.com/neogeny/TatSu/pull/313>)
   - move build configuration to pyproject.toml (#316
   <https://github.com/neogeny/TatSu/pull/316> #317
   <https://github.com/neogeny/TatSu/pull/317>)
   - evaluate constant to a Python literal when possible (#304
   <https://github.com/neogeny/TatSu/issues/304> #320
   <https://github.com/neogeny/TatSu/pull/320>)
   - fix comments_re and eol_comments_re so they effectively can be None (
   #307 <https://github.com/neogeny/TatSu/pull/307> #312
   <https://github.com/neogeny/TatSu/issues/312> #314
   <https://github.com/neogeny/TatSu/pull/314>)
   - skip over whitespace and comments before memoizing (#305
   <https://github.com/neogeny/TatSu/issues/305> #306
   <https://github.com/neogeny/TatSu/pull/306> #309
   <https://github.com/neogeny/TatSu/pull/309> #318
   <https://github.com/neogeny/TatSu/pull/318>)
   - verify that () parses to None or is ignored (#308
   <https://github.com/neogeny/TatSu/pull/308>)


--
Juancarlo Añez
mailto:apal...@gmail.com
___
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/
Member address: arch...@mail-archive.com


[Python-announce] Late 1.0.0 - late bound arguments

2023-11-11 Thread Juancarlo Añez
*Late* provides decorators and functions to work around the issues that
early binding of default argument values produces in Python.

@latebinding
def f(x: list[Any] = __([])) -> list[Any]:
x.append(1)
return x

assert f() == [1]
assert f() == [1]
assert f() == [1]

https://pypi.org/project/Late/

-- 
Juancarlo *Añez*
mailto:apal...@gmail.com
___
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/
Member address: arch...@mail-archive.com


[Python-announce] Late 1.2.2 released

2023-11-23 Thread Juancarlo Añez
*包 Late* provides decorators and functions to work around the issues that
early binding of default argument values produces in Python.
https://github.com/neogeny/late

--
Juancarlo Añez
mailto:apal...@gmail.com
___
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/
Member address: arch...@mail-archive.com


[Python-announce] TatSu 5.10.2 - PEG parser generator

2023-11-23 Thread Juancarlo Añez
竜 TatSu is a tool that takes grammars in a variation of EBNF as input, and
outputs memoizing (Packrat) PEG parsers in Python.

Please take a look at the release log for the latest improvements and fixes:

https://github.com/neogeny/TatSu/releases

--
Juancarlo Añez
mailto:apal...@gmail.com
___
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/
Member address: arch...@mail-archive.com


Grako 3.7.0 released

2016-03-11 Thread Juancarlo Añez
Grako (for grammar compiler) is a tool that takes grammars in a variation
of EBNF as input, and outputs memoizing (Packrat) PEG parsers in Python.

In this release:

* Added suport for `constant` expressions which don't consume any input yet
return the specified constant.
* Now an empty closure ({}) consumes no input and generates an empty list
as AST.
* Removed the --binary command-line option. It went unused, it was
untested, and it was incorrectly implemented.
* Generated parsers pass on KeyboardInterrupt.
* Moved the bulk of the entry code for generated parsers to
util.generic_main(). This allows for the verbose code to be verified by the
usual tools.
* Deprecate {e}* and {e}- by removing them from the documentation.
* Added the Python-inspired join operator, s.{e}, as a convenient syntax
for parsing sequences with separators.

Links:

https://pypi.python.org/pypi/grako/
https://bitbucket.org/apalala/grako/

-- 
Juancarlo *Añez*
tel:+58(414)901-2021
skype:juancarloanez
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


ANN: Grako 3.12.1

2016-08-08 Thread Juancarlo Añez
Grako (for grammar compiler) is a tool that takes grammars in a variation
of EBNF as input, and outputs memoizing (Packrat) PEG parsers in Python.

Changes in 3.12.1:

   - Distinguish between positive and normal joins: s.{e}+ and s.{e}.
   Having s.{e} use a positive closure was too unexpected.
   - Also generate a buffering.Buffer descendant specific to the grammar
   for parsers that need to customize the parsing.Parser.parse() method.
   - Added the grako.synth module which makes synthetic grako.model.Node
   classes pickable.
   - Traded memory for simplicity and replaced the line-based line cache in
   buffering.Buffer for a position-based cache. Buffering needs to continue
   being str-based for complex re patterns to work as expected.
   - Now patterns may be concatenated to split a complex pattern into
   parts, possibly accross several lines: /regexp/ + /regexp/.
   - Added basic support for symbol tables in grako.symtables.
   - Now model.ParseModel is an alias for model.Node.
   - Improved examples/antlr2grako so it generates more usable Grako
   grammars.
   - Syntax file for Sublime Text (vmuriart).
   - The latest changes to grako.util.trim() were incomplete.
   - Fixed several inconsistencies in the implementation and use of
   buffering.Buffer line indexing.
   - Repeated parameters to object model constructors.



-- 
Juancarlo *Añez*
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


Grako 3.16.0 released

2016-10-03 Thread Juancarlo Añez
*Grako* (for *grammar compiler*) is a tool that takes grammars in a
variation of EBNF  as input, and outputs
memoizing  (Packrat
) PEG
 parsers in Python
.
3.16.0
 @
2016-10-01
Added

   - Test and publish *Grako* using Travis CI .
   - Added support for case-insensitivity to grako.symtables.
   - A base class can now be specified along with the object model class
   name in grammar rules.

integer::Integer::Literal

Changed

   - Reduced the memory used by symbol tables by replacing
   symtables.SymbolReference by the referencing objectmodel.Node.
   - Now grako.grammars.Decorator is public.
   - Demoted support for *left recursion* to *experimental*. It has been
   reported that even some simple cases are not handled correctly.
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


Grako 3.20.0 released

2017-04-10 Thread Juancarlo Añez
Added

   -

   Added grako.compile(grammar, name=None, **kwargs) as a substitute for
   grako.genmodel (which remains for backwards compatibility).
   -

   Added a grako.parse(grammar, input, **kwargs) that will compile a
   grammar and uset to parse the given input. For efficiency, parsed grammars
   are cached.
   -

   Added a grako.to_python_sourcecode(grammar, name=None, filename=None,
   **kwargs) that compiles the grammar to the Python sourcecode that
   implements the parser.
   -

   Rename the existing *join* (.{}) expression to *gather*, and use *join* for
   a new expression (%{}) that keeps the separator in the resulting AST.
   -

   Added left-join (<{}) and right-join (>{}) expressions to the grammar.

Changed

   -

   Enable python setup.py test with pytest.
   -

   Remove the deprecated prefix= argument to ParseContext.closure().
   -

   Document that *Grako* may be used as a library (with no code generation)
   by compiling grammars to Grammar objects that can be used to parse any
   given input, much like Python's re does with regular expressions.
   -

   Refactored grammar so double naming (name1:name2:exp) is disallowed.

Grako 3.20.0 <https://pypi.python.org/pypi/grako/3.20.0>

*Grako* (for *grammar compiler*) is a tool that takes grammars in a
variation of EBNF as input, and outputs memoizing (Packrat) PEG parsers
in Python.

*Grako* can also compile a grammar stored in a string into a
grako.grammars.Grammar object that can be used to parse any given input,
much like the *re* module does with regular expressions.
https://pypi.python.org/pypi/grako/3.20.0

https://bitbucket.org/neogeny/grako/

-- 
Juancarlo *Añez*
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


Grako 3.21.0

2017-04-17 Thread Juancarlo Añez
Grako 3.21.0
==

-  Name all _"info"_ as `...Info`, make them classes that descend from
`namedtuple`, have `__slots__ = ()`. Move them to module `infos`.

-   Status information during parsing is now routed through
`logging.getLogger("grako")`.

-   Methods in `objectmodel.Node` that require an `infos.ParseInfo` will
now raise `exceptions.NoParseInfo` if parse information is not available
for the node.

-   There were broken links in the documentation after the repository was
moved from /apalala/ to /neogeny/ on Bitbucket.


Grako
=

Grako (for grammar compiler) is a tool that takes grammars in a variation
of EBNF as input, and outputs memoizing (Packrat) PEG parsers in Python.

https://pypi.python.org/pypi/grako/3.21.0

-- 
Juancarlo *Añez*
mailto:apal...@gmail.com
tel:+58(414)901-2021 <0414-9012021>
skype:juancarloanez
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TASU 4.0.0 released

2017-05-07 Thread Juancarlo Añez
TATSU (the successor to Grako) is a tool that takes grammars in a variation
of EBNF as input, and outputs memoizing (Packrat) PEG parsers in Python.

Tatsu can compile a grammar stored in a string into a
tatsu.grammars.Grammar object that can be used to parse any given input,
much like the re module does with regular expressions, or it can generate a
Python module that implements the parser.

https://pypi.python.org/pypi/tatsu/

https://github.com/apalala/tatsu

http://tatsu.readthedocs.io/

-- 
Juancarlo
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TatSu 4.1.0

2017-05-22 Thread Juancarlo Añez
TatSu v4.1.0 was released

* https://pypi.org/project/tatsu/

* http://tatsu.readthedocs.io/en/latest/

* https://github.com/neogeny/TatSu

TatSu (the successor to Grako) is a tool that takes grammars in a variation
of EBNF as input, and outputs memoizing (Packrat) PEG parsers in Python.

CHANGES

*  New support for *left recursion* with correct associativity. All test
cases pass.

*  Left recursion is enabled by default. Use the``@@left_recursion ::
False`` directive to diasable it.

*  Renamed the decorator for generated rule methods to ``@tatsumasu``.

*  Refactored the ``tatsu.contexts.ParseContext`` for clarity.

*  The ``@@ignorecase`` directive and the ``ignorecase=`` parameter no
longer appy to regular expressions (patterns) in grammars. Use  ``(?i)`` in
the pattern to ignore the case in a particular pattern.

*  Now ``tatsu.g2e`` is a library and executable module for translating
`ANTLR`_ grammars to **TatSu**.

*  Modernized the ``calc`` example and made it part of the documentation as
*Mini Tutorial*.

*  Simplified the generated object models using the semantics of class
attributes in Python.



-- 
Juancarlo *Añez*
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TatSu 4.2.0

2017-06-05 Thread Juancarlo Añez
Added
~

*   Parse speeds on large files reduced by 5-20% by optimizing parse
contexts and closures, and unifying the AST_ and CST_ stacks.

*   Added the *"skip to"* expression ( ``->``), useful for writing
*recovery* rules.  The parser will advance over input, one character at
time, until the expression matches. Whitespace and comments will be skipped
at each step.

*   Added the *any* expression ( ``/./``) for matching the next character
in the input.

*   The ANTLR_ grammar for Python3_ to the `g2e` example, and udate `g2e`
to handle more ANTLR_ syntax.

*   Check typing with Mypy_.


Changed
~~~

*   Removed the very old _regex_ example.

*   Make parse traces more compact. Add a sample to the docs.

*   Explain Grako_ compatibility in docs.



|TatSu|
===

|TatSu| (the successor to Grako_) is a tool that takes grammars in a
variation of `EBNF`_ as input, and outputs `memoizing`_ (`Packrat`_) `PEG`_
parsers in `Python`_.

|TatSu| can compile a grammar stored in a string into a
``tatsu.grammars.Grammar`` object that can be used to parse any given
input, much like the `re`_ module does with regular expressions, or it can
generate a Python_ module that implements the parser.


--
Juancarlo Añez
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TatSu v4.2.5 released

2017-11-27 Thread Juancarlo Añez
竜 TatSu (the successor to Grako) is a tool that takes grammars in a
variation of EBNF as input, and outputs memoizing (Packrat) PEG parsers in
Python.

竜 TatSu can compile a grammar stored in a string into a
tatsu.grammars.Grammar object that can be used to parse any given input,
much like the re module does with regular expressions, or it can generate a
Python module that implements the parser.

竜 TatSu fully supports left-recursive rules in PEG grammars using the
algorithm by Laurent and Mens. The generated AST has the expected left
associativity.

https://github.com/neogeny/TatSu
http://tatsu.readthedocs.io/en/stable/

v4.2.5


* #42 <https://github.com/neogeny/TatSu/issues/42> Rename vim files from
grako.vim to tatsu.vim (@fcoelho <https://github.com/fcoelho>)
* #51 <https://github.com/neogeny/TatSu/issues/51> Fix inconsistent code
generation for whitespace (@fpom <https://github.com/fpom>)
* #54 <https://github.com/neogeny/TatSu/pull/54> Only care about case of
first letter of rule name for determining advance over whitespace (@acw1251
<https://github.com/acw1251>)

 v4.2.4
-
* #40 Make the start rule default to the first rule defined in the grammar
(@hariedo)
* #43 Import re from tatsu.util to support optional regex-only features
(@azazel75)
* #47 Fix incorrect sample code in documentation

v4.2.3


* #37 Regression: The #include pragma works by using the EBNFBuffer from
grammars.py. Somehow the default EBNFBootstrapBuffer from bootstrap.py has
been used instead (@gegenschall).
* #38 Documentation: Use of json.dumps() requires ast.asjson() (@davidchen).


-- 
Juancarlo *Añez*
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TatSu 4.3.0 released

2018-11-17 Thread Juancarlo Añez
TatSu 4.3.0 has been released with this changelog:


-- 
Juancarlo *Añez*
tel:+58(414)901-2021
skype:juancarloanez
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TatSu 4.3.0 released

2018-11-17 Thread Juancarlo Añez
TatSu 4.3.0 has been released with this changelog:

   - #66 <https://github.com/neogeny/TatSu/issues/66> Fix multiline ( (?x)
   ) patterns not properly supported in grammar (@pdw-mb
   <https://github.com/pdw-mb>)
   - #70 <https://github.com/neogeny/TatSu/issues/70> Important upgrade to
   ModelBuilder and grammar specification of classes for generated nodes. See
   pull request #78 <https://github.com/neogeny/TatSu/pull/78> for details (
   @Victorious3 <https://github.com/Victorious3>)


https://pypi.org/project/tatsu/
https://github.com/neogeny/TatSu
https://tatsu.readthedocs.io/

竜 TatSu (the successor to Grako <https://bitbucket.org/neogeny/grako/>) is
a tool that takes grammars in a variation of EBNF
<http://en.wikipedia.org/wiki/Ebnf> as input, and outputs memoizing
<http://en.wikipedia.org/wiki/Memoization> (Packrat
<http://bford.info/packrat/>) PEG
<http://en.wikipedia.org/wiki/Parsing_expression_grammar> parsers in Python
<http://python.org/>.

竜 TatSu can compile a grammar stored in a string into a
tatsu.grammars.Grammar object that can be used to parse any given input,
much like the re <https://docs.python.org/3.7/library/re.html> module does
with regular expressions, or it can generate a Python
<http://python.org/> module
that implements the parser.
-- 
Juancarlo *Añez*
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TatSu v4.4.0 PEG parser generator released

2019-04-25 Thread Juancarlo Añez
竜 TatSu v4.4.0 has been released. Thanks to Vic Nightfall, support for
left-recursion in PEG grammars is now complete.

def WARNING():
return 'v4.4.0 is the last version of 竜TatSu supporting Python 2.7'

竜 TatSu (the successor to Grako) is a tool that takes grammars in a
variation of EBNF as input, and outputs memoizing (Packrat) PEG parsers
in Python.

竜 TatSu can compile a grammar stored in a string into a
tatsu.grammars.Grammar object that can be used to parse any given input,
much like the re module does with regular expressions, or it can
generate a Python module that implements the parser.

竜 TatSu supports left-recursive rules in PEG grammars using the
algorithm by _Laurent_ and _Mens_. The generated AST has the expected
left associativity.


LINKS
*   https://pypi.org/project/TatSu/4.4.0/
*   https://tatsu.readthedocs.io/
*   https://github.com/neogeny/TatSu


CHANGELOG
*   The default regexp for whitespace was changed to `(?s)s+
*   Allow empty patterns (//) like Python does
*   #65 Allow initial, consecutive, and trailing @namechars
*   #73 Allow @@whitespace :: None and @@whitespace :: False
*   #75 Complete implemenation of left recursion(@Victorious3)
*   #77 Allow @keyword throughout the grammar
*   #89 Make all attributes defined in the rule present in the resulting
AST or Node even if the associated expression was not parsed
*   #93 Fix trace colorization on Windows
*   #96 Documented each @@directive
*   Switched the documentation to the "Alabaster" theme
*   Various code and documentation fixes (@davesque, @nicholasbishop,
@rayjolt)


-- 
Juancarlo *Añez*
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TatSu 5.0.0 released

2020-01-28 Thread Juancarlo Añez
竜 TatSu is a tool that takes grammars in a variation of EBNF
<http://en.wikipedia.org/wiki/Ebnf> as input, and outputs memoizing
<http://en.wikipedia.org/wiki/Memoization> (Packrat
<http://bford.info/packrat/>) PEG
<http://en.wikipedia.org/wiki/Parsing_expression_grammar> parsers in Python
<http://python.org/>.

竜 TatSu can compile a grammar stored in a string into a
tatsu.grammars.Grammar object that can be used to parse any given input,
much like the re <https://docs.python.org/3.7/library/re.html> module does
with regular expressions, or it can generate a Python
<http://python.org/> module
that implements the parser.

竜 TatSu supports left-recursive
<https://en.wikipedia.org/wiki/Left_recursion> rules in PEG
<http://en.wikipedia.org/wiki/Parsing_expression_grammar> grammars using
the algorithm <http://norswap.com/pubs/sle2016.pdf> by *Laurent* and *Mens*.
The generated AST <http://en.wikipedia.org/wiki/Abstract_syntax_tree> has
the expected left associativity.
<https://github.com/neogeny/TatSu#installation>*CHANGES*


   - 竜 TatSu is now only tested against Python 3.8. Earlier versions of
   Python are now deprecated, and Python 2.X versions are no longer supported (
   @apalala <https://github.com/apalala>).
   - Apply nameguard only if token[0].isalpha(). This solves a regression
   afecting previous TatSu and Grako grammars (@apalala
   <https://github.com/apalala>).
   - Remove pygraphviz from develoment requirements, as it doesn't build
   under Py38 (@apalala <https://github.com/apalala>)
   - #56 <https://github.com/neogeny/TatSu/issues/56> Include missing
   tatsu/g2e/antlr.ebnf in distribution (@apalala
   <https://github.com/apalala>)
   - #138 <https://github.com/neogeny/TatSu/issues/138> Reimplement the
   calculation of FIRST, FOLLOW, and LOOKAHEAD sets using latest theories.
   For now, this should improve parser error reporting, but should eventually
   enable the simplification of parsing of leftrec grammars (@apalala
   <https://github.com/apalala>).
   - #153 <https://github.com/neogeny/TatSu/issues/153> Import ABCs from
   collections.abc (@tirkarthi <https://github.com/tirkarthi>)
   - Remove support for Cythonand pypy3 (@apalala
   <https://github.com/apalala>).


-- 
Juancarlo *Añez*
--
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/

Support the Python Software Foundation:
http://www.python.org/psf/donations/


TatSu v4.2.5 released

2017-11-28 Thread nospam . Juancarlo Añez
ç«£ TatSu (the successor to Grako) is a tool that takes grammars in a
variation of EBNF as input, and outputs memoizing (Packrat) PEG parsers in
Python.

ç«£ TatSu can compile a grammar stored in a string into a
tatsu.grammars.Grammar object that can be used to parse any given input, much
like the re module does with regular expressions, or it can generate a Python
module that implements the parser.

ç«£ TatSu fully supports left-recursive rules in PEG grammars using the
algorithm by Laurent and Mens. The generated AST has the expected left
associativity.

https://github.com/neogeny/TatSu
http://tatsu.readthedocs.io/en/stable/

v4.2.5


* #42  Rename vim files from
grako.vim to tatsu.vim (@fcoelho )
* #51  Fix inconsistent code
generation for whitespace (@fpom )
* #54  Only care about case of
first letter of rule name for determining advance over whitespace (@acw1251
)

 v4.2.4
-
* #40 Make the start rule default to the first rule defined in the grammar
(@hariedo)
* #43 Import re from tatsu.util to support optional regex-only features
(@azazel75)
* #47 Fix incorrect sample code in documentation

v4.2.3


* #37 Regression: The #include pragma works by using the EBNFBuffer from
grammars.py. Somehow the default EBNFBootstrapBuffer from bootstrap.py has been
 used instead (@gegenschall).
* #38 Documentation: Use of json.dumps() requires ast.asjson() (@davidchen).


--
Juancarlo *Aıez*

-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/