llparse 0.2.0__tar.gz → 0.3.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. {llparse-0.2.0 → llparse-0.3.0}/PKG-INFO +3 -2
  2. {llparse-0.2.0 → llparse-0.3.0}/llparse/C_compiler.py +2 -6
  3. llparse-0.3.0/llparse/__init__.py +12 -0
  4. llparse-0.3.0/llparse/_tempita/__init__.py +1281 -0
  5. llparse-0.3.0/llparse/_tempita/__init__.pyi +147 -0
  6. llparse-0.3.0/llparse/_tempita/__main__.py +3 -0
  7. llparse-0.3.0/llparse/_tempita/_looper.py +169 -0
  8. llparse-0.3.0/llparse/_tempita/_looper.pyi +49 -0
  9. llparse-0.3.0/llparse/_tempita/compat3.py +46 -0
  10. llparse-0.3.0/llparse/capi_builder.py +529 -0
  11. {llparse-0.2.0 → llparse-0.3.0}/llparse/compilator.py +105 -71
  12. {llparse-0.2.0 → llparse-0.3.0}/llparse/dot.py +5 -6
  13. {llparse-0.2.0 → llparse-0.3.0}/llparse/frontend.py +22 -19
  14. {llparse-0.2.0 → llparse-0.3.0}/llparse/header.py +18 -27
  15. {llparse-0.2.0 → llparse-0.3.0}/llparse/llparse.py +29 -24
  16. {llparse-0.2.0 → llparse-0.3.0}/llparse/pybuilder/builder.py +4 -4
  17. {llparse-0.2.0 → llparse-0.3.0}/llparse/pybuilder/loopchecker.py +2 -2
  18. {llparse-0.2.0 → llparse-0.3.0}/llparse/pybuilder/main_code.py +33 -19
  19. {llparse-0.2.0 → llparse-0.3.0}/llparse/pybuilder/parsemap.py +20 -0
  20. llparse-0.3.0/llparse/pyfront/__init__.py +2 -0
  21. {llparse-0.2.0 → llparse-0.3.0}/llparse/pyfront/code.py +6 -6
  22. {llparse-0.2.0 → llparse-0.3.0}/llparse/pyfront/namespace.py +1 -5
  23. {llparse-0.2.0 → llparse-0.3.0}/llparse/pyfront/nodes.py +15 -18
  24. {llparse-0.2.0 → llparse-0.3.0}/llparse/pyfront/peephole.py +6 -5
  25. {llparse-0.2.0 → llparse-0.3.0}/llparse/spanalloc.py +6 -9
  26. {llparse-0.2.0 → llparse-0.3.0}/llparse/trie.py +2 -3
  27. {llparse-0.2.0 → llparse-0.3.0}/llparse.egg-info/PKG-INFO +3 -2
  28. {llparse-0.2.0 → llparse-0.3.0}/llparse.egg-info/SOURCES.txt +8 -2
  29. llparse-0.3.0/llparse.egg-info/requires.txt +3 -0
  30. llparse-0.3.0/pyproject.toml +21 -0
  31. {llparse-0.2.0 → llparse-0.3.0}/tests/test_compilator.py +1 -2
  32. {llparse-0.2.0 → llparse-0.3.0}/tests/test_frontend.py +7 -4
  33. llparse-0.2.0/llparse/__init__.py +0 -4
  34. llparse-0.2.0/llparse/cython_builder.py +0 -312
  35. llparse-0.2.0/llparse/pyfront/__init__.py +0 -3
  36. llparse-0.2.0/llparse/settings.py +0 -284
  37. llparse-0.2.0/pyproject.toml +0 -11
  38. {llparse-0.2.0 → llparse-0.3.0}/LICENSE +0 -0
  39. {llparse-0.2.0 → llparse-0.3.0}/README.md +0 -0
  40. {llparse-0.2.0 → llparse-0.3.0}/llparse/constants.py +0 -0
  41. {llparse-0.2.0 → llparse-0.3.0}/llparse/debug.py +0 -0
  42. {llparse-0.2.0 → llparse-0.3.0}/llparse/enumerator.py +0 -0
  43. {llparse-0.2.0 → llparse-0.3.0}/llparse/errors.py +0 -0
  44. {llparse-0.2.0 → llparse-0.3.0}/llparse/pybuilder/__init__.py +0 -0
  45. {llparse-0.2.0 → llparse-0.3.0}/llparse/pyfront/implementation.py +0 -0
  46. {llparse-0.2.0 → llparse-0.3.0}/llparse/pyfront/transform.py +0 -0
  47. {llparse-0.2.0 → llparse-0.3.0}/llparse.egg-info/dependency_links.txt +0 -0
  48. {llparse-0.2.0 → llparse-0.3.0}/llparse.egg-info/top_level.txt +0 -0
  49. {llparse-0.2.0 → llparse-0.3.0}/setup.cfg +0 -0
  50. {llparse-0.2.0 → llparse-0.3.0}/tests/test_loop_checker.py +0 -0
  51. {llparse-0.2.0 → llparse-0.3.0}/tests/test_span_allocator.py +0 -0
@@ -1,11 +1,12 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: llparse
3
- Version: 0.2.0
3
+ Version: 0.3.0
4
4
  Summary: A Parody of llparse written for writing C Parsers with Python
5
5
  Author-email: Vizonex <VizonexBusiness@gmail.com>
6
- Requires-Python: >=3.9
6
+ Requires-Python: >=3.10
7
7
  Description-Content-Type: text/markdown
8
8
  License-File: LICENSE
9
+ Requires-Dist: typing_extensions; python_version < "3.13"
9
10
  Dynamic: license-file
10
11
 
11
12
  # pyllparse
@@ -1,16 +1,12 @@
1
- from typing import Optional
2
-
3
1
  from .compilator import Compilation, ICompilerOptions, Node
4
- from .constants import *
2
+ from .constants import ARG_STATE, ARG_POS, ARG_ENDPOS, VAR_MATCH, STATE_ERROR
5
3
  from .frontend import IFrontendResult
6
4
 
7
5
 
8
6
  class CCompiler:
9
7
  """The Final HeadPeice where the Main C-Code gets compiled to..."""
10
8
 
11
- def __init__(
12
- self, header: Optional[str] = None, debug: Optional[str] = None
13
- ) -> None:
9
+ def __init__(self, header: str | None = None, debug: str | None = None) -> None:
14
10
  # NOTE Unlike in typescript llparse Containers are not Required since I'm using a different methoad to translate those parts...
15
11
  self.options = ICompilerOptions(debug, header)
16
12
 
@@ -0,0 +1,12 @@
1
+ """
2
+ LLParse
3
+ -------
4
+
5
+ A Pythonic version of the typescript llparse library.
6
+ """
7
+
8
+ from .dot import Dot
9
+ from .llparse import LLParse
10
+
11
+ __version__ = "0.3.0"
12
+ __all__ = ("Dot", "LLParse")