Skip to content

Commit

Permalink
Remove unused "include" directives and "using" statements (#1569)
Browse files Browse the repository at this point in the history
  • Loading branch information
cqc-alec authored Sep 9, 2024
1 parent 3107488 commit 0e9122f
Show file tree
Hide file tree
Showing 132 changed files with 19 additions and 224 deletions.
2 changes: 1 addition & 1 deletion pytket/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def package(self):
cmake.install()

def requirements(self):
self.requires("tket/1.3.23@tket/stable")
self.requires("tket/1.3.24@tket/stable")
self.requires("tklog/0.3.3@tket/stable")
self.requires("tkrng/0.3.3@tket/stable")
self.requires("tkassert/0.3.4@tket/stable")
Expand Down
2 changes: 1 addition & 1 deletion tket/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

class TketConan(ConanFile):
name = "tket"
version = "1.3.23"
version = "1.3.24"
package_type = "library"
license = "Apache 2"
homepage = "https://github.com/CQCL/tket"
Expand Down
2 changes: 2 additions & 0 deletions tket/proptest/src/ComparisonFunctions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
#include <sstream>
#include <stdexcept>

#include "tket/Utils/MatrixAnalysis.hpp"

// NOTE: this is an identical copy of a file in tket-tests, in the Simulation
// folder. This is deliberate! Please keep both in sync!
// See the tket-tests file for a mathematical discussion.
Expand Down
2 changes: 1 addition & 1 deletion tket/proptest/src/ComparisonFunctions.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

#pragma once

#include "tket/Utils/MatrixAnalysis.hpp"
#include "tket/Utils/EigenConfig.hpp"

namespace tket {
namespace tket_sim {
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Architecture/Architecture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,9 @@

#include <boost/graph/biconnected_components.hpp>
#include <tkassert/Assert.hpp>
#include <unordered_set>
#include <vector>

#include "tket/Graphs/ArticulationPoints.hpp"
#include "tket/Utils/Json.hpp"
#include "tket/Utils/UnitID.hpp"

namespace tket {
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Architecture/ArchitectureMapping.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@

#include "tket/Architecture/ArchitectureMapping.hpp"

#include <sstream>
#include <stdexcept>
#include <tkassert/Assert.hpp>

namespace tket {
Expand Down
3 changes: 0 additions & 3 deletions tket/src/Architecture/DistancesFromArchitecture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@

#include "tket/Architecture/DistancesFromArchitecture.hpp"

#include <sstream>
#include <stdexcept>

namespace tket {

DistancesFromArchitecture::DistancesFromArchitecture(
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Architecture/NeighboursFromArchitecture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@
#include "tket/Architecture/NeighboursFromArchitecture.hpp"

#include <algorithm>
#include <sstream>
#include <stdexcept>

namespace tket {

Expand Down
5 changes: 0 additions & 5 deletions tket/src/Circuit/AssertionSynthesis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,12 @@

#include <array>
#include <cmath>
#include <complex>
#include <optional>
#include <stdexcept>
#include <tkassert/Assert.hpp>

#include "tket/Circuit/CircUtils.hpp"
#include "tket/Circuit/Circuit.hpp"
#include "tket/OpType/OpType.hpp"
#include "tket/Utils/Constants.hpp"
#include "tket/Utils/CosSinDecomposition.hpp"
#include "tket/Utils/EigenConfig.hpp"
#include "tket/Utils/MatrixAnalysis.hpp"
#include "tket/Utils/UnitID.hpp"

Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/Boxes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,8 @@
#include "tket/OpType/OpTypeInfo.hpp"
#include "tket/Ops/OpJsonFactory.hpp"
#include "tket/Ops/OpPtr.hpp"
#include "tket/Utils/EigenConfig.hpp"
#include "tket/Utils/Expression.hpp"
#include "tket/Utils/HelperFunctions.hpp"
#include "tket/Utils/Json.hpp"
#include "tket/Utils/PauliTensor.hpp"

namespace tket {
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/CircPool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,9 @@

#include "tket/Circuit/CircUtils.hpp"
#include "tket/Circuit/Circuit.hpp"
#include "tket/Gate/Rotation.hpp"
#include "tket/OpType/OpType.hpp"
#include "tket/Transformations/BasicOptimisation.hpp"
#include "tket/Utils/Expression.hpp"
#include "tket/Utils/MatrixAnalysis.hpp"

namespace tket {

Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/CircUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@
#include "tket/Gate/GateUnitaryMatrixImplementations.hpp"
#include "tket/Gate/Rotation.hpp"
#include "tket/OpType/OpType.hpp"
#include "tket/Ops/Op.hpp"
#include "tket/Utils/EigenConfig.hpp"
#include "tket/Utils/Expression.hpp"
#include "tket/Utils/MatrixAnalysis.hpp"
#include "tket/Utils/UnitID.hpp"
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/Circuit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <algorithm>
#include <cstddef>
#include <fstream>
#include <numeric>
#include <optional>
#include <set>
#include <string>
Expand All @@ -32,7 +31,6 @@
#include "tket/OpType/OpType.hpp"
#include "tket/OpType/OpTypeFunctions.hpp"
#include "tket/Utils/Expression.hpp"
#include "tket/Utils/GraphHeaders.hpp"
#include "tket/Utils/HelperFunctions.hpp"

namespace tket {
Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/CircuitJson.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.

#include "tket/Circuit/Circuit.hpp"
#include "tket/Utils/Json.hpp"

namespace tket {

Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/ConjugationBox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
#include "Utils/Expression.hpp"
#include "tket/Circuit/Circuit.hpp"
#include "tket/Ops/OpJsonFactory.hpp"
#include "tket/Utils/HelperFunctions.hpp"
#include "tket/Utils/Json.hpp"

namespace tket {

Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/ControlledGates.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
#include "tket/Gate/GatePtr.hpp"
#include "tket/Gate/Rotation.hpp"
#include "tket/OpType/OpType.hpp"
#include "tket/Utils/EigenConfig.hpp"
#include "tket/Utils/HelperFunctions.hpp"

namespace tket {
Expand Down
3 changes: 1 addition & 2 deletions tket/src/Circuit/DAGProperties.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,10 @@
#include "DAGProperties.hpp"

#include <algorithm>
#include <tkassert/Assert.hpp>
#include <tklog/TketLog.hpp>

#include "tket/Circuit/Circuit.hpp"
#include "tket/OpType/EdgeType.hpp"
#include "tket/Utils/GraphHeaders.hpp"

namespace tket {

Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/DiagonalBox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,8 @@

#include "tket/Circuit/Circuit.hpp"
#include "tket/Circuit/Multiplexor.hpp"
#include "tket/Gate/Rotation.hpp"
#include "tket/Ops/OpJsonFactory.hpp"
#include "tket/Utils/HelperFunctions.hpp"
#include "tket/Utils/Json.hpp"

namespace tket {

Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/Multiplexor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
#include "tket/Ops/OpJsonFactory.hpp"
#include "tket/Utils/Constants.hpp"
#include "tket/Utils/HelperFunctions.hpp"
#include "tket/Utils/Json.hpp"

namespace tket {

Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/OpJson.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include "tket/OpType/OpTypeFunctions.hpp"
#include "tket/Ops/BarrierOp.hpp"
#include "tket/Ops/ClassicalOps.hpp"
#include "tket/Ops/MetaOp.hpp"
#include "tket/Ops/OpPtr.hpp"
#include "tket/Utils/Json.hpp"

Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/PauliExpBoxes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@

#include "tket/Circuit/PauliExpBoxes.hpp"

#include <iostream>

#include "tket/Circuit/CircUtils.hpp"
#include "tket/Circuit/ConjugationBox.hpp"
#include "tket/Converters/PhasePoly.hpp"
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/ResourceData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@

#include "tket/Circuit/ResourceData.hpp"

#include "tket/Utils/Json.hpp"

namespace tket {

bool ResourceData::operator==(const ResourceData& other) const {
Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/Simulation/BitOperations.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

#include "BitOperations.hpp"

#include <stdexcept>
#include <tkassert/Assert.hpp>

namespace tket {
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/Simulation/DecomposeCircuit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
#include "GateNodesBuffer.hpp"
#include "tket/Circuit/Boxes.hpp"
#include "tket/Circuit/Circuit.hpp"
#include "tket/Circuit/PauliExpBoxes.hpp"
#include "tket/Circuit/Simulation/PauliExpBoxUnitaryCalculator.hpp"
#include "tket/Gate/Gate.hpp"
#include "tket/Gate/GateUnitaryMatrix.hpp"
#include "tket/Gate/GateUnitaryMatrixError.hpp"
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/Simulation/DecomposeCircuit.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@

#pragma once

#include "tket/Utils/MatrixAnalysis.hpp"

namespace tket {
class Circuit;
namespace tket_sim {
Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/Simulation/GateNodesBuffer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <memory>

#include "GateNode.hpp"
#include "tket/Utils/MatrixAnalysis.hpp"

namespace tket {
namespace tket_sim {
Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/StatePreparation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
#include "tket/Gate/Rotation.hpp"
#include "tket/Ops/OpJsonFactory.hpp"
#include "tket/Utils/HelperFunctions.hpp"
#include "tket/Utils/Json.hpp"

namespace tket {

Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/SubcircuitFinder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
#include <boost/graph/transitive_closure.hpp>
#include <cstddef>
#include <iterator>
#include <memory>
#include <optional>
#include <tkassert/Assert.hpp>
#include <vector>
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/ThreeQubitConversion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@
#include "tket/OpType/OpType.hpp"
#include "tket/Utils/Constants.hpp"
#include "tket/Utils/CosSinDecomposition.hpp"
#include "tket/Utils/EigenConfig.hpp"
#include "tket/Utils/MatrixAnalysis.hpp"
#include "tket/Utils/UnitID.hpp"

namespace tket {
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Circuit/ToffoliBox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,8 @@
#include "tket/Circuit/Circuit.hpp"
#include "tket/Circuit/DiagonalBox.hpp"
#include "tket/Circuit/Multiplexor.hpp"
#include "tket/Gate/Rotation.hpp"
#include "tket/Ops/OpJsonFactory.hpp"
#include "tket/Utils/HelperFunctions.hpp"
#include "tket/Utils/Json.hpp"

namespace tket {

Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/macro_circ_info.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
#include "tket/OpType/EdgeType.hpp"
#include "tket/OpType/OpType.hpp"
#include "tket/Ops/OpPtr.hpp"
#include "tket/Utils/GraphHeaders.hpp"

namespace tket {

Expand Down
1 change: 0 additions & 1 deletion tket/src/Circuit/setters_and_getters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
#include "tket/OpType/OpDesc.hpp"
#include "tket/OpType/OpType.hpp"
#include "tket/Ops/OpPtr.hpp"
#include "tket/Utils/GraphHeaders.hpp"

namespace tket {

Expand Down
2 changes: 0 additions & 2 deletions tket/src/Converters/PauliGraphConverters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@
#include "tket/Circuit/Boxes.hpp"
#include "tket/Circuit/PauliExpBoxes.hpp"
#include "tket/Converters/Converters.hpp"
#include "tket/Converters/PhasePoly.hpp"
#include "tket/Diagonalisation/Diagonalisation.hpp"
#include "tket/Gate/Gate.hpp"

namespace tket {
Expand Down
2 changes: 0 additions & 2 deletions tket/src/Converters/PhasePoly.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@
#include "tket/OpType/OpType.hpp"
#include "tket/Ops/OpJsonFactory.hpp"
#include "tket/Ops/OpPtr.hpp"
#include "tket/Utils/GraphHeaders.hpp"
#include "tket/Utils/Json.hpp"

namespace tket {

Expand Down
1 change: 0 additions & 1 deletion tket/src/Converters/ZXConverters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#include "tket/Circuit/CircPool.hpp"
#include "tket/Converters/Converters.hpp"
#include "tket/ZX/Flow.hpp"
#include "tket/ZX/ZXDiagram.hpp"
Expand Down
1 change: 0 additions & 1 deletion tket/src/Diagonalisation/Diagonalisation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@

#include <tkassert/Assert.hpp>

#include "tket/Ops/Op.hpp"
#include "tket/PauliGraph/ConjugatePauliFunctions.hpp"
#include "tket/Utils/UnitID.hpp"

Expand Down
1 change: 0 additions & 1 deletion tket/src/Diagonalisation/PauliPartition.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@

#include "tket/Graphs/AdjacencyData.hpp"
#include "tket/Graphs/GraphColouring.hpp"
#include "tket/Utils/GraphHeaders.hpp"

namespace tket {

Expand Down
2 changes: 1 addition & 1 deletion tket/src/Gate/GateUnitaryMatrixVariableQubits.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#pragma once

#include "tket/OpType/OpType.hpp"
#include "tket/Utils/MatrixAnalysis.hpp"
#include "tket/Utils/EigenConfig.hpp"

namespace tket {
namespace internal {
Expand Down
1 change: 0 additions & 1 deletion tket/src/Gate/Rotation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
#include "tket/OpType/OpDesc.hpp"
#include "tket/OpType/OpType.hpp"
#include "tket/Utils/Expression.hpp"
#include "tket/Utils/Symbols.hpp"

namespace tket {

Expand Down
3 changes: 0 additions & 3 deletions tket/src/Graphs/AdjacencyData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,9 @@
#include <algorithm>
#include <set>
#include <sstream>
#include <stdexcept>
#include <tkassert/Assert.hpp>

using std::exception;
using std::map;
using std::runtime_error;
using std::set;
using std::string;
using std::stringstream;
Expand Down
1 change: 0 additions & 1 deletion tket/src/Graphs/ArticulationPoints.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
#include <vector>

#include "tket/Graphs/Utils.hpp"
#include "tket/Utils/GraphHeaders.hpp"

namespace tket::graphs {

Expand Down
1 change: 0 additions & 1 deletion tket/src/Graphs/BruteForceColouring.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
#include "BruteForceColouring.hpp"

#include <set>
#include <sstream>
#include <stdexcept>
#include <tkassert/Assert.hpp>

Expand Down
Loading

0 comments on commit 0e9122f

Please sign in to comment.