File tree Expand file tree Collapse file tree 3 files changed +16
-6
lines changed Expand file tree Collapse file tree 3 files changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -64,8 +64,8 @@ IntoGDAny
6464
6565
6666class {{ spec.name }}(Enum):
67- {% for a in spec .values .keys () %}
68- {{ a }}: int
67+ {% for key in spec .values .keys () %}
68+ {{ key }}: int
6969{% endfor %}
7070{% endfor %}
7171
@@ -89,6 +89,14 @@ def {{ spec.name }}(
8989# Builtins #
9090##############################################################################
9191{% for spec in api ["builtins" ] if not spec .is_scalar %}
92+ {% for e in spec .enums %}
93+
94+
95+ class {{ e.name }}(Enum):
96+ {% for key in e .values .keys () %}
97+ {{ key }}: int
98+ {% endfor %}
99+ {% endfor %}
92100
93101
94102class {{spec.name}}:
@@ -98,6 +106,8 @@ class {{spec.name}}:
98106{% endfor %}
99107{% if spec .members %}
100108
109+ def clone(self) -> {{ spec.name }}: ...
110+
101111 # Members
102112{% endif %}
103113{% for m in spec .members %}
Original file line number Diff line number Diff line change 1- {% - from 'builtins_pyx/constructor.pyx.j2' import render_constructors with context - %}
2- {% - from 'builtins_pyx/member.pyx.j2' import render_member with context - %}
1+ {% from 'builtins_pyx/constructor.pyx.j2' import render_constructors with context %}
2+ {% from 'builtins_pyx/member.pyx.j2' import render_member with context %}
33
44
55{% macro render_constant (spec , c ) %}
Original file line number Diff line number Diff line change 1- {% - from 'gdapi_pxd/macros.pxd.j2' import
1+ {% from 'gdapi_pxd/macros.pxd.j2' import
22 render_utility_function_signature ,
33 render_utility_function ,
44 render_builtin_type_cy_struct ,
88 render_builtin_method_signature ,
99 render_builtin_all_functions ,
1010 render_builtin_functions_ptrs
11- - %}
11+ %}
1212cimport cython
1313from libc.stdint cimport *
1414
You canβt perform that action at this time.
0 commit comments