We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 890f1a5 commit edef9cbCopy full SHA for edef9cb
src/build123d/topology/shape_core.py
@@ -50,6 +50,7 @@
50
import itertools
51
import warnings
52
from abc import ABC, abstractmethod
53
+from functools import lru_cache
54
from typing import (
55
cast as tcast,
56
Any,
@@ -2935,7 +2936,7 @@ def _sew_topods_faces(faces: Iterable[TopoDS_Face]) -> TopoDS_Shape:
2935
2936
shell_builder.Perform()
2937
return downcast(shell_builder.SewedShape())
2938
-
2939
+@lru_cache(maxsize=128) # default is 128
2940
def _topods_entities(shape: TopoDS_Shape, topo_type: Shapes) -> list[TopoDS_Shape]:
2941
"""Return the TopoDS_Shapes of topo_type from this TopoDS_Shape"""
2942
out = {} # using dict to prevent duplicates
0 commit comments