Skip to content

Commit

Permalink
Fix mypy errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ausbin committed Jun 4, 2024
1 parent 462b7e1 commit 4810634
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions pyqir/pyqir/_native.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ class Builder:
"""
...

def phi(self, value: Type) -> Instruction:
def phi(self, value: Type) -> Phi:
"""
Inserts a phi node.
Expand Down Expand Up @@ -768,7 +768,7 @@ class Opcode(Enum):
class Phi(Instruction):
"""A phi node instruction."""

def add_incoming(self, value: Value, block: BasicBlock):
def add_incoming(self, value: Value, block: BasicBlock) -> None:
"""Adds an incoming value to the end of the phi list."""
...

Expand Down
2 changes: 1 addition & 1 deletion pyqir/tests/test_phi.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def test_ghz_loop() -> None:
for i in range(num_qubits):
pyqir.rt.result_record_output(builder, pyqir.result(context, i), nullptr)

builder.ret()
builder.ret(None)
mod.verify()

ir = str(mod)
Expand Down

0 comments on commit 4810634

Please sign in to comment.