Skip to content

Commit 6c1c09e

Browse files
committed
Type lp.map_instructions.
1 parent 19ac7b2 commit 6c1c09e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

loopy/transform/instruction.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939

4040

4141
if TYPE_CHECKING:
42-
from collections.abc import Mapping, Sequence
42+
from collections.abc import Callable, Mapping, Sequence
4343

4444
from pymbolic import ArithmeticExpression
4545
from pymbolic.primitives import Subscript
@@ -84,7 +84,8 @@ def find_instructions(
8484

8585
# {{{ map_instructions
8686

87-
def map_instructions(kernel, insn_match, f):
87+
def map_instructions(kernel: LoopKernel, insn_match: ToMatchConvertible,
88+
f: Callable[[InstructionBase], InstructionBase]) -> LoopKernel:
8889
from loopy.match import parse_match
8990
match = parse_match(insn_match)
9091

0 commit comments

Comments
 (0)