Compare commits
2 Commits
7ffc620f06
...
f4ca9658fb
| Author | SHA1 | Date | |
|---|---|---|---|
| f4ca9658fb | |||
| ae8c8b01ba |
@@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "breakshaft"
|
name = "breakshaft"
|
||||||
version = "0.1.0"
|
version = "0.1.0.post1"
|
||||||
description = "Library for in-time codegen for type conversion"
|
description = "Library for in-time codegen for type conversion"
|
||||||
authors = [
|
authors = [
|
||||||
{ name = "nikto_b", email = "niktob560@yandex.ru" }
|
{ name = "nikto_b", email = "niktob560@yandex.ru" }
|
||||||
@@ -17,7 +17,7 @@ requires = ["hatchling"]
|
|||||||
build-backend = "hatchling.build"
|
build-backend = "hatchling.build"
|
||||||
|
|
||||||
[tool.hatch.build.targets.wheel]
|
[tool.hatch.build.targets.wheel]
|
||||||
packages = ["src/megasniff"]
|
packages = ["src/breakshaft"]
|
||||||
|
|
||||||
|
|
||||||
[dependency-groups]
|
[dependency-groups]
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ from types import NoneType
|
|||||||
from typing import Callable, Optional
|
from typing import Callable, Optional
|
||||||
|
|
||||||
from .models import ConversionPoint, Callgraph, CallgraphVariant, TransformationPoint, CompositionDirection
|
from .models import ConversionPoint, Callgraph, CallgraphVariant, TransformationPoint, CompositionDirection
|
||||||
from .util import extract_func_argtypes, all_combinations
|
from .util import extract_func_argtypes, all_combinations, extract_func_argtypes_seq
|
||||||
|
|
||||||
|
|
||||||
class GraphWalker:
|
class GraphWalker:
|
||||||
@@ -23,8 +23,9 @@ class GraphWalker:
|
|||||||
if cg is None:
|
if cg is None:
|
||||||
return None
|
return None
|
||||||
branches |= {cg}
|
branches |= {cg}
|
||||||
variant = CallgraphVariant(ConversionPoint(consumer_fn, NoneType, tuple(extract_func_argtypes(consumer_fn))),
|
variant = CallgraphVariant(
|
||||||
branches, frozenset())
|
ConversionPoint(consumer_fn, NoneType, tuple(extract_func_argtypes_seq(consumer_fn))),
|
||||||
|
branches, frozenset())
|
||||||
return Callgraph(frozenset({variant}))
|
return Callgraph(frozenset({variant}))
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
|
|||||||
Reference in New Issue
Block a user