DrawCircuitError
public enum DrawCircuitError : Error, Hashable
Errors throwed by Drawable.drawCircuit(_:qubitCount:)
-
Throwed when
qubitCountis 0, i.e. a circuit requires at least 1 qubitDeclaration
Swift
case qubitCountHasToBeBiggerThanZero -
Throwed when
gateinforms no inputs/controlsDeclaration
Swift
case gateWithEmptyInputList(gate: Gate) -
Throwed when
gateinforms the same input qubit twice (or more)Declaration
Swift
case gateWithRepeatedInputs(gate: Gate) -
Throwed when
gateinforms the same control qubit twice (or more) in the same controlled/oracle gate or in different controlled/oracle gatesDeclaration
Swift
case gateWithRepeatedControls(gate: Gate) -
Throwed when
gatetries to use one or more input qubits also as control qubitsDeclaration
Swift
case gateWithOneOrMoreInputsAlsoControls(gate: Gate) -
Throwed when one or more of the inputs/targets/controls in
gatereference a qubit that does not existDeclaration
Swift
case gateWithOneOrMoreInputsOrControlsOutOfRange(gate: Gate)
DrawCircuitError Enumeration Reference