Skip to content

Commit 680c1ac

Browse files
authored
[mypyc] Fix capsule deps of librt.internal.(Write|Read)Buffer (#21329)
These shouldn't depend on `librt.strings`. Restore to the original primitive definitions added in #20194, which didn't have any deps.
1 parent b9147fe commit 680c1ac

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

mypyc/ir/rtypes.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -537,12 +537,12 @@ def __hash__(self) -> int:
537537
range_rprimitive: Final = RPrimitive("builtins.range", is_unboxed=False, is_refcounted=True)
538538

539539
KNOWN_NATIVE_TYPES: Final = {
540-
name: RPrimitive(name, is_unboxed=False, is_refcounted=True, dependencies=(LIBRT_STRINGS,))
541-
for name in [
542-
"librt.internal.WriteBuffer",
543-
"librt.internal.ReadBuffer",
544-
"librt.strings.BytesWriter",
545-
"librt.strings.StringWriter",
540+
name: RPrimitive(name, is_unboxed=False, is_refcounted=True, dependencies=deps)
541+
for name, deps in [
542+
("librt.internal.WriteBuffer", ()),
543+
("librt.internal.ReadBuffer", ()),
544+
("librt.strings.BytesWriter", (LIBRT_STRINGS,)),
545+
("librt.strings.StringWriter", (LIBRT_STRINGS,)),
546546
]
547547
}
548548

0 commit comments

Comments
 (0)