Skip to content

Commit 4cbf316

Browse files
committed
Remove CompiledFunction.id
It's unused and we can get rid of the global fn_counter.
1 parent 2af3efd commit 4cbf316

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

compiler.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,19 +37,14 @@
3737
Env = Dict[str, str]
3838

3939

40-
fn_counter = itertools.count()
41-
42-
4340
@dataclasses.dataclass
4441
class CompiledFunction:
45-
id: int = dataclasses.field(default=0, init=False, compare=False, hash=False)
4642
name: str
4743
params: typing.List[str]
4844
fields: typing.List[str] = dataclasses.field(default_factory=list)
4945
code: typing.List[str] = dataclasses.field(default_factory=list)
5046

5147
def __post_init__(self) -> None:
52-
self.id = next(fn_counter)
5348
self.code.append("HANDLES();")
5449
for param in self.params:
5550
# The parameters are raw pointers and must be updated on GC

0 commit comments

Comments
 (0)