openscad-parser 2.4.1__tar.gz → 2.4.3__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: openscad_parser
3
- Version: 2.4.1
3
+ Version: 2.4.3
4
4
  Summary: A PEG parser to read OpenSCAD language source code, with optional AST tree generation.
5
5
  Keywords: openscad,openscad parser,parser
6
6
  Author: Revar Desmera
@@ -4,7 +4,7 @@ build-backend = "uv_build"
4
4
 
5
5
  [project]
6
6
  name = "openscad_parser"
7
- version = "2.4.1"
7
+ version = "2.4.3"
8
8
  description = "A PEG parser to read OpenSCAD language source code, with optional AST tree generation."
9
9
  readme = "README.rst"
10
10
  authors = [
@@ -170,7 +170,10 @@ class NumberLiteral(Primary):
170
170
  val: float
171
171
 
172
172
  def __str__(self):
173
- return str(self.val)
173
+ s = str(self.val)
174
+ if 'e' not in s and s.endswith('.0'):
175
+ return s[:-2]
176
+ return s
174
177
 
175
178
 
176
179
  @dataclass