You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
with the instruction being appended to a quantum circuit being of type Operation | CircuitInstruction.
In practice, however, we can add also anything that has a to_instruction method (see also this comment). It would be nice to reflect this functionality in the type hints and/or in the following docstring.
The text was updated successfully, but these errors were encountered:
Hello @alexanderivrii , I am thinking of modifying things the following way:
type hints from instruction: Operation | CircuitInstruction to instruction: InstructionLike
and docstring to include additionally in the , :class: ~.circuit would be converted into .circuit.Instruction. and include in the Args::class with .to_instruction() attribute.
What do you suggest about this? If you have a better way of putting things, kindly let me know.
The
QuantumCircuit.append
method looks as followswith the instruction being appended to a quantum circuit being of type
Operation | CircuitInstruction
.In practice, however, we can add also anything that has a
to_instruction
method (see also this comment). It would be nice to reflect this functionality in the type hints and/or in the following docstring.The text was updated successfully, but these errors were encountered: