| 1462 | } |
| 1463 | |
| 1464 | void applyMultiQubitPhaseFlip(Qureg qureg, int* targets, int numTargets) { |
| 1465 | validate_quregFields(qureg, __func__); |
| 1466 | validate_targets(qureg, targets, numTargets, __func__); |
| 1467 | |
| 1468 | // treat as a (numTargets-1)-controlled 1-target Pauli Z |
| 1469 | DiagMatr1 matr = getDiagMatr1({1, -1}); |
| 1470 | |
| 1471 | // harmlessly re-validates |
| 1472 | applyMultiStateControlledDiagMatr1(qureg, &targets[1], nullptr, numTargets-1, targets[0], matr); |
| 1473 | } |
| 1474 | |
| 1475 | } // end de-mangler |
| 1476 |
no test coverage detected