├── .gitignore ├── CMakeLists.txt ├── LICENSE ├── README.md ├── docs └── images │ ├── dumpling.png │ ├── scroll.png │ └── strip.png ├── examples ├── CMakeLists.txt ├── main.cpp ├── paths.h ├── scene_helper.h └── utils.h ├── models ├── armadillo_lvl0_verts30966.obj ├── armadillo_lvl1_verts15484.obj ├── armadillo_lvl2_verts7743.obj ├── armadillo_lvl3_verts3872.obj ├── armadillo_lvl4_verts1937.obj ├── armadillo_lvl5_verts969.obj ├── bunny_lvl0_verts26457.obj ├── bunny_lvl1_verts13229.obj ├── bunny_lvl2_verts6615.obj ├── bunny_lvl3_verts3308.obj ├── bunny_lvl3_verts3308_orig.obj ├── bunny_lvl4_verts1655.obj ├── bunny_lvl5_verts828.obj ├── cylinder_1.obj ├── cylinder_2.obj ├── cylinder_3.obj ├── cylinder_4.obj ├── halfsphere_cutout_16x8.obj ├── halfsphere_cutout_32x16.obj ├── halfsphere_cutout_64x32.obj ├── icosphere_1.obj ├── icosphere_2.obj ├── icosphere_3.obj ├── icosphere_4.obj ├── icosphere_cap_2.obj ├── icosphere_cap_3.obj ├── icosphere_cap_4.obj ├── icosphere_half_2.obj ├── icosphere_half_3.obj ├── rounded_box.obj ├── uvsphere_8x4.obj └── uvsphere_half_8x4.obj ├── paraview └── micropolar.py ├── stark ├── CMakeLists.txt ├── extern │ ├── Eigen │ │ ├── CMakeLists.txt │ │ ├── Eigen │ │ │ ├── AccelerateSupport │ │ │ ├── Cholesky │ │ │ ├── CholmodSupport │ │ │ ├── Core │ │ │ ├── Dense │ │ │ ├── Eigen │ │ │ ├── Eigenvalues │ │ │ ├── Geometry │ │ │ ├── Householder │ │ │ ├── IterativeLinearSolvers │ │ │ ├── Jacobi │ │ │ ├── KLUSupport │ │ │ ├── LU │ │ │ ├── MetisSupport │ │ │ ├── OrderingMethods │ │ │ ├── PaStiXSupport │ │ │ ├── PardisoSupport │ │ │ ├── QR │ │ │ ├── QtAlignedMalloc │ │ │ ├── SPQRSupport │ │ │ ├── SVD │ │ │ ├── Sparse │ │ │ ├── SparseCholesky │ │ │ ├── SparseCore │ │ │ ├── SparseLU │ │ │ ├── SparseQR │ │ │ ├── StdDeque │ │ │ ├── StdList │ │ │ ├── StdVector │ │ │ ├── SuperLUSupport │ │ │ ├── ThreadPool │ │ │ ├── UmfPackSupport │ │ │ └── src │ │ │ │ ├── AccelerateSupport │ │ │ │ ├── AccelerateSupport.h │ │ │ │ └── InternalHeaderCheck.h │ │ │ │ ├── Cholesky │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── LDLT.h │ │ │ │ ├── LLT.h │ │ │ │ └── LLT_LAPACKE.h │ │ │ │ ├── CholmodSupport │ │ │ │ ├── CholmodSupport.h │ │ │ │ └── InternalHeaderCheck.h │ │ │ │ ├── Core │ │ │ │ ├── ArithmeticSequence.h │ │ │ │ ├── Array.h │ │ │ │ ├── ArrayBase.h │ │ │ │ ├── ArrayWrapper.h │ │ │ │ ├── Assign.h │ │ │ │ ├── AssignEvaluator.h │ │ │ │ ├── Assign_MKL.h │ │ │ │ ├── BandMatrix.h │ │ │ │ ├── Block.h │ │ │ │ ├── CommaInitializer.h │ │ │ │ ├── ConditionEstimator.h │ │ │ │ ├── CoreEvaluators.h │ │ │ │ ├── CoreIterators.h │ │ │ │ ├── CwiseBinaryOp.h │ │ │ │ ├── CwiseNullaryOp.h │ │ │ │ ├── CwiseTernaryOp.h │ │ │ │ ├── CwiseUnaryOp.h │ │ │ │ ├── CwiseUnaryView.h │ │ │ │ ├── DenseBase.h │ │ │ │ ├── DenseCoeffsBase.h │ │ │ │ ├── DenseStorage.h │ │ │ │ ├── DeviceWrapper.h │ │ │ │ ├── Diagonal.h │ │ │ │ ├── DiagonalMatrix.h │ │ │ │ ├── DiagonalProduct.h │ │ │ │ ├── Dot.h │ │ │ │ ├── EigenBase.h │ │ │ │ ├── ForceAlignedAccess.h │ │ │ │ ├── Fuzzy.h │ │ │ │ ├── GeneralProduct.h │ │ │ │ ├── GenericPacketMath.h │ │ │ │ ├── GlobalFunctions.h │ │ │ │ ├── IO.h │ │ │ │ ├── IndexedView.h │ │ │ │ ├── InnerProduct.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── Inverse.h │ │ │ │ ├── Map.h │ │ │ │ ├── MapBase.h │ │ │ │ ├── MathFunctions.h │ │ │ │ ├── MathFunctionsImpl.h │ │ │ │ ├── Matrix.h │ │ │ │ ├── MatrixBase.h │ │ │ │ ├── NestByValue.h │ │ │ │ ├── NoAlias.h │ │ │ │ ├── NumTraits.h │ │ │ │ ├── PartialReduxEvaluator.h │ │ │ │ ├── PermutationMatrix.h │ │ │ │ ├── PlainObjectBase.h │ │ │ │ ├── Product.h │ │ │ │ ├── ProductEvaluators.h │ │ │ │ ├── Random.h │ │ │ │ ├── RandomImpl.h │ │ │ │ ├── Redux.h │ │ │ │ ├── Ref.h │ │ │ │ ├── Replicate.h │ │ │ │ ├── Reshaped.h │ │ │ │ ├── ReturnByValue.h │ │ │ │ ├── Reverse.h │ │ │ │ ├── Select.h │ │ │ │ ├── SelfAdjointView.h │ │ │ │ ├── SelfCwiseBinaryOp.h │ │ │ │ ├── SkewSymmetricMatrix3.h │ │ │ │ ├── Solve.h │ │ │ │ ├── SolveTriangular.h │ │ │ │ ├── SolverBase.h │ │ │ │ ├── StableNorm.h │ │ │ │ ├── StlIterators.h │ │ │ │ ├── Stride.h │ │ │ │ ├── Swap.h │ │ │ │ ├── Transpose.h │ │ │ │ ├── Transpositions.h │ │ │ │ ├── TriangularMatrix.h │ │ │ │ ├── VectorBlock.h │ │ │ │ ├── VectorwiseOp.h │ │ │ │ ├── Visitor.h │ │ │ │ ├── arch │ │ │ │ │ ├── AVX │ │ │ │ │ │ ├── Complex.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ ├── PacketMath.h │ │ │ │ │ │ └── TypeCasting.h │ │ │ │ │ ├── AVX512 │ │ │ │ │ │ ├── Complex.h │ │ │ │ │ │ ├── GemmKernel.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ ├── PacketMath.h │ │ │ │ │ │ ├── PacketMathFP16.h │ │ │ │ │ │ ├── TrsmKernel.h │ │ │ │ │ │ ├── TrsmUnrolls.inc │ │ │ │ │ │ └── TypeCasting.h │ │ │ │ │ ├── AltiVec │ │ │ │ │ │ ├── Complex.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ ├── MatrixProduct.h │ │ │ │ │ │ ├── MatrixProductCommon.h │ │ │ │ │ │ ├── MatrixProductMMA.h │ │ │ │ │ │ ├── MatrixProductMMAbfloat16.h │ │ │ │ │ │ ├── MatrixVectorProduct.h │ │ │ │ │ │ ├── PacketMath.h │ │ │ │ │ │ └── TypeCasting.h │ │ │ │ │ ├── Default │ │ │ │ │ │ ├── BFloat16.h │ │ │ │ │ │ ├── ConjHelper.h │ │ │ │ │ │ ├── GenericPacketMathFunctions.h │ │ │ │ │ │ ├── GenericPacketMathFunctionsFwd.h │ │ │ │ │ │ ├── Half.h │ │ │ │ │ │ └── Settings.h │ │ │ │ │ ├── GPU │ │ │ │ │ │ ├── Complex.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ ├── PacketMath.h │ │ │ │ │ │ ├── Tuple.h │ │ │ │ │ │ └── TypeCasting.h │ │ │ │ │ ├── HIP │ │ │ │ │ │ └── hcc │ │ │ │ │ │ │ └── math_constants.h │ │ │ │ │ ├── HVX │ │ │ │ │ │ └── PacketMath.h │ │ │ │ │ ├── MSA │ │ │ │ │ │ ├── Complex.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ └── PacketMath.h │ │ │ │ │ ├── NEON │ │ │ │ │ │ ├── Complex.h │ │ │ │ │ │ ├── GeneralBlockPanelKernel.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ ├── PacketMath.h │ │ │ │ │ │ ├── TypeCasting.h │ │ │ │ │ │ └── UnaryFunctors.h │ │ │ │ │ ├── SSE │ │ │ │ │ │ ├── Complex.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ ├── PacketMath.h │ │ │ │ │ │ └── TypeCasting.h │ │ │ │ │ ├── SVE │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ ├── PacketMath.h │ │ │ │ │ │ └── TypeCasting.h │ │ │ │ │ ├── SYCL │ │ │ │ │ │ ├── InteropHeaders.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ ├── PacketMath.h │ │ │ │ │ │ └── TypeCasting.h │ │ │ │ │ └── ZVector │ │ │ │ │ │ ├── Complex.h │ │ │ │ │ │ ├── MathFunctions.h │ │ │ │ │ │ └── PacketMath.h │ │ │ │ ├── functors │ │ │ │ │ ├── AssignmentFunctors.h │ │ │ │ │ ├── BinaryFunctors.h │ │ │ │ │ ├── NullaryFunctors.h │ │ │ │ │ ├── StlFunctors.h │ │ │ │ │ ├── TernaryFunctors.h │ │ │ │ │ └── UnaryFunctors.h │ │ │ │ ├── products │ │ │ │ │ ├── GeneralBlockPanelKernel.h │ │ │ │ │ ├── GeneralMatrixMatrix.h │ │ │ │ │ ├── GeneralMatrixMatrixTriangular.h │ │ │ │ │ ├── GeneralMatrixMatrixTriangular_BLAS.h │ │ │ │ │ ├── GeneralMatrixMatrix_BLAS.h │ │ │ │ │ ├── GeneralMatrixVector.h │ │ │ │ │ ├── GeneralMatrixVector_BLAS.h │ │ │ │ │ ├── Parallelizer.h │ │ │ │ │ ├── SelfadjointMatrixMatrix.h │ │ │ │ │ ├── SelfadjointMatrixMatrix_BLAS.h │ │ │ │ │ ├── SelfadjointMatrixVector.h │ │ │ │ │ ├── SelfadjointMatrixVector_BLAS.h │ │ │ │ │ ├── SelfadjointProduct.h │ │ │ │ │ ├── SelfadjointRank2Update.h │ │ │ │ │ ├── TriangularMatrixMatrix.h │ │ │ │ │ ├── TriangularMatrixMatrix_BLAS.h │ │ │ │ │ ├── TriangularMatrixVector.h │ │ │ │ │ ├── TriangularMatrixVector_BLAS.h │ │ │ │ │ ├── TriangularSolverMatrix.h │ │ │ │ │ ├── TriangularSolverMatrix_BLAS.h │ │ │ │ │ └── TriangularSolverVector.h │ │ │ │ └── util │ │ │ │ │ ├── Assert.h │ │ │ │ │ ├── BlasUtil.h │ │ │ │ │ ├── ConfigureVectorization.h │ │ │ │ │ ├── Constants.h │ │ │ │ │ ├── DisableStupidWarnings.h │ │ │ │ │ ├── EmulateArray.h │ │ │ │ │ ├── ForwardDeclarations.h │ │ │ │ │ ├── IndexedViewHelper.h │ │ │ │ │ ├── IntegralConstant.h │ │ │ │ │ ├── MKL_support.h │ │ │ │ │ ├── Macros.h │ │ │ │ │ ├── MaxSizeVector.h │ │ │ │ │ ├── Memory.h │ │ │ │ │ ├── Meta.h │ │ │ │ │ ├── MoreMeta.h │ │ │ │ │ ├── ReenableStupidWarnings.h │ │ │ │ │ ├── ReshapedHelper.h │ │ │ │ │ ├── Serializer.h │ │ │ │ │ ├── StaticAssert.h │ │ │ │ │ ├── SymbolicIndex.h │ │ │ │ │ └── XprHelper.h │ │ │ │ ├── Eigenvalues │ │ │ │ ├── ComplexEigenSolver.h │ │ │ │ ├── ComplexSchur.h │ │ │ │ ├── ComplexSchur_LAPACKE.h │ │ │ │ ├── EigenSolver.h │ │ │ │ ├── GeneralizedEigenSolver.h │ │ │ │ ├── GeneralizedSelfAdjointEigenSolver.h │ │ │ │ ├── HessenbergDecomposition.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── MatrixBaseEigenvalues.h │ │ │ │ ├── RealQZ.h │ │ │ │ ├── RealSchur.h │ │ │ │ ├── RealSchur_LAPACKE.h │ │ │ │ ├── SelfAdjointEigenSolver.h │ │ │ │ ├── SelfAdjointEigenSolver_LAPACKE.h │ │ │ │ └── Tridiagonalization.h │ │ │ │ ├── Geometry │ │ │ │ ├── AlignedBox.h │ │ │ │ ├── AngleAxis.h │ │ │ │ ├── EulerAngles.h │ │ │ │ ├── Homogeneous.h │ │ │ │ ├── Hyperplane.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── OrthoMethods.h │ │ │ │ ├── ParametrizedLine.h │ │ │ │ ├── Quaternion.h │ │ │ │ ├── Rotation2D.h │ │ │ │ ├── RotationBase.h │ │ │ │ ├── Scaling.h │ │ │ │ ├── Transform.h │ │ │ │ ├── Translation.h │ │ │ │ ├── Umeyama.h │ │ │ │ └── arch │ │ │ │ │ └── Geometry_SIMD.h │ │ │ │ ├── Householder │ │ │ │ ├── BlockHouseholder.h │ │ │ │ ├── Householder.h │ │ │ │ ├── HouseholderSequence.h │ │ │ │ └── InternalHeaderCheck.h │ │ │ │ ├── IterativeLinearSolvers │ │ │ │ ├── BasicPreconditioners.h │ │ │ │ ├── BiCGSTAB.h │ │ │ │ ├── ConjugateGradient.h │ │ │ │ ├── IncompleteCholesky.h │ │ │ │ ├── IncompleteLUT.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── IterativeSolverBase.h │ │ │ │ ├── LeastSquareConjugateGradient.h │ │ │ │ └── SolveWithGuess.h │ │ │ │ ├── Jacobi │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── Jacobi.h │ │ │ │ ├── KLUSupport │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── KLUSupport.h │ │ │ │ ├── LU │ │ │ │ ├── Determinant.h │ │ │ │ ├── FullPivLU.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── InverseImpl.h │ │ │ │ ├── PartialPivLU.h │ │ │ │ ├── PartialPivLU_LAPACKE.h │ │ │ │ └── arch │ │ │ │ │ └── InverseSize4.h │ │ │ │ ├── MetisSupport │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── MetisSupport.h │ │ │ │ ├── OrderingMethods │ │ │ │ ├── Amd.h │ │ │ │ ├── Eigen_Colamd.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── Ordering.h │ │ │ │ ├── PaStiXSupport │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── PaStiXSupport.h │ │ │ │ ├── PardisoSupport │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── PardisoSupport.h │ │ │ │ ├── QR │ │ │ │ ├── ColPivHouseholderQR.h │ │ │ │ ├── ColPivHouseholderQR_LAPACKE.h │ │ │ │ ├── CompleteOrthogonalDecomposition.h │ │ │ │ ├── FullPivHouseholderQR.h │ │ │ │ ├── HouseholderQR.h │ │ │ │ ├── HouseholderQR_LAPACKE.h │ │ │ │ └── InternalHeaderCheck.h │ │ │ │ ├── SPQRSupport │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── SuiteSparseQRSupport.h │ │ │ │ ├── SVD │ │ │ │ ├── BDCSVD.h │ │ │ │ ├── BDCSVD_LAPACKE.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── JacobiSVD.h │ │ │ │ ├── JacobiSVD_LAPACKE.h │ │ │ │ ├── SVDBase.h │ │ │ │ └── UpperBidiagonalization.h │ │ │ │ ├── SparseCholesky │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── SimplicialCholesky.h │ │ │ │ └── SimplicialCholesky_impl.h │ │ │ │ ├── SparseCore │ │ │ │ ├── AmbiVector.h │ │ │ │ ├── CompressedStorage.h │ │ │ │ ├── ConservativeSparseSparseProduct.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── SparseAssign.h │ │ │ │ ├── SparseBlock.h │ │ │ │ ├── SparseColEtree.h │ │ │ │ ├── SparseCompressedBase.h │ │ │ │ ├── SparseCwiseBinaryOp.h │ │ │ │ ├── SparseCwiseUnaryOp.h │ │ │ │ ├── SparseDenseProduct.h │ │ │ │ ├── SparseDiagonalProduct.h │ │ │ │ ├── SparseDot.h │ │ │ │ ├── SparseFuzzy.h │ │ │ │ ├── SparseMap.h │ │ │ │ ├── SparseMatrix.h │ │ │ │ ├── SparseMatrixBase.h │ │ │ │ ├── SparsePermutation.h │ │ │ │ ├── SparseProduct.h │ │ │ │ ├── SparseRedux.h │ │ │ │ ├── SparseRef.h │ │ │ │ ├── SparseSelfAdjointView.h │ │ │ │ ├── SparseSolverBase.h │ │ │ │ ├── SparseSparseProductWithPruning.h │ │ │ │ ├── SparseTranspose.h │ │ │ │ ├── SparseTriangularView.h │ │ │ │ ├── SparseUtil.h │ │ │ │ ├── SparseVector.h │ │ │ │ ├── SparseView.h │ │ │ │ └── TriangularSolver.h │ │ │ │ ├── SparseLU │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── SparseLU.h │ │ │ │ ├── SparseLUImpl.h │ │ │ │ ├── SparseLU_Memory.h │ │ │ │ ├── SparseLU_Structs.h │ │ │ │ ├── SparseLU_SupernodalMatrix.h │ │ │ │ ├── SparseLU_Utils.h │ │ │ │ ├── SparseLU_column_bmod.h │ │ │ │ ├── SparseLU_column_dfs.h │ │ │ │ ├── SparseLU_copy_to_ucol.h │ │ │ │ ├── SparseLU_heap_relax_snode.h │ │ │ │ ├── SparseLU_kernel_bmod.h │ │ │ │ ├── SparseLU_panel_bmod.h │ │ │ │ ├── SparseLU_panel_dfs.h │ │ │ │ ├── SparseLU_pivotL.h │ │ │ │ ├── SparseLU_pruneL.h │ │ │ │ └── SparseLU_relax_snode.h │ │ │ │ ├── SparseQR │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── SparseQR.h │ │ │ │ ├── StlSupport │ │ │ │ ├── StdDeque.h │ │ │ │ ├── StdList.h │ │ │ │ ├── StdVector.h │ │ │ │ └── details.h │ │ │ │ ├── SuperLUSupport │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── SuperLUSupport.h │ │ │ │ ├── ThreadPool │ │ │ │ ├── Barrier.h │ │ │ │ ├── CoreThreadPoolDevice.h │ │ │ │ ├── EventCount.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── NonBlockingThreadPool.h │ │ │ │ ├── RunQueue.h │ │ │ │ ├── ThreadCancel.h │ │ │ │ ├── ThreadEnvironment.h │ │ │ │ ├── ThreadLocal.h │ │ │ │ ├── ThreadPoolInterface.h │ │ │ │ └── ThreadYield.h │ │ │ │ ├── UmfPackSupport │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ └── UmfPackSupport.h │ │ │ │ ├── misc │ │ │ │ ├── Image.h │ │ │ │ ├── InternalHeaderCheck.h │ │ │ │ ├── Kernel.h │ │ │ │ ├── RealSvd2x2.h │ │ │ │ ├── blas.h │ │ │ │ ├── lapacke.h │ │ │ │ ├── lapacke_helpers.h │ │ │ │ └── lapacke_mangling.h │ │ │ │ └── plugins │ │ │ │ ├── ArrayCwiseBinaryOps.inc │ │ │ │ ├── ArrayCwiseUnaryOps.inc │ │ │ │ ├── BlockMethods.inc │ │ │ │ ├── CommonCwiseBinaryOps.inc │ │ │ │ ├── CommonCwiseUnaryOps.inc │ │ │ │ ├── IndexedViewMethods.inc │ │ │ │ ├── InternalHeaderCheck.inc │ │ │ │ ├── MatrixCwiseBinaryOps.inc │ │ │ │ ├── MatrixCwiseUnaryOps.inc │ │ │ │ └── ReshapedMethods.inc │ │ ├── eigen.natvis │ │ └── signature_of_eigen3_matrix_library │ ├── TriangleMeshCollisionDetection │ │ ├── CMakeLists.txt │ │ ├── LICENSE.txt │ │ ├── include │ │ │ └── TriangleMeshCollisionDetection │ │ └── src │ │ │ ├── AABBs.cpp │ │ │ ├── AABBs.h │ │ │ ├── BroadPhaseBase.cpp │ │ │ ├── BroadPhaseBase.h │ │ │ ├── BroadPhaseET.cpp │ │ │ ├── BroadPhaseET.h │ │ │ ├── BroadPhasePTEE.cpp │ │ │ ├── BroadPhasePTEE.h │ │ │ ├── BroadPhasePTEEBase.cpp │ │ │ ├── BroadPhasePTEEBase.h │ │ │ ├── BroadPhasePTEECCD.cpp │ │ │ ├── BroadPhasePTEECCD.h │ │ │ ├── IntersectionDetection.cpp │ │ │ ├── IntersectionDetection.h │ │ │ ├── IntersectionResults.h │ │ │ ├── Meshes.cpp │ │ │ ├── Meshes.h │ │ │ ├── Octree.cpp │ │ │ ├── Octree.h │ │ │ ├── ProximityDetection.cpp │ │ │ ├── ProximityDetection.h │ │ │ ├── ProximityResults.h │ │ │ ├── RecursiveBuffer.h │ │ │ ├── Vec3.h │ │ │ ├── alignment_allocator.h │ │ │ ├── helpers.h │ │ │ ├── info_structs.h │ │ │ ├── ipc_toolkit_geometry_functions.cpp │ │ │ ├── ipc_toolkit_geometry_functions.h │ │ │ ├── shuffle_lut.h │ │ │ └── types.h │ ├── TriangleMeshDistance │ │ ├── LICENSE │ │ └── include │ │ │ └── tmd │ │ │ └── TriangleMeshDistance.h │ ├── fmt │ │ ├── .clang-format │ │ ├── CMakeLists.txt │ │ ├── CONTRIBUTING.md │ │ ├── ChangeLog.rst │ │ ├── LICENSE.rst │ │ ├── README.rst │ │ ├── doc │ │ │ ├── CMakeLists.txt │ │ │ ├── _static │ │ │ │ ├── bootstrap.min.js │ │ │ │ └── fonts │ │ │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ │ │ └── glyphicons-halflings-regular.woff │ │ │ ├── _templates │ │ │ │ ├── layout.html │ │ │ │ └── search.html │ │ │ ├── api.rst │ │ │ ├── basic-bootstrap │ │ │ │ ├── README │ │ │ │ ├── layout.html │ │ │ │ └── theme.conf │ │ │ ├── bootstrap │ │ │ │ ├── alerts.less │ │ │ │ ├── badges.less │ │ │ │ ├── bootstrap.less │ │ │ │ ├── breadcrumbs.less │ │ │ │ ├── button-groups.less │ │ │ │ ├── buttons.less │ │ │ │ ├── carousel.less │ │ │ │ ├── close.less │ │ │ │ ├── code.less │ │ │ │ ├── component-animations.less │ │ │ │ ├── dropdowns.less │ │ │ │ ├── forms.less │ │ │ │ ├── glyphicons.less │ │ │ │ ├── grid.less │ │ │ │ ├── input-groups.less │ │ │ │ ├── jumbotron.less │ │ │ │ ├── labels.less │ │ │ │ ├── list-group.less │ │ │ │ ├── media.less │ │ │ │ ├── mixins.less │ │ │ │ ├── mixins │ │ │ │ │ ├── alerts.less │ │ │ │ │ ├── background-variant.less │ │ │ │ │ ├── border-radius.less │ │ │ │ │ ├── buttons.less │ │ │ │ │ ├── center-block.less │ │ │ │ │ ├── clearfix.less │ │ │ │ │ ├── forms.less │ │ │ │ │ ├── gradients.less │ │ │ │ │ ├── grid-framework.less │ │ │ │ │ ├── grid.less │ │ │ │ │ ├── hide-text.less │ │ │ │ │ ├── image.less │ │ │ │ │ ├── labels.less │ │ │ │ │ ├── list-group.less │ │ │ │ │ ├── nav-divider.less │ │ │ │ │ ├── nav-vertical-align.less │ │ │ │ │ ├── opacity.less │ │ │ │ │ ├── pagination.less │ │ │ │ │ ├── panels.less │ │ │ │ │ ├── progress-bar.less │ │ │ │ │ ├── reset-filter.less │ │ │ │ │ ├── resize.less │ │ │ │ │ ├── responsive-visibility.less │ │ │ │ │ ├── size.less │ │ │ │ │ ├── tab-focus.less │ │ │ │ │ ├── table-row.less │ │ │ │ │ ├── text-emphasis.less │ │ │ │ │ ├── text-overflow.less │ │ │ │ │ └── vendor-prefixes.less │ │ │ │ ├── modals.less │ │ │ │ ├── navbar.less │ │ │ │ ├── navs.less │ │ │ │ ├── normalize.less │ │ │ │ ├── pager.less │ │ │ │ ├── pagination.less │ │ │ │ ├── panels.less │ │ │ │ ├── popovers.less │ │ │ │ ├── print.less │ │ │ │ ├── progress-bars.less │ │ │ │ ├── responsive-embed.less │ │ │ │ ├── responsive-utilities.less │ │ │ │ ├── scaffolding.less │ │ │ │ ├── tables.less │ │ │ │ ├── theme.less │ │ │ │ ├── thumbnails.less │ │ │ │ ├── tooltip.less │ │ │ │ ├── type.less │ │ │ │ ├── utilities.less │ │ │ │ ├── variables.less │ │ │ │ └── wells.less │ │ │ ├── build.py │ │ │ ├── conf.py │ │ │ ├── contents.rst │ │ │ ├── fmt.less │ │ │ ├── html │ │ │ │ ├── _sources │ │ │ │ │ ├── api.rst.txt │ │ │ │ │ ├── contents.rst.txt │ │ │ │ │ ├── index.rst.txt │ │ │ │ │ ├── syntax.rst.txt │ │ │ │ │ └── usage.rst.txt │ │ │ │ ├── _static │ │ │ │ │ ├── basic.css │ │ │ │ │ ├── bootstrap.min.js │ │ │ │ │ ├── doctools.js │ │ │ │ │ ├── documentation_options.js │ │ │ │ │ ├── file.png │ │ │ │ │ ├── fmt.css │ │ │ │ │ ├── fonts │ │ │ │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ │ │ │ └── glyphicons-halflings-regular.woff │ │ │ │ │ ├── jquery-3.5.1.js │ │ │ │ │ ├── jquery.js │ │ │ │ │ ├── language_data.js │ │ │ │ │ ├── minus.png │ │ │ │ │ ├── plus.png │ │ │ │ │ ├── pygments.css │ │ │ │ │ ├── searchtools.js │ │ │ │ │ ├── underscore-1.3.1.js │ │ │ │ │ └── underscore.js │ │ │ │ ├── api.html │ │ │ │ ├── contents.html │ │ │ │ ├── genindex.html │ │ │ │ ├── index.html │ │ │ │ ├── objects.inv │ │ │ │ ├── search.html │ │ │ │ ├── searchindex.js │ │ │ │ ├── syntax.html │ │ │ │ └── usage.html │ │ │ ├── index.rst │ │ │ ├── python-license.txt │ │ │ ├── syntax.rst │ │ │ └── usage.rst │ │ ├── include │ │ │ └── fmt │ │ │ │ ├── args.h │ │ │ │ ├── chrono.h │ │ │ │ ├── color.h │ │ │ │ ├── compile.h │ │ │ │ ├── core.h │ │ │ │ ├── format-inl.h │ │ │ │ ├── format.h │ │ │ │ ├── os.h │ │ │ │ ├── ostream.h │ │ │ │ ├── printf.h │ │ │ │ ├── ranges.h │ │ │ │ ├── std.h │ │ │ │ └── xchar.h │ │ ├── src │ │ │ ├── fmt.cc │ │ │ ├── format.cc │ │ │ └── os.cc │ │ ├── support │ │ │ ├── Android.mk │ │ │ ├── AndroidManifest.xml │ │ │ ├── C++.sublime-syntax │ │ │ ├── README │ │ │ ├── Vagrantfile │ │ │ ├── bazel │ │ │ │ ├── .bazelversion │ │ │ │ ├── BUILD.bazel │ │ │ │ ├── README.md │ │ │ │ └── WORKSPACE.bazel │ │ │ ├── build-docs.py │ │ │ ├── build.gradle │ │ │ ├── cmake │ │ │ │ ├── FindSetEnv.cmake │ │ │ │ ├── JoinPaths.cmake │ │ │ │ ├── fmt-config.cmake.in │ │ │ │ └── fmt.pc.in │ │ │ ├── compute-powers.py │ │ │ ├── docopt.py │ │ │ ├── manage.py │ │ │ ├── printable.py │ │ │ ├── rst2md.py │ │ │ └── rtd │ │ │ │ ├── conf.py │ │ │ │ ├── index.rst │ │ │ │ └── theme │ │ │ │ ├── layout.html │ │ │ │ └── theme.conf │ │ └── test │ │ │ ├── CMakeLists.txt │ │ │ ├── add-subdirectory-test │ │ │ ├── CMakeLists.txt │ │ │ └── main.cc │ │ │ ├── args-test.cc │ │ │ ├── assert-test.cc │ │ │ ├── chrono-test.cc │ │ │ ├── color-test.cc │ │ │ ├── compile-error-test │ │ │ └── CMakeLists.txt │ │ │ ├── compile-fp-test.cc │ │ │ ├── compile-test.cc │ │ │ ├── core-test.cc │ │ │ ├── cuda-test │ │ │ ├── CMakeLists.txt │ │ │ ├── cpp14.cc │ │ │ └── cuda-cpp14.cu │ │ │ ├── detect-stdfs.cc │ │ │ ├── enforce-checks-test.cc │ │ │ ├── find-package-test │ │ │ ├── CMakeLists.txt │ │ │ └── main.cc │ │ │ ├── format-impl-test.cc │ │ │ ├── format-test.cc │ │ │ ├── fuzzing │ │ │ ├── CMakeLists.txt │ │ │ ├── README.md │ │ │ ├── build.sh │ │ │ ├── chrono-duration.cc │ │ │ ├── chrono-timepoint.cc │ │ │ ├── float.cc │ │ │ ├── fuzzer-common.h │ │ │ ├── main.cc │ │ │ ├── named-arg.cc │ │ │ ├── one-arg.cc │ │ │ └── two-args.cc │ │ │ ├── gtest-extra-test.cc │ │ │ ├── gtest-extra.cc │ │ │ ├── gtest-extra.h │ │ │ ├── gtest │ │ │ ├── .clang-format │ │ │ ├── CMakeLists.txt │ │ │ ├── gmock-gtest-all.cc │ │ │ ├── gmock │ │ │ │ └── gmock.h │ │ │ └── gtest │ │ │ │ ├── gtest-spi.h │ │ │ │ └── gtest.h │ │ │ ├── header-only-test.cc │ │ │ ├── mock-allocator.h │ │ │ ├── module-test.cc │ │ │ ├── noexception-test.cc │ │ │ ├── os-test.cc │ │ │ ├── ostream-test.cc │ │ │ ├── posix-mock-test.cc │ │ │ ├── posix-mock.h │ │ │ ├── printf-test.cc │ │ │ ├── ranges-odr-test.cc │ │ │ ├── ranges-test.cc │ │ │ ├── scan-test.cc │ │ │ ├── scan.h │ │ │ ├── static-export-test │ │ │ ├── CMakeLists.txt │ │ │ ├── library.cc │ │ │ └── main.cc │ │ │ ├── std-test.cc │ │ │ ├── test-assert.h │ │ │ ├── test-main.cc │ │ │ ├── unicode-test.cc │ │ │ ├── util.cc │ │ │ ├── util.h │ │ │ └── xchar-test.cc │ ├── par_shapes │ │ └── include │ │ │ └── par_shapes │ │ │ └── par_shapes.h │ ├── symx │ │ ├── CMakeLists.txt │ │ ├── LICENSE │ │ ├── extern │ │ │ ├── BlockedSparseMatrix │ │ │ │ ├── LICENSE │ │ │ │ └── include │ │ │ │ │ └── BlockedSparseMatrix │ │ │ │ │ ├── AlignmentAllocator.h │ │ │ │ │ ├── BlockedSparseMatrix.h │ │ │ │ │ ├── ConjugateGradientMethod.h │ │ │ │ │ ├── LICENSE │ │ │ │ │ ├── ParallelNumber.h │ │ │ │ │ ├── ParallelVector.h │ │ │ │ │ └── types.h │ │ │ └── picoSHA2 │ │ │ │ └── include │ │ │ │ └── picoSHA2 │ │ │ │ └── picosha2.h │ │ ├── include │ │ │ └── symx │ │ └── src │ │ │ ├── AlignmentAllocator.h │ │ │ ├── Assembly.cpp │ │ │ ├── Assembly.h │ │ │ ├── Compilation.cpp │ │ │ ├── Compilation.h │ │ │ ├── Compiled.cpp │ │ │ ├── Compiled.h │ │ │ ├── CompiledInLoop.h │ │ │ ├── Element.cpp │ │ │ ├── Element.h │ │ │ ├── Energy.cpp │ │ │ ├── Energy.h │ │ │ ├── EvalSequence.cpp │ │ │ ├── EvalSequence.h │ │ │ ├── Expr.h │ │ │ ├── Expressions.cpp │ │ │ ├── Expressions.h │ │ │ ├── FixedBranchSequence.cpp │ │ │ ├── FixedBranchSequence.h │ │ │ ├── GlobalEnergy.cpp │ │ │ ├── GlobalEnergy.h │ │ │ ├── LabelledConnectivity.h │ │ │ ├── Matrix.cpp │ │ │ ├── Matrix.h │ │ │ ├── Scalar.cpp │ │ │ ├── Scalar.h │ │ │ ├── Sequence.cpp │ │ │ ├── Sequence.h │ │ │ ├── SymbolicWorkSpace.cpp │ │ │ ├── SymbolicWorkSpace.h │ │ │ ├── Vector.cpp │ │ │ ├── Vector.h │ │ │ ├── diff.cpp │ │ │ ├── diff.h │ │ │ ├── hashing.h │ │ │ ├── lambdas.h │ │ │ ├── project_to_PD.h │ │ │ ├── simd_utils.h │ │ │ ├── utils.cpp │ │ │ └── utils.h │ ├── tinyobjloader │ │ └── include │ │ │ └── tinyobjloader.h │ └── vtkio │ │ ├── LICENSE │ │ ├── include │ │ └── vtkio │ │ └── src │ │ ├── ByteBuffer.h │ │ ├── VTKFile.h │ │ ├── dynamic_types.h │ │ ├── endianness.h │ │ ├── stream_io.h │ │ └── tables.h ├── include │ └── stark └── src │ ├── core │ ├── Callbacks.h │ ├── Console.cpp │ ├── Console.h │ ├── EventDrivenScript.cpp │ ├── EventDrivenScript.h │ ├── Logger.cpp │ ├── Logger.h │ ├── NewtonsMethod.cpp │ ├── NewtonsMethod.h │ ├── Settings.cpp │ ├── Settings.h │ ├── Stark.cpp │ ├── Stark.h │ └── include_ui.h │ ├── models │ ├── IntervalVector.h │ ├── MeshOutputGroups.cpp │ ├── MeshOutputGroups.h │ ├── Simulation.cpp │ ├── Simulation.h │ ├── deformables │ │ ├── Deformables.cpp │ │ ├── Deformables.h │ │ ├── DeformablesMeshOutput.cpp │ │ ├── DeformablesMeshOutput.h │ │ ├── PointDynamics.cpp │ │ ├── PointDynamics.h │ │ ├── PointSetHandler.cpp │ │ ├── PointSetHandler.h │ │ ├── deformable_tools.cpp │ │ ├── deformable_tools.h │ │ ├── deformables_energies_include.h │ │ ├── line │ │ │ ├── EnergySegmentStrain.cpp │ │ │ └── EnergySegmentStrain.h │ │ ├── point │ │ │ ├── EnergyLumpedInertia.cpp │ │ │ ├── EnergyLumpedInertia.h │ │ │ ├── EnergyPrescribedPositions.cpp │ │ │ └── EnergyPrescribedPositions.h │ │ ├── surface │ │ │ ├── EnergyDiscreteShells.cpp │ │ │ ├── EnergyDiscreteShells.h │ │ │ ├── EnergyMicropolarShell.cpp │ │ │ ├── EnergyMicropolarShell.h │ │ │ ├── EnergyTriangleStrain.cpp │ │ │ ├── EnergyTriangleStrain.h │ │ │ ├── EnergyTriangleStrainKim20.cpp │ │ │ ├── EnergyTriangleStrainKim20.h │ │ │ ├── EnergyTriangleStrainWen23.cpp │ │ │ └── EnergyTriangleStrainWen23.h │ │ └── volume │ │ │ ├── EnergyTetStrain.cpp │ │ │ └── EnergyTetStrain.h │ ├── distances.cpp │ ├── distances.h │ ├── fem_elements.h │ ├── fem_quadrature.cpp │ ├── fem_quadrature.h │ ├── fem_symx_types.h │ ├── fem_types.h │ ├── include.h │ ├── interactions │ │ ├── EnergyAttachments.cpp │ │ ├── EnergyAttachments.h │ │ ├── EnergyFrictionalContact.cpp │ │ ├── EnergyFrictionalContact.h │ │ ├── EnergyFrictionalContact_NEW_DRAFT.cpp │ │ ├── EnergyFrictionalContact_NEW_DRAFT.h │ │ ├── Interactions.cpp │ │ ├── Interactions.h │ │ ├── contact_and_friction_data.h │ │ ├── friction_geometry.cpp │ │ └── friction_geometry.h │ ├── matrix_wrapper.h │ ├── presets │ │ ├── DeformablesPresets.cpp │ │ ├── DeformablesPresets.h │ │ ├── Presets.cpp │ │ ├── Presets.h │ │ ├── RigidBodyPresets.cpp │ │ ├── RigidBodyPresets.h │ │ ├── deformables_preset_types.cpp │ │ └── deformables_preset_types.h │ ├── rigidbodies │ │ ├── EnergyRigidBodyConstraints.cpp │ │ ├── EnergyRigidBodyConstraints.h │ │ ├── EnergyRigidBodyInertia.cpp │ │ ├── EnergyRigidBodyInertia.h │ │ ├── RigidBodies.cpp │ │ ├── RigidBodies.h │ │ ├── RigidBodiesMeshOutput.cpp │ │ ├── RigidBodiesMeshOutput.h │ │ ├── RigidBodyConstraints.h │ │ ├── RigidBodyDynamics.cpp │ │ ├── RigidBodyDynamics.h │ │ ├── RigidBodyHandler.cpp │ │ ├── RigidBodyHandler.h │ │ ├── inertia_tensors.cpp │ │ ├── inertia_tensors.h │ │ ├── rigid_body_constraint_utils.h │ │ ├── rigidbody_constraints_ui.h │ │ ├── rigidbody_transformations.cpp │ │ └── rigidbody_transformations.h │ ├── symx_quaternion.cpp │ ├── symx_quaternion.h │ ├── time_integration.cpp │ ├── time_integration.h │ └── types.h │ └── utils │ ├── Mesh.h │ ├── blends.cpp │ ├── blends.h │ ├── include.h │ ├── mesh_generators.cpp │ ├── mesh_generators.h │ ├── mesh_utils.cpp │ ├── mesh_utils.h │ └── unordered_array_set_and_map.h └── tests ├── CMakeLists.txt ├── extern └── Catch2 │ ├── CMake │ ├── Catch2Config.cmake.in │ ├── CatchConfigOptions.cmake │ ├── CatchMiscFunctions.cmake │ ├── FindGcov.cmake │ ├── FindLcov.cmake │ ├── Findcodecov.cmake │ ├── catch2-with-main.pc.in │ ├── catch2.pc.in │ └── llvm-cov-wrapper │ ├── CMakeLists.txt │ ├── LICENSE.txt │ └── src │ ├── CMakeLists.txt │ └── catch2 │ ├── benchmark │ ├── catch_benchmark.hpp │ ├── catch_benchmark_all.hpp │ ├── catch_chronometer.cpp │ ├── catch_chronometer.hpp │ ├── catch_clock.hpp │ ├── catch_constructor.hpp │ ├── catch_environment.hpp │ ├── catch_estimate.hpp │ ├── catch_execution_plan.hpp │ ├── catch_optimizer.hpp │ ├── catch_outlier_classification.hpp │ ├── catch_sample_analysis.hpp │ └── detail │ │ ├── catch_analyse.cpp │ │ ├── catch_analyse.hpp │ │ ├── catch_benchmark_function.cpp │ │ ├── catch_benchmark_function.hpp │ │ ├── catch_benchmark_stats.hpp │ │ ├── catch_benchmark_stats_fwd.hpp │ │ ├── catch_complete_invoke.hpp │ │ ├── catch_estimate_clock.hpp │ │ ├── catch_measure.hpp │ │ ├── catch_repeat.hpp │ │ ├── catch_run_for_at_least.cpp │ │ ├── catch_run_for_at_least.hpp │ │ ├── catch_stats.cpp │ │ ├── catch_stats.hpp │ │ └── catch_timing.hpp │ ├── catch_all.hpp │ ├── catch_approx.cpp │ ├── catch_approx.hpp │ ├── catch_assertion_info.hpp │ ├── catch_assertion_result.cpp │ ├── catch_assertion_result.hpp │ ├── catch_config.cpp │ ├── catch_config.hpp │ ├── catch_get_random_seed.cpp │ ├── catch_get_random_seed.hpp │ ├── catch_message.cpp │ ├── catch_message.hpp │ ├── catch_registry_hub.cpp │ ├── catch_section_info.hpp │ ├── catch_session.cpp │ ├── catch_session.hpp │ ├── catch_tag_alias.hpp │ ├── catch_tag_alias_autoregistrar.cpp │ ├── catch_tag_alias_autoregistrar.hpp │ ├── catch_template_test_macros.hpp │ ├── catch_test_case_info.cpp │ ├── catch_test_case_info.hpp │ ├── catch_test_macros.hpp │ ├── catch_test_spec.cpp │ ├── catch_test_spec.hpp │ ├── catch_timer.cpp │ ├── catch_timer.hpp │ ├── catch_tostring.cpp │ ├── catch_tostring.hpp │ ├── catch_totals.cpp │ ├── catch_totals.hpp │ ├── catch_translate_exception.cpp │ ├── catch_translate_exception.hpp │ ├── catch_user_config.hpp.in │ ├── catch_version.cpp │ ├── catch_version.hpp │ ├── catch_version_macros.hpp │ ├── generators │ ├── catch_generator_exception.cpp │ ├── catch_generator_exception.hpp │ ├── catch_generators.cpp │ ├── catch_generators.hpp │ ├── catch_generators_adapters.hpp │ ├── catch_generators_all.hpp │ ├── catch_generators_random.cpp │ ├── catch_generators_random.hpp │ └── catch_generators_range.hpp │ ├── interfaces │ ├── catch_interfaces_all.hpp │ ├── catch_interfaces_capture.cpp │ ├── catch_interfaces_capture.hpp │ ├── catch_interfaces_config.cpp │ ├── catch_interfaces_config.hpp │ ├── catch_interfaces_enum_values_registry.hpp │ ├── catch_interfaces_exception.cpp │ ├── catch_interfaces_exception.hpp │ ├── catch_interfaces_generatortracker.cpp │ ├── catch_interfaces_generatortracker.hpp │ ├── catch_interfaces_registry_hub.cpp │ ├── catch_interfaces_registry_hub.hpp │ ├── catch_interfaces_reporter.cpp │ ├── catch_interfaces_reporter.hpp │ ├── catch_interfaces_reporter_factory.cpp │ ├── catch_interfaces_reporter_factory.hpp │ ├── catch_interfaces_tag_alias_registry.hpp │ ├── catch_interfaces_test_invoker.hpp │ ├── catch_interfaces_testcase.cpp │ └── catch_interfaces_testcase.hpp │ ├── internal │ ├── catch_assertion_handler.cpp │ ├── catch_assertion_handler.hpp │ ├── catch_case_insensitive_comparisons.cpp │ ├── catch_case_insensitive_comparisons.hpp │ ├── catch_case_sensitive.hpp │ ├── catch_clara.cpp │ ├── catch_clara.hpp │ ├── catch_commandline.cpp │ ├── catch_commandline.hpp │ ├── catch_compare_traits.hpp │ ├── catch_compiler_capabilities.hpp │ ├── catch_config_android_logwrite.hpp │ ├── catch_config_counter.hpp │ ├── catch_config_prefix_messages.hpp │ ├── catch_config_static_analysis_support.hpp │ ├── catch_config_uncaught_exceptions.hpp │ ├── catch_config_wchar.hpp │ ├── catch_console_colour.cpp │ ├── catch_console_colour.hpp │ ├── catch_console_width.hpp │ ├── catch_container_nonmembers.hpp │ ├── catch_context.cpp │ ├── catch_context.hpp │ ├── catch_debug_console.cpp │ ├── catch_debug_console.hpp │ ├── catch_debugger.cpp │ ├── catch_debugger.hpp │ ├── catch_decomposer.cpp │ ├── catch_decomposer.hpp │ ├── catch_enforce.cpp │ ├── catch_enforce.hpp │ ├── catch_enum_values_registry.cpp │ ├── catch_enum_values_registry.hpp │ ├── catch_errno_guard.cpp │ ├── catch_errno_guard.hpp │ ├── catch_exception_translator_registry.cpp │ ├── catch_exception_translator_registry.hpp │ ├── catch_fatal_condition_handler.cpp │ ├── catch_fatal_condition_handler.hpp │ ├── catch_floating_point_helpers.cpp │ ├── catch_floating_point_helpers.hpp │ ├── catch_getenv.cpp │ ├── catch_getenv.hpp │ ├── catch_is_permutation.hpp │ ├── catch_istream.cpp │ ├── catch_istream.hpp │ ├── catch_jsonwriter.cpp │ ├── catch_jsonwriter.hpp │ ├── catch_lazy_expr.cpp │ ├── catch_lazy_expr.hpp │ ├── catch_leak_detector.cpp │ ├── catch_leak_detector.hpp │ ├── catch_list.cpp │ ├── catch_list.hpp │ ├── catch_logical_traits.hpp │ ├── catch_main.cpp │ ├── catch_message_info.cpp │ ├── catch_message_info.hpp │ ├── catch_meta.hpp │ ├── catch_move_and_forward.hpp │ ├── catch_noncopyable.hpp │ ├── catch_optional.hpp │ ├── catch_output_redirect.cpp │ ├── catch_output_redirect.hpp │ ├── catch_parse_numbers.cpp │ ├── catch_parse_numbers.hpp │ ├── catch_platform.hpp │ ├── catch_polyfills.cpp │ ├── catch_polyfills.hpp │ ├── catch_preprocessor.hpp │ ├── catch_preprocessor_internal_stringify.hpp │ ├── catch_preprocessor_remove_parens.hpp │ ├── catch_random_number_generator.cpp │ ├── catch_random_number_generator.hpp │ ├── catch_random_seed_generation.cpp │ ├── catch_random_seed_generation.hpp │ ├── catch_reporter_registry.cpp │ ├── catch_reporter_registry.hpp │ ├── catch_reporter_spec_parser.cpp │ ├── catch_reporter_spec_parser.hpp │ ├── catch_result_type.cpp │ ├── catch_result_type.hpp │ ├── catch_reusable_string_stream.cpp │ ├── catch_reusable_string_stream.hpp │ ├── catch_run_context.cpp │ ├── catch_run_context.hpp │ ├── catch_section.cpp │ ├── catch_section.hpp │ ├── catch_sharding.hpp │ ├── catch_singletons.cpp │ ├── catch_singletons.hpp │ ├── catch_source_line_info.cpp │ ├── catch_source_line_info.hpp │ ├── catch_startup_exception_registry.cpp │ ├── catch_startup_exception_registry.hpp │ ├── catch_stdstreams.cpp │ ├── catch_stdstreams.hpp │ ├── catch_stream_end_stop.hpp │ ├── catch_string_manip.cpp │ ├── catch_string_manip.hpp │ ├── catch_stringref.cpp │ ├── catch_stringref.hpp │ ├── catch_tag_alias_registry.cpp │ ├── catch_tag_alias_registry.hpp │ ├── catch_template_test_registry.hpp │ ├── catch_test_case_info_hasher.cpp │ ├── catch_test_case_info_hasher.hpp │ ├── catch_test_case_registry_impl.cpp │ ├── catch_test_case_registry_impl.hpp │ ├── catch_test_case_tracker.cpp │ ├── catch_test_case_tracker.hpp │ ├── catch_test_failure_exception.cpp │ ├── catch_test_failure_exception.hpp │ ├── catch_test_macro_impl.hpp │ ├── catch_test_registry.cpp │ ├── catch_test_registry.hpp │ ├── catch_test_run_info.hpp │ ├── catch_test_spec_parser.cpp │ ├── catch_test_spec_parser.hpp │ ├── catch_textflow.cpp │ ├── catch_textflow.hpp │ ├── catch_to_string.hpp │ ├── catch_uncaught_exceptions.cpp │ ├── catch_uncaught_exceptions.hpp │ ├── catch_unique_name.hpp │ ├── catch_unique_ptr.hpp │ ├── catch_void_type.hpp │ ├── catch_wildcard_pattern.cpp │ ├── catch_wildcard_pattern.hpp │ ├── catch_windows_h_proxy.hpp │ ├── catch_xmlwriter.cpp │ └── catch_xmlwriter.hpp │ ├── matchers │ ├── catch_matchers.cpp │ ├── catch_matchers.hpp │ ├── catch_matchers_all.hpp │ ├── catch_matchers_container_properties.cpp │ ├── catch_matchers_container_properties.hpp │ ├── catch_matchers_contains.hpp │ ├── catch_matchers_exception.cpp │ ├── catch_matchers_exception.hpp │ ├── catch_matchers_floating_point.cpp │ ├── catch_matchers_floating_point.hpp │ ├── catch_matchers_predicate.cpp │ ├── catch_matchers_predicate.hpp │ ├── catch_matchers_quantifiers.cpp │ ├── catch_matchers_quantifiers.hpp │ ├── catch_matchers_range_equals.hpp │ ├── catch_matchers_string.cpp │ ├── catch_matchers_string.hpp │ ├── catch_matchers_templated.cpp │ ├── catch_matchers_templated.hpp │ ├── catch_matchers_vector.hpp │ └── internal │ │ ├── catch_matchers_impl.cpp │ │ └── catch_matchers_impl.hpp │ ├── meson.build │ └── reporters │ ├── catch_reporter_automake.cpp │ ├── catch_reporter_automake.hpp │ ├── catch_reporter_common_base.cpp │ ├── catch_reporter_common_base.hpp │ ├── catch_reporter_compact.cpp │ ├── catch_reporter_compact.hpp │ ├── catch_reporter_console.cpp │ ├── catch_reporter_console.hpp │ ├── catch_reporter_cumulative_base.cpp │ ├── catch_reporter_cumulative_base.hpp │ ├── catch_reporter_event_listener.cpp │ ├── catch_reporter_event_listener.hpp │ ├── catch_reporter_helpers.cpp │ ├── catch_reporter_helpers.hpp │ ├── catch_reporter_json.cpp │ ├── catch_reporter_json.hpp │ ├── catch_reporter_junit.cpp │ ├── catch_reporter_junit.hpp │ ├── catch_reporter_multi.cpp │ ├── catch_reporter_multi.hpp │ ├── catch_reporter_registrars.cpp │ ├── catch_reporter_registrars.hpp │ ├── catch_reporter_sonarqube.cpp │ ├── catch_reporter_sonarqube.hpp │ ├── catch_reporter_streaming_base.cpp │ ├── catch_reporter_streaming_base.hpp │ ├── catch_reporter_tap.cpp │ ├── catch_reporter_tap.hpp │ ├── catch_reporter_teamcity.cpp │ ├── catch_reporter_teamcity.hpp │ ├── catch_reporter_xml.cpp │ ├── catch_reporter_xml.hpp │ └── catch_reporters_all.hpp └── rb_constraints.cpp /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | 3 | *.pyc 4 | *.pyi 5 | *.pyd 6 | 7 | .idea/ 8 | cmake-build-*/ 9 | build/ 10 | codegen/ 11 | output/ 12 | -------------------------------------------------------------------------------- /CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.15...3.27) 2 | project(stark) 3 | set(CMAKE_CXX_STANDARD 20) 4 | 5 | # Compile options for address sanitizer and Libcxx debug 6 | #add_compile_options(-fsanitize=address -fno-omit-frame-pointer -g -D_GLIBCXX_DEBUG) 7 | #add_link_options(-fsanitize=address) 8 | 9 | add_subdirectory(stark) 10 | add_subdirectory(examples) 11 | add_subdirectory(tests) 12 | -------------------------------------------------------------------------------- /docs/images/dumpling.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/docs/images/dumpling.png -------------------------------------------------------------------------------- /docs/images/scroll.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/docs/images/scroll.png -------------------------------------------------------------------------------- /docs/images/strip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/docs/images/strip.png -------------------------------------------------------------------------------- /examples/paths.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | static const std::string MODELS_PATH = "models"; 5 | static const std::string OUTPUT_PATH = "output"; 6 | static const std::string COMPILE_PATH = "codegen"; 7 | -------------------------------------------------------------------------------- /examples/utils.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | /// Wraps std::optional and redefines * and -> operators to throw if no value is contained. 6 | template 7 | struct Option : std::optional { 8 | Option() = default; 9 | Option(std::nullopt_t value) : std::optional(value) {} 10 | Option(std::optional value) : std::optional(value) {} 11 | Option(T value) : std::optional(value) {} 12 | 13 | operator T() const { return this->value(); } 14 | 15 | T& operator*() & { return this->value(); } 16 | const T& operator*() const& { return this->value(); } 17 | T&& operator*() && { return this->value(); } 18 | const T&& operator*() const&& { return this->value(); } 19 | T* operator->() { return &this->value(); } 20 | const T* operator->() const { return &this->value(); } 21 | 22 | void apply_to(T& target) const { 23 | if (this->has_value()) { 24 | target = this->value(); 25 | } 26 | } 27 | 28 | void apply_to(Option& target) const { 29 | if (this->has_value()) { 30 | target = this->value(); 31 | } 32 | } 33 | }; 34 | -------------------------------------------------------------------------------- /models/cylinder_1.obj: -------------------------------------------------------------------------------- 1 | # Blender 4.0.1 2 | # www.blender.org 3 | o Cylinder 4 | v -0.500000 0.000000 -1.000000 5 | v 0.500000 -0.000000 -1.000000 6 | v -0.500000 -1.000000 0.000000 7 | v 0.500000 -1.000000 0.000000 8 | v -0.500000 0.000000 1.000000 9 | v 0.500000 -0.000000 1.000000 10 | v -0.500000 1.000000 0.000000 11 | v 0.500000 1.000000 0.000000 12 | s 0 13 | f 2 3 1 14 | f 4 5 3 15 | f 6 7 5 16 | f 8 1 7 17 | f 2 4 3 18 | f 4 6 5 19 | f 6 8 7 20 | f 8 2 1 21 | -------------------------------------------------------------------------------- /models/cylinder_2.obj: -------------------------------------------------------------------------------- 1 | # Blender 4.0.1 2 | # www.blender.org 3 | o Cylinder 4 | v -0.500000 0.000000 -1.000000 5 | v 0.500000 -0.000000 -1.000000 6 | v -0.500000 -0.707107 -0.707107 7 | v 0.500000 -0.707107 -0.707107 8 | v -0.500000 -1.000000 0.000000 9 | v 0.500000 -1.000000 0.000000 10 | v -0.500000 -0.707107 0.707107 11 | v 0.500000 -0.707107 0.707107 12 | v -0.500000 0.000000 1.000000 13 | v 0.500000 -0.000000 1.000000 14 | v -0.500000 0.707107 0.707107 15 | v 0.500000 0.707107 0.707107 16 | v -0.500000 1.000000 0.000000 17 | v 0.500000 1.000000 0.000000 18 | v -0.500000 0.707107 -0.707107 19 | v 0.500000 0.707107 -0.707107 20 | s 0 21 | f 2 3 1 22 | f 4 5 3 23 | f 6 7 5 24 | f 8 9 7 25 | f 10 11 9 26 | f 12 13 11 27 | f 14 15 13 28 | f 16 1 15 29 | f 2 4 3 30 | f 4 6 5 31 | f 6 8 7 32 | f 8 10 9 33 | f 10 12 11 34 | f 12 14 13 35 | f 14 16 15 36 | f 16 2 1 37 | -------------------------------------------------------------------------------- /models/icosphere_1.obj: -------------------------------------------------------------------------------- 1 | # Blender 4.0.1 2 | # www.blender.org 3 | o Icosphere 4 | v 0.000000 0.000000 -1.000000 5 | v -0.525720 -0.723600 -0.447215 6 | v -0.850640 0.276385 -0.447215 7 | v 0.000000 0.894425 -0.447215 8 | v 0.850640 0.276385 -0.447215 9 | v 0.525720 -0.723600 -0.447215 10 | v -0.850640 -0.276385 0.447215 11 | v -0.525720 0.723600 0.447215 12 | v 0.525720 0.723600 0.447215 13 | v 0.850640 -0.276385 0.447215 14 | v 0.000000 -0.894425 0.447215 15 | v 0.000000 0.000000 1.000000 16 | s 0 17 | f 1 2 3 18 | f 2 1 6 19 | f 1 3 4 20 | f 1 4 5 21 | f 1 5 6 22 | f 2 6 11 23 | f 3 2 7 24 | f 4 3 8 25 | f 5 4 9 26 | f 6 5 10 27 | f 2 11 7 28 | f 3 7 8 29 | f 4 8 9 30 | f 5 9 10 31 | f 6 10 11 32 | f 7 11 12 33 | f 8 7 12 34 | f 9 8 12 35 | f 10 9 12 36 | f 11 10 12 37 | -------------------------------------------------------------------------------- /models/icosphere_cap_2.obj: -------------------------------------------------------------------------------- 1 | # Blender 4.0.1 2 | # www.blender.org 3 | o Icosphere 4 | v 0.276388 -0.850649 0.447220 5 | v -0.723607 -0.525725 0.447220 6 | v -0.723607 0.525725 0.447220 7 | v 0.276388 0.850649 0.447220 8 | v 0.894426 0.000000 0.447216 9 | v 0.000000 0.000000 1.000000 10 | v 0.688189 -0.499997 0.525736 11 | v -0.262869 -0.809012 0.525738 12 | v -0.850648 0.000000 0.525736 13 | v -0.262869 0.809012 0.525738 14 | v 0.688189 0.499997 0.525736 15 | v 0.162456 -0.499995 0.850654 16 | v 0.525730 0.000000 0.850652 17 | v -0.425323 -0.309011 0.850654 18 | v -0.425323 0.309011 0.850654 19 | v 0.162456 0.499995 0.850654 20 | s 0 21 | f 1 7 12 22 | f 2 8 14 23 | f 3 9 15 24 | f 4 10 16 25 | f 5 11 13 26 | f 13 16 6 27 | f 13 11 16 28 | f 11 4 16 29 | f 16 15 6 30 | f 16 10 15 31 | f 10 3 15 32 | f 15 14 6 33 | f 15 9 14 34 | f 9 2 14 35 | f 14 12 6 36 | f 14 8 12 37 | f 8 1 12 38 | f 12 13 6 39 | f 12 7 13 40 | f 7 5 13 41 | -------------------------------------------------------------------------------- /models/uvsphere_half_8x4.obj: -------------------------------------------------------------------------------- 1 | # Blender 4.1.0 2 | # www.blender.org 3 | o Sphere 4 | v 0.500000 0.500000 0.707107 5 | v 0.707107 0.707107 0.000000 6 | v 0.707107 0.000000 0.707107 7 | v 1.000000 0.000000 0.000000 8 | v 0.500000 -0.500000 0.707107 9 | v 0.707107 -0.707107 0.000000 10 | v 0.000000 -0.707107 0.707107 11 | v 0.000000 -1.000000 0.000000 12 | v -0.500000 -0.500000 0.707107 13 | v -0.707107 -0.707107 0.000000 14 | v -0.707107 0.000000 0.707107 15 | v -1.000000 0.000000 0.000000 16 | v -0.500000 0.500000 0.707107 17 | v -0.707107 0.707107 0.000000 18 | v 0.000000 0.000000 1.000000 19 | v 0.000000 0.707107 0.707107 20 | v 0.000000 1.000000 0.000000 21 | s 0 22 | f 14 13 16 23 | f 16 15 1 24 | f 1 2 16 25 | f 1 15 3 26 | f 3 6 4 27 | f 3 15 5 28 | f 5 15 7 29 | f 7 15 9 30 | f 7 10 8 31 | f 6 5 7 32 | f 9 15 11 33 | f 10 9 11 34 | f 11 15 13 35 | f 11 14 12 36 | f 13 15 16 37 | f 3 5 6 38 | f 4 2 3 39 | f 2 1 3 40 | f 8 6 7 41 | f 7 9 10 42 | f 12 10 11 43 | f 11 13 14 44 | f 17 14 16 45 | f 2 17 16 46 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/Dense: -------------------------------------------------------------------------------- 1 | #include "Core" 2 | #include "LU" 3 | #include "Cholesky" 4 | #include "QR" 5 | #include "SVD" 6 | #include "Geometry" 7 | #include "Eigenvalues" 8 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/Eigen: -------------------------------------------------------------------------------- 1 | #include "Dense" 2 | #include "Sparse" 3 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/Householder: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // This Source Code Form is subject to the terms of the Mozilla 5 | // Public License v. 2.0. If a copy of the MPL was not distributed 6 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 7 | 8 | #ifndef EIGEN_HOUSEHOLDER_MODULE_H 9 | #define EIGEN_HOUSEHOLDER_MODULE_H 10 | 11 | #include "Core" 12 | 13 | #include "src/Core/util/DisableStupidWarnings.h" 14 | 15 | /** \defgroup Householder_Module Householder module 16 | * This module provides Householder transformations. 17 | * 18 | * \code 19 | * #include 20 | * \endcode 21 | */ 22 | 23 | // IWYU pragma: begin_exports 24 | #include "src/Householder/Householder.h" 25 | #include "src/Householder/HouseholderSequence.h" 26 | #include "src/Householder/BlockHouseholder.h" 27 | // IWYU pragma: end_exports 28 | 29 | #include "src/Core/util/ReenableStupidWarnings.h" 30 | 31 | #endif // EIGEN_HOUSEHOLDER_MODULE_H 32 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/Jacobi: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // This Source Code Form is subject to the terms of the Mozilla 5 | // Public License v. 2.0. If a copy of the MPL was not distributed 6 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 7 | 8 | #ifndef EIGEN_JACOBI_MODULE_H 9 | #define EIGEN_JACOBI_MODULE_H 10 | 11 | #include "Core" 12 | 13 | #include "src/Core/util/DisableStupidWarnings.h" 14 | 15 | /** \defgroup Jacobi_Module Jacobi module 16 | * This module provides Jacobi and Givens rotations. 17 | * 18 | * \code 19 | * #include 20 | * \endcode 21 | * 22 | * In addition to listed classes, it defines the two following MatrixBase methods to apply a Jacobi or Givens rotation: 23 | * - MatrixBase::applyOnTheLeft() 24 | * - MatrixBase::applyOnTheRight(). 25 | */ 26 | 27 | // IWYU pragma: begin_exports 28 | #include "src/Jacobi/Jacobi.h" 29 | // IWYU pragma: end_exports 30 | 31 | #include "src/Core/util/ReenableStupidWarnings.h" 32 | 33 | #endif // EIGEN_JACOBI_MODULE_H 34 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/MetisSupport: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // This Source Code Form is subject to the terms of the Mozilla 5 | // Public License v. 2.0. If a copy of the MPL was not distributed 6 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 7 | 8 | #ifndef EIGEN_METISSUPPORT_MODULE_H 9 | #define EIGEN_METISSUPPORT_MODULE_H 10 | 11 | #include "SparseCore" 12 | 13 | #include "src/Core/util/DisableStupidWarnings.h" 14 | 15 | extern "C" { 16 | #include 17 | } 18 | 19 | /** \ingroup Support_modules 20 | * \defgroup MetisSupport_Module MetisSupport module 21 | * 22 | * \code 23 | * #include 24 | * \endcode 25 | * This module defines an interface to the METIS reordering package (http://glaros.dtc.umn.edu/gkhome/views/metis). 26 | * It can be used just as any other built-in method as explained in \link OrderingMethods_Module here. \endlink 27 | */ 28 | 29 | // IWYU pragma: begin_exports 30 | #include "src/MetisSupport/MetisSupport.h" 31 | // IWYU pragma: end_exports 32 | 33 | #include "src/Core/util/ReenableStupidWarnings.h" 34 | 35 | #endif // EIGEN_METISSUPPORT_MODULE_H 36 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/QtAlignedMalloc: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // This Source Code Form is subject to the terms of the Mozilla 5 | // Public License v. 2.0. If a copy of the MPL was not distributed 6 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 7 | 8 | #ifndef EIGEN_QTMALLOC_MODULE_H 9 | #define EIGEN_QTMALLOC_MODULE_H 10 | 11 | #include "Core" 12 | 13 | #if (!EIGEN_MALLOC_ALREADY_ALIGNED) 14 | 15 | #include "src/Core/util/DisableStupidWarnings.h" 16 | 17 | void *qMalloc(std::size_t size) { return Eigen::internal::aligned_malloc(size); } 18 | 19 | void qFree(void *ptr) { Eigen::internal::aligned_free(ptr); } 20 | 21 | void *qRealloc(void *ptr, std::size_t size) { 22 | void *newPtr = Eigen::internal::aligned_malloc(size); 23 | std::memcpy(newPtr, ptr, size); 24 | Eigen::internal::aligned_free(ptr); 25 | return newPtr; 26 | } 27 | 28 | #include "src/Core/util/ReenableStupidWarnings.h" 29 | 30 | #endif 31 | 32 | #endif // EIGEN_QTMALLOC_MODULE_H 33 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/Sparse: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // This Source Code Form is subject to the terms of the Mozilla 5 | // Public License v. 2.0. If a copy of the MPL was not distributed 6 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 7 | 8 | #ifndef EIGEN_SPARSE_MODULE_H 9 | #define EIGEN_SPARSE_MODULE_H 10 | 11 | /** \defgroup Sparse_Module Sparse meta-module 12 | * 13 | * Meta-module including all related modules: 14 | * - \ref SparseCore_Module 15 | * - \ref OrderingMethods_Module 16 | * - \ref SparseCholesky_Module 17 | * - \ref SparseLU_Module 18 | * - \ref SparseQR_Module 19 | * - \ref IterativeLinearSolvers_Module 20 | * 21 | \code 22 | #include 23 | \endcode 24 | */ 25 | 26 | #include "SparseCore" 27 | #include "OrderingMethods" 28 | #include "SparseCholesky" 29 | #include "SparseLU" 30 | #include "SparseQR" 31 | #include "IterativeLinearSolvers" 32 | 33 | #endif // EIGEN_SPARSE_MODULE_H 34 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/StdDeque: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // Copyright (C) 2009 Gael Guennebaud 5 | // Copyright (C) 2009 Hauke Heibel 6 | // 7 | // This Source Code Form is subject to the terms of the Mozilla 8 | // Public License v. 2.0. If a copy of the MPL was not distributed 9 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 10 | 11 | #ifndef EIGEN_STDDEQUE_MODULE_H 12 | #define EIGEN_STDDEQUE_MODULE_H 13 | 14 | #include "Core" 15 | #include 16 | 17 | #if EIGEN_COMP_MSVC && EIGEN_OS_WIN64 && \ 18 | (EIGEN_MAX_STATIC_ALIGN_BYTES <= 16) /* MSVC auto aligns up to 16 bytes in 64 bit builds */ 19 | 20 | #define EIGEN_DEFINE_STL_DEQUE_SPECIALIZATION(...) 21 | 22 | #else 23 | 24 | // IWYU pragma: begin_exports 25 | #include "src/StlSupport/StdDeque.h" 26 | // IWYU pragma: end_exports 27 | 28 | #endif 29 | 30 | #endif // EIGEN_STDDEQUE_MODULE_H 31 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/StdList: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // Copyright (C) 2009 Hauke Heibel 5 | // 6 | // This Source Code Form is subject to the terms of the Mozilla 7 | // Public License v. 2.0. If a copy of the MPL was not distributed 8 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 9 | 10 | #ifndef EIGEN_STDLIST_MODULE_H 11 | #define EIGEN_STDLIST_MODULE_H 12 | 13 | #include "Core" 14 | #include 15 | 16 | #if EIGEN_COMP_MSVC && EIGEN_OS_WIN64 && \ 17 | (EIGEN_MAX_STATIC_ALIGN_BYTES <= 16) /* MSVC auto aligns up to 16 bytes in 64 bit builds */ 18 | 19 | #define EIGEN_DEFINE_STL_LIST_SPECIALIZATION(...) 20 | 21 | #else 22 | 23 | // IWYU pragma: begin_exports 24 | #include "src/StlSupport/StdList.h" 25 | // IWYU pragma: end_exports 26 | 27 | #endif 28 | 29 | #endif // EIGEN_STDLIST_MODULE_H 30 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/StdVector: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // Copyright (C) 2009 Gael Guennebaud 5 | // Copyright (C) 2009 Hauke Heibel 6 | // 7 | // This Source Code Form is subject to the terms of the Mozilla 8 | // Public License v. 2.0. If a copy of the MPL was not distributed 9 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 10 | 11 | #ifndef EIGEN_STDVECTOR_MODULE_H 12 | #define EIGEN_STDVECTOR_MODULE_H 13 | 14 | #include "Core" 15 | #include 16 | 17 | #if EIGEN_COMP_MSVC && EIGEN_OS_WIN64 && \ 18 | (EIGEN_MAX_STATIC_ALIGN_BYTES <= 16) /* MSVC auto aligns up to 16 bytes in 64 bit builds */ 19 | 20 | #define EIGEN_DEFINE_STL_VECTOR_SPECIALIZATION(...) 21 | 22 | #else 23 | 24 | // IWYU pragma: begin_exports 25 | #include "src/StlSupport/StdVector.h" 26 | // IWYU pragma: end_exports 27 | 28 | #endif 29 | 30 | #endif // EIGEN_STDVECTOR_MODULE_H 31 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/AccelerateSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_ACCELERATESUPPORT_MODULE_H 2 | #error "Please include Eigen/AccelerateSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/Cholesky/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_CHOLESKY_MODULE_H 2 | #error "Please include Eigen/Cholesky instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/CholmodSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_CHOLMODSUPPORT_MODULE_H 2 | #error "Please include Eigen/CholmodSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/Core/DiagonalProduct.h: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // Copyright (C) 2008 Gael Guennebaud 5 | // Copyright (C) 2007-2009 Benoit Jacob 6 | // 7 | // This Source Code Form is subject to the terms of the Mozilla 8 | // Public License v. 2.0. If a copy of the MPL was not distributed 9 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 10 | 11 | #ifndef EIGEN_DIAGONALPRODUCT_H 12 | #define EIGEN_DIAGONALPRODUCT_H 13 | 14 | // IWYU pragma: private 15 | #include "./InternalHeaderCheck.h" 16 | 17 | namespace Eigen { 18 | 19 | /** \returns the diagonal matrix product of \c *this by the diagonal matrix \a diagonal. 20 | */ 21 | template 22 | template 23 | EIGEN_DEVICE_FUNC inline const Product MatrixBase::operator*( 24 | const DiagonalBase &a_diagonal) const { 25 | return Product(derived(), a_diagonal.derived()); 26 | } 27 | 28 | } // end namespace Eigen 29 | 30 | #endif // EIGEN_DIAGONALPRODUCT_H 31 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/Core/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_CORE_MODULE_H 2 | #error "Please include Eigen/Core instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/Core/arch/HIP/hcc/math_constants.h: -------------------------------------------------------------------------------- 1 | /* 2 | * math_constants.h - 3 | * HIP equivalent of the CUDA header of the same name 4 | */ 5 | 6 | #ifndef __MATH_CONSTANTS_H__ 7 | #define __MATH_CONSTANTS_H__ 8 | 9 | /* single precision constants */ 10 | 11 | #define HIPRT_INF_F __int_as_float(0x7f800000) 12 | #define HIPRT_NAN_F __int_as_float(0x7fffffff) 13 | #define HIPRT_MIN_DENORM_F __int_as_float(0x00000001) 14 | #define HIPRT_MAX_NORMAL_F __int_as_float(0x7f7fffff) 15 | #define HIPRT_NEG_ZERO_F __int_as_float(0x80000000) 16 | #define HIPRT_ZERO_F 0.0f 17 | #define HIPRT_ONE_F 1.0f 18 | 19 | /* double precision constants */ 20 | #define HIPRT_INF __hiloint2double(0x7ff00000, 0x00000000) 21 | #define HIPRT_NAN __hiloint2double(0xfff80000, 0x00000000) 22 | 23 | #endif 24 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/Eigenvalues/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_EIGENVALUES_MODULE_H 2 | #error "Please include Eigen/Eigenvalues instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/Geometry/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_GEOMETRY_MODULE_H 2 | #error "Please include Eigen/Geometry instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/Householder/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_HOUSEHOLDER_MODULE_H 2 | #error "Please include Eigen/Householder instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/IterativeLinearSolvers/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_ITERATIVELINEARSOLVERS_MODULE_H 2 | #error "Please include Eigen/IterativeLinearSolvers instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/Jacobi/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_JACOBI_MODULE_H 2 | #error "Please include Eigen/Jacobi instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/KLUSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_KLUSUPPORT_MODULE_H 2 | #error "Please include Eigen/KLUSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/LU/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_LU_MODULE_H 2 | #error "Please include Eigen/LU instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/MetisSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_METISSUPPORT_MODULE_H 2 | #error "Please include Eigen/MetisSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/OrderingMethods/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_ORDERINGMETHODS_MODULE_H 2 | #error "Please include Eigen/OrderingMethods instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/PaStiXSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_PASTIXSUPPORT_MODULE_H 2 | #error "Please include Eigen/PaStiXSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/PardisoSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_PARDISOSUPPORT_MODULE_H 2 | #error "Please include Eigen/PardisoSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/QR/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_QR_MODULE_H 2 | #error "Please include Eigen/QR instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/SPQRSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_SPQRSUPPORT_MODULE_H 2 | #error "Please include Eigen/SPQRSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/SVD/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_SVD_MODULE_H 2 | #error "Please include Eigen/SVD instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/SparseCholesky/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_SPARSECHOLESKY_MODULE_H 2 | #error "Please include Eigen/SparseCholesky instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/SparseCore/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_SPARSECORE_MODULE_H 2 | #error "Please include Eigen/SparseCore instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/SparseLU/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_SPARSELU_MODULE_H 2 | #error "Please include Eigen/SparseLU instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/SparseQR/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_SPARSEQR_MODULE_H 2 | #error "Please include Eigen/SparseQR instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/SuperLUSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_SUPERLUSUPPORT_MODULE_H 2 | #error "Please include Eigen/SuperLUSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/ThreadPool/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_THREADPOOL_MODULE_H 2 | #error \ 3 | "Please include unsupported/Eigen/CXX11/ThreadPool instead of including headers inside the src directory directly." 4 | #endif 5 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/ThreadPool/ThreadCancel.h: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // Copyright (C) 2016 Benoit Steiner 5 | // 6 | // This Source Code Form is subject to the terms of the Mozilla 7 | // Public License v. 2.0. If a copy of the MPL was not distributed 8 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 9 | 10 | #ifndef EIGEN_CXX11_THREADPOOL_THREAD_CANCEL_H 11 | #define EIGEN_CXX11_THREADPOOL_THREAD_CANCEL_H 12 | 13 | // Try to come up with a portable way to cancel a thread 14 | #if EIGEN_OS_GNULINUX 15 | #define EIGEN_THREAD_CANCEL(t) pthread_cancel(t.native_handle()); 16 | #define EIGEN_SUPPORTS_THREAD_CANCELLATION 1 17 | #else 18 | #define EIGEN_THREAD_CANCEL(t) 19 | #endif 20 | 21 | #endif // EIGEN_CXX11_THREADPOOL_THREAD_CANCEL_H 22 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/ThreadPool/ThreadYield.h: -------------------------------------------------------------------------------- 1 | // This file is part of Eigen, a lightweight C++ template library 2 | // for linear algebra. 3 | // 4 | // Copyright (C) 2016 Benoit Steiner 5 | // 6 | // This Source Code Form is subject to the terms of the Mozilla 7 | // Public License v. 2.0. If a copy of the MPL was not distributed 8 | // with this file, You can obtain one at http://mozilla.org/MPL/2.0/. 9 | 10 | #ifndef EIGEN_CXX11_THREADPOOL_THREAD_YIELD_H 11 | #define EIGEN_CXX11_THREADPOOL_THREAD_YIELD_H 12 | 13 | // Try to come up with a portable way to yield 14 | #define EIGEN_THREAD_YIELD() std::this_thread::yield() 15 | 16 | #endif // EIGEN_CXX11_THREADPOOL_THREAD_YIELD_H 17 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/UmfPackSupport/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_UMFPACKSUPPORT_MODULE_H 2 | #error "Please include Eigen/UmfPackSupport instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/misc/InternalHeaderCheck.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_CORE_MODULE_H 2 | #error "Please include Eigen/Core instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/misc/lapacke_mangling.h: -------------------------------------------------------------------------------- 1 | #ifndef LAPACK_HEADER_INCLUDED 2 | #define LAPACK_HEADER_INCLUDED 3 | 4 | #ifndef LAPACK_GLOBAL 5 | #if defined(LAPACK_GLOBAL_PATTERN_LC) || defined(ADD_) 6 | #define LAPACK_GLOBAL(lcname, UCNAME) lcname##_ 7 | #elif defined(LAPACK_GLOBAL_PATTERN_UC) || defined(UPPER) 8 | #define LAPACK_GLOBAL(lcname, UCNAME) UCNAME 9 | #elif defined(LAPACK_GLOBAL_PATTERN_MC) || defined(NOCHANGE) 10 | #define LAPACK_GLOBAL(lcname, UCNAME) lcname 11 | #else 12 | #define LAPACK_GLOBAL(lcname, UCNAME) lcname##_ 13 | #endif 14 | #endif 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /stark/extern/Eigen/Eigen/src/plugins/InternalHeaderCheck.inc: -------------------------------------------------------------------------------- 1 | #ifndef EIGEN_CORE_MODULE_H 2 | #error "Please include Eigen/plugins instead of including headers inside the src directory directly." 3 | #endif 4 | -------------------------------------------------------------------------------- /stark/extern/Eigen/signature_of_eigen3_matrix_library: -------------------------------------------------------------------------------- 1 | This file is just there as a signature to help identify directories containing Eigen3. When writing a script looking for Eigen3, just look for this file. This is especially useful to help disambiguate with Eigen2... 2 | -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/include/TriangleMeshCollisionDetection: -------------------------------------------------------------------------------- 1 | #include "../src/ipc_toolkit_geometry_functions.h" 2 | #include "../src/BroadPhaseET.h" 3 | #include "../src/BroadPhasePTEE.h" 4 | #include "../src/BroadPhasePTEECCD.h" 5 | #include "../src/IntersectionDetection.h" 6 | #include "../src/ProximityDetection.h" -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/src/AABBs.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | #include "Meshes.h" 6 | #include "types.h" // TODO: bring AABB here 7 | 8 | namespace tmcd 9 | { 10 | namespace internals 11 | { 12 | class AABBs 13 | { 14 | public: 15 | /* Fields */ 16 | std::vector aabbs; 17 | int32_t first_point_idx = -1; 18 | int32_t first_triangle_idx = -1; 19 | int32_t first_edge_idx = -1; 20 | std::array world_bottom; 21 | std::array world_top; 22 | double runtime; 23 | 24 | /* Methods */ 25 | void compute(const Meshes& meshes, const double enlargement, const bool ccd, const bool add_points, const bool add_triangles, const bool add_edges, const int n_threads); 26 | const AABB& get_point_aabb(const int32_t i) const; 27 | const AABB& get_triangle_aabb(const int32_t i) const; 28 | const AABB& get_edge_aabb(const int32_t i) const; 29 | }; 30 | } 31 | } -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/src/BroadPhaseBase.cpp: -------------------------------------------------------------------------------- 1 | #include "BroadPhaseBase.h" 2 | 3 | #include 4 | 5 | void tmcd::internals::BroadPhaseBase::set_n_threads(const int32_t n_threads) 6 | { 7 | this->n_threads = n_threads; 8 | } 9 | int tmcd::internals::BroadPhaseBase::get_n_threads() const 10 | { 11 | return this->n_threads; 12 | } 13 | void tmcd::internals::BroadPhaseBase::set_recursion_cap(const int32_t cap) 14 | { 15 | this->octree.set_recursion_cap(cap); 16 | } 17 | void tmcd::internals::BroadPhaseBase::set_max_recursion(const int32_t max_recursion) 18 | { 19 | this->octree.set_max_recursion(max_recursion); 20 | } 21 | int32_t tmcd::internals::BroadPhaseBase::get_n_meshes() const 22 | { 23 | return this->meshes.get_n_meshes(); 24 | } 25 | void tmcd::internals::BroadPhaseBase::_init_threads() 26 | { 27 | if (this->n_threads < 0) { 28 | this->n_threads = omp_get_max_threads() / 2; 29 | } 30 | this->thread_buffers.resize(this->n_threads); 31 | } 32 | -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/src/BroadPhaseBase.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | #include "types.h" 6 | #include "Octree.h" 7 | #include "Meshes.h" 8 | #include "AABBs.h" 9 | 10 | 11 | namespace tmcd 12 | { 13 | namespace internals 14 | { 15 | /* 16 | Common functionalities for all types of BroadPhase specializations. 17 | */ 18 | class BroadPhaseBase 19 | { 20 | public: 21 | /* Methods */ 22 | BroadPhaseBase() = default; 23 | ~BroadPhaseBase() = default; 24 | 25 | void set_n_threads(const int32_t n_threads); 26 | int32_t get_n_threads() const; 27 | void set_max_recursion(const int32_t cap = 20); 28 | void set_recursion_cap(const int32_t cap = 1500); 29 | int32_t get_n_meshes() const; 30 | 31 | protected: 32 | 33 | /* Methods */ 34 | void _init_threads(); 35 | 36 | /* Fields */ 37 | internals::Meshes meshes; 38 | internals::AABBs aabbs; 39 | Octree octree; 40 | 41 | // Multithreading 42 | std::vector thread_buffers; 43 | int32_t n_threads = -1; 44 | }; 45 | } 46 | } -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/src/BroadPhasePTEE.cpp: -------------------------------------------------------------------------------- 1 | #include "BroadPhasePTEE.h" 2 | 3 | int32_t tmcd::BroadPhasePTEE::add_mesh(const double* xm, const int32_t n_vertices, const int32_t* triangles, const int32_t n_triangles, const int32_t* edges, const int32_t n_edges) 4 | { 5 | return this->meshes.add_mesh(nullptr, nullptr, xm, n_vertices, triangles, n_triangles, edges, n_edges); 6 | } 7 | 8 | const tmcd::BroadPhasePTEEResults& tmcd::BroadPhasePTEE::run(const double enlargement, const BroadPhaseStrategy strat) 9 | { 10 | return this->_run(/* is_ccd = */ false, enlargement, strat); 11 | } 12 | -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/src/BroadPhasePTEE.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | #include "BroadPhasePTEEBase.h" 6 | 7 | 8 | namespace tmcd 9 | { 10 | class BroadPhasePTEE 11 | : public internals::BroadPhasePTEEBase 12 | { 13 | public: 14 | /* Methods */ 15 | BroadPhasePTEE() = default; 16 | ~BroadPhasePTEE() = default; 17 | 18 | int32_t add_mesh(const double* xm, const int32_t n_vertices, const int32_t* triangles, const int32_t n_triangles, const int32_t* edges, const int32_t n_edges); 19 | const BroadPhasePTEEResults& run(const double enlargement, const BroadPhaseStrategy strat = BroadPhaseStrategy::OctreeSIMD); 20 | }; 21 | } 22 | -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/src/BroadPhasePTEECCD.cpp: -------------------------------------------------------------------------------- 1 | #include "BroadPhasePTEECCD.h" 2 | 3 | int32_t tmcd::BroadPhasePTEECCD::add_mesh(const double* x0, const double* x1, const int32_t n_vertices, const int32_t* triangles, const int32_t n_triangles, const int32_t* edges, const int32_t n_edges) 4 | { 5 | return this->meshes.add_mesh(x0, x1, nullptr, n_vertices, triangles, n_triangles, edges, n_edges); 6 | } 7 | 8 | const tmcd::BroadPhasePTEEResults& tmcd::BroadPhasePTEECCD::run(const BroadPhaseStrategy strat) 9 | { 10 | return this->_run(/* is_ccd = */ false, /* enlargement = */ 0.0, strat); 11 | } 12 | -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/src/BroadPhasePTEECCD.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | #include "BroadPhasePTEEBase.h" 6 | 7 | 8 | namespace tmcd 9 | { 10 | class BroadPhasePTEECCD 11 | : public internals::BroadPhasePTEEBase 12 | { 13 | public: 14 | /* Methods */ 15 | BroadPhasePTEECCD() = default; 16 | ~BroadPhasePTEECCD() = default; 17 | 18 | int32_t add_mesh(const double* x0, const double* x1, const int32_t n_vertices, const int32_t* triangles, const int32_t n_triangles, const int32_t* edges, const int32_t n_edges); 19 | const BroadPhasePTEEResults& run(const BroadPhaseStrategy strat = BroadPhaseStrategy::OctreeSIMD); 20 | }; 21 | } 22 | -------------------------------------------------------------------------------- /stark/extern/TriangleMeshCollisionDetection/src/IntersectionResults.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | #include "types.h" 5 | 6 | 7 | namespace tmcd 8 | { 9 | struct IntersectionResults 10 | { 11 | std::vector> edge_triangle; 12 | void clear() 13 | { 14 | this->edge_triangle.clear(); 15 | }; 16 | }; 17 | } -------------------------------------------------------------------------------- /stark/extern/TriangleMeshDistance/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 Jose Antonio Fernandez Fernandez 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /stark/extern/fmt/.clang-format: -------------------------------------------------------------------------------- 1 | # Run manually to reformat a file: 2 | # clang-format -i --style=file 3 | Language: Cpp 4 | BasedOnStyle: Google 5 | IndentPPDirectives: AfterHash 6 | IndentCaseLabels: false 7 | AlwaysBreakTemplateDeclarations: false 8 | DerivePointerAlignment: false 9 | -------------------------------------------------------------------------------- /stark/extern/fmt/CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | Contributing to {fmt} 2 | ===================== 3 | 4 | By submitting a pull request or a patch, you represent that you have the right 5 | to license your contribution to the {fmt} project owners and the community, 6 | agree that your contributions are licensed under the {fmt} license, and agree 7 | to future changes to the licensing. 8 | 9 | All C++ code must adhere to [Google C++ Style Guide]( 10 | https://google.github.io/styleguide/cppguide.html) with the following 11 | exceptions: 12 | 13 | * Exceptions are permitted 14 | * snake_case should be used instead of UpperCamelCase for function and type 15 | names 16 | 17 | All documentation must adhere to the [Google Developer Documentation Style 18 | Guide](https://developers.google.com/style). 19 | 20 | Thanks for contributing! 21 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | find_program(DOXYGEN doxygen 2 | PATHS "$ENV{ProgramFiles}/doxygen/bin" 3 | "$ENV{ProgramFiles\(x86\)}/doxygen/bin") 4 | if (NOT DOXYGEN) 5 | message(STATUS "Target 'doc' disabled (requires doxygen)") 6 | return () 7 | endif () 8 | 9 | # Find the Python interpreter and set the PYTHON_EXECUTABLE variable. 10 | if (CMAKE_VERSION VERSION_LESS 3.12) 11 | # This logic is deprecated in CMake after 3.12. 12 | find_package(PythonInterp QUIET REQUIRED) 13 | else () 14 | find_package(Python QUIET REQUIRED) 15 | set(PYTHON_EXECUTABLE ${Python_EXECUTABLE}) 16 | endif () 17 | 18 | add_custom_target(doc 19 | COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/build.py 20 | ${FMT_VERSION} 21 | SOURCES api.rst syntax.rst usage.rst build.py conf.py _templates/layout.html) 22 | 23 | include(GNUInstallDirs) 24 | install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/ 25 | DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/doc/fmt OPTIONAL 26 | PATTERN ".doctrees" EXCLUDE) 27 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/_static/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/_static/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /stark/extern/fmt/doc/_static/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/_static/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /stark/extern/fmt/doc/_static/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/_static/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /stark/extern/fmt/doc/basic-bootstrap/README: -------------------------------------------------------------------------------- 1 | Sphinx basic theme with Bootstrap support. Modifications are kept to 2 | a minimum to simplify integration in case of changes to Sphinx theming. 3 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/basic-bootstrap/theme.conf: -------------------------------------------------------------------------------- 1 | [theme] 2 | inherit = basic 3 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/breadcrumbs.less: -------------------------------------------------------------------------------- 1 | // 2 | // Breadcrumbs 3 | // -------------------------------------------------- 4 | 5 | 6 | .breadcrumb { 7 | padding: @breadcrumb-padding-vertical @breadcrumb-padding-horizontal; 8 | margin-bottom: @line-height-computed; 9 | list-style: none; 10 | background-color: @breadcrumb-bg; 11 | border-radius: @border-radius-base; 12 | 13 | > li { 14 | display: inline-block; 15 | 16 | + li:before { 17 | content: "@{breadcrumb-separator}\00a0"; // Unicode space added since inline-block means non-collapsing white-space 18 | padding: 0 5px; 19 | color: @breadcrumb-color; 20 | } 21 | } 22 | 23 | > .active { 24 | color: @breadcrumb-active-color; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/close.less: -------------------------------------------------------------------------------- 1 | // 2 | // Close icons 3 | // -------------------------------------------------- 4 | 5 | 6 | .close { 7 | float: right; 8 | font-size: (@font-size-base * 1.5); 9 | font-weight: @close-font-weight; 10 | line-height: 1; 11 | color: @close-color; 12 | text-shadow: @close-text-shadow; 13 | .opacity(.2); 14 | 15 | &:hover, 16 | &:focus { 17 | color: @close-color; 18 | text-decoration: none; 19 | cursor: pointer; 20 | .opacity(.5); 21 | } 22 | 23 | // Additional properties for button version 24 | // iOS requires the button element instead of an anchor tag. 25 | // If you want the anchor version, it requires `href="#"`. 26 | // See https://developer.mozilla.org/en-US/docs/Web/Events/click#Safari_Mobile 27 | button& { 28 | padding: 0; 29 | cursor: pointer; 30 | background: transparent; 31 | border: 0; 32 | -webkit-appearance: none; 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/component-animations.less: -------------------------------------------------------------------------------- 1 | // 2 | // Component animations 3 | // -------------------------------------------------- 4 | 5 | // Heads up! 6 | // 7 | // We don't use the `.opacity()` mixin here since it causes a bug with text 8 | // fields in IE7-8. Source: https://github.com/twbs/bootstrap/pull/3552. 9 | 10 | .fade { 11 | opacity: 0; 12 | .transition(opacity .15s linear); 13 | &.in { 14 | opacity: 1; 15 | } 16 | } 17 | 18 | .collapse { 19 | display: none; 20 | 21 | &.in { display: block; } 22 | tr&.in { display: table-row; } 23 | tbody&.in { display: table-row-group; } 24 | } 25 | 26 | .collapsing { 27 | position: relative; 28 | height: 0; 29 | overflow: hidden; 30 | .transition-property(~"height, visibility"); 31 | .transition-duration(.35s); 32 | .transition-timing-function(ease); 33 | } 34 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/jumbotron.less: -------------------------------------------------------------------------------- 1 | // 2 | // Jumbotron 3 | // -------------------------------------------------- 4 | 5 | 6 | .jumbotron { 7 | padding: @jumbotron-padding (@jumbotron-padding / 2); 8 | margin-bottom: @jumbotron-padding; 9 | color: @jumbotron-color; 10 | background-color: @jumbotron-bg; 11 | 12 | h1, 13 | .h1 { 14 | color: @jumbotron-heading-color; 15 | } 16 | 17 | p { 18 | margin-bottom: (@jumbotron-padding / 2); 19 | font-size: @jumbotron-font-size; 20 | font-weight: 200; 21 | } 22 | 23 | > hr { 24 | border-top-color: darken(@jumbotron-bg, 10%); 25 | } 26 | 27 | .tb-container &, 28 | .container-fluid & { 29 | border-radius: @border-radius-large; // Only round corners at higher resolutions if contained in a container 30 | } 31 | 32 | .tb-container { 33 | max-width: 100%; 34 | } 35 | 36 | @media screen and (min-width: @screen-sm-min) { 37 | padding: (@jumbotron-padding * 1.6) 0; 38 | 39 | .tb-container &, 40 | .container-fluid & { 41 | padding-left: (@jumbotron-padding * 2); 42 | padding-right: (@jumbotron-padding * 2); 43 | } 44 | 45 | h1, 46 | .h1 { 47 | font-size: (@font-size-base * 4.5); 48 | } 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/media.less: -------------------------------------------------------------------------------- 1 | .media { 2 | // Proper spacing between instances of .media 3 | margin-top: 15px; 4 | 5 | &:first-child { 6 | margin-top: 0; 7 | } 8 | } 9 | 10 | .media, 11 | .media-body { 12 | zoom: 1; 13 | overflow: hidden; 14 | } 15 | 16 | .media-body { 17 | width: 10000px; 18 | } 19 | 20 | .media-object { 21 | display: block; 22 | } 23 | 24 | .media-right, 25 | .media > .pull-right { 26 | padding-left: 10px; 27 | } 28 | 29 | .media-left, 30 | .media > .pull-left { 31 | padding-right: 10px; 32 | } 33 | 34 | .media-left, 35 | .media-right, 36 | .media-body { 37 | display: table-cell; 38 | vertical-align: top; 39 | } 40 | 41 | .media-middle { 42 | vertical-align: middle; 43 | } 44 | 45 | .media-bottom { 46 | vertical-align: bottom; 47 | } 48 | 49 | // Reset margins on headings for tighter default spacing 50 | .media-heading { 51 | margin-top: 0; 52 | margin-bottom: 5px; 53 | } 54 | 55 | // Media list variation 56 | // 57 | // Undo default ul/ol styles 58 | .media-list { 59 | padding-left: 0; 60 | list-style: none; 61 | } 62 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins.less: -------------------------------------------------------------------------------- 1 | // Mixins 2 | // -------------------------------------------------- 3 | 4 | // Utilities 5 | @import "mixins/hide-text.less"; 6 | @import "mixins/opacity.less"; 7 | @import "mixins/image.less"; 8 | @import "mixins/labels.less"; 9 | @import "mixins/reset-filter.less"; 10 | @import "mixins/resize.less"; 11 | @import "mixins/responsive-visibility.less"; 12 | @import "mixins/size.less"; 13 | @import "mixins/tab-focus.less"; 14 | @import "mixins/text-emphasis.less"; 15 | @import "mixins/text-overflow.less"; 16 | @import "mixins/vendor-prefixes.less"; 17 | 18 | // Components 19 | @import "mixins/alerts.less"; 20 | @import "mixins/buttons.less"; 21 | @import "mixins/panels.less"; 22 | @import "mixins/pagination.less"; 23 | @import "mixins/list-group.less"; 24 | @import "mixins/nav-divider.less"; 25 | @import "mixins/forms.less"; 26 | @import "mixins/progress-bar.less"; 27 | @import "mixins/table-row.less"; 28 | 29 | // Skins 30 | @import "mixins/background-variant.less"; 31 | @import "mixins/border-radius.less"; 32 | @import "mixins/gradients.less"; 33 | 34 | // Layout 35 | @import "mixins/clearfix.less"; 36 | @import "mixins/center-block.less"; 37 | @import "mixins/nav-vertical-align.less"; 38 | @import "mixins/grid-framework.less"; 39 | @import "mixins/grid.less"; 40 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/alerts.less: -------------------------------------------------------------------------------- 1 | // Alerts 2 | 3 | .alert-variant(@background; @border; @text-color) { 4 | background-color: @background; 5 | border-color: @border; 6 | color: @text-color; 7 | 8 | hr { 9 | border-top-color: darken(@border, 5%); 10 | } 11 | .alert-link { 12 | color: darken(@text-color, 10%); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/background-variant.less: -------------------------------------------------------------------------------- 1 | // Contextual backgrounds 2 | 3 | .bg-variant(@color) { 4 | background-color: @color; 5 | a&:hover { 6 | background-color: darken(@color, 10%); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/border-radius.less: -------------------------------------------------------------------------------- 1 | // Single side border-radius 2 | 3 | .border-top-radius(@radius) { 4 | border-top-right-radius: @radius; 5 | border-top-left-radius: @radius; 6 | } 7 | .border-right-radius(@radius) { 8 | border-bottom-right-radius: @radius; 9 | border-top-right-radius: @radius; 10 | } 11 | .border-bottom-radius(@radius) { 12 | border-bottom-right-radius: @radius; 13 | border-bottom-left-radius: @radius; 14 | } 15 | .border-left-radius(@radius) { 16 | border-bottom-left-radius: @radius; 17 | border-top-left-radius: @radius; 18 | } 19 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/center-block.less: -------------------------------------------------------------------------------- 1 | // Center-align a block level element 2 | 3 | .center-block() { 4 | display: block; 5 | margin-left: auto; 6 | margin-right: auto; 7 | } 8 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/clearfix.less: -------------------------------------------------------------------------------- 1 | // Clearfix 2 | // 3 | // For modern browsers 4 | // 1. The space content is one way to avoid an Opera bug when the 5 | // contenteditable attribute is included anywhere else in the document. 6 | // Otherwise it causes space to appear at the top and bottom of elements 7 | // that are clearfixed. 8 | // 2. The use of `table` rather than `block` is only necessary if using 9 | // `:before` to contain the top-margins of child elements. 10 | // 11 | // Source: http://nicolasgallagher.com/micro-clearfix-hack/ 12 | 13 | .clearfix() { 14 | &:before, 15 | &:after { 16 | content: " "; // 1 17 | display: table; // 2 18 | } 19 | &:after { 20 | clear: both; 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/hide-text.less: -------------------------------------------------------------------------------- 1 | // CSS image replacement 2 | // 3 | // Heads up! v3 launched with with only `.hide-text()`, but per our pattern for 4 | // mixins being reused as classes with the same name, this doesn't hold up. As 5 | // of v3.0.1 we have added `.text-hide()` and deprecated `.hide-text()`. 6 | // 7 | // Source: https://github.com/h5bp/html5-boilerplate/commit/aa0396eae757 8 | 9 | // Deprecated as of v3.0.1 (will be removed in v4) 10 | .hide-text() { 11 | font: ~"0/0" a; 12 | color: transparent; 13 | text-shadow: none; 14 | background-color: transparent; 15 | border: 0; 16 | } 17 | 18 | // New mixin to use as of v3.0.1 19 | .text-hide() { 20 | .hide-text(); 21 | } 22 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/image.less: -------------------------------------------------------------------------------- 1 | // Image Mixins 2 | // - Responsive image 3 | // - Retina image 4 | 5 | 6 | // Responsive image 7 | // 8 | // Keep images from scaling beyond the width of their parents. 9 | .img-responsive(@display: block) { 10 | display: @display; 11 | max-width: 100%; // Part 1: Set a maximum relative to the parent 12 | height: auto; // Part 2: Scale the height according to the width, otherwise you get stretching 13 | } 14 | 15 | 16 | // Retina image 17 | // 18 | // Short retina mixin for setting background-image and -size. Note that the 19 | // spelling of `min--moz-device-pixel-ratio` is intentional. 20 | .img-retina(@file-1x; @file-2x; @width-1x; @height-1x) { 21 | background-image: url("@{file-1x}"); 22 | 23 | @media 24 | only screen and (-webkit-min-device-pixel-ratio: 2), 25 | only screen and ( min--moz-device-pixel-ratio: 2), 26 | only screen and ( -o-min-device-pixel-ratio: 2/1), 27 | only screen and ( min-device-pixel-ratio: 2), 28 | only screen and ( min-resolution: 192dpi), 29 | only screen and ( min-resolution: 2dppx) { 30 | background-image: url("@{file-2x}"); 31 | background-size: @width-1x @height-1x; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/labels.less: -------------------------------------------------------------------------------- 1 | // Labels 2 | 3 | .label-variant(@color) { 4 | background-color: @color; 5 | 6 | &[href] { 7 | &:hover, 8 | &:focus { 9 | background-color: darken(@color, 10%); 10 | } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/list-group.less: -------------------------------------------------------------------------------- 1 | // List Groups 2 | 3 | .list-group-item-variant(@state; @background; @color) { 4 | .list-group-item-@{state} { 5 | color: @color; 6 | background-color: @background; 7 | 8 | a& { 9 | color: @color; 10 | 11 | .list-group-item-heading { 12 | color: inherit; 13 | } 14 | 15 | &:hover, 16 | &:focus { 17 | color: @color; 18 | background-color: darken(@background, 5%); 19 | } 20 | &.active, 21 | &.active:hover, 22 | &.active:focus { 23 | color: #fff; 24 | background-color: @color; 25 | border-color: @color; 26 | } 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/nav-divider.less: -------------------------------------------------------------------------------- 1 | // Horizontal dividers 2 | // 3 | // Dividers (basically an hr) within dropdowns and nav lists 4 | 5 | .nav-divider(@color: #e5e5e5) { 6 | height: 1px; 7 | margin: ((@line-height-computed / 2) - 1) 0; 8 | overflow: hidden; 9 | background-color: @color; 10 | } 11 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/nav-vertical-align.less: -------------------------------------------------------------------------------- 1 | // Navbar vertical align 2 | // 3 | // Vertically center elements in the navbar. 4 | // Example: an element has a height of 30px, so write out `.navbar-vertical-align(30px);` to calculate the appropriate top margin. 5 | 6 | .navbar-vertical-align(@element-height) { 7 | margin-top: ((@navbar-height - @element-height) / 2); 8 | margin-bottom: ((@navbar-height - @element-height) / 2); 9 | } 10 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/opacity.less: -------------------------------------------------------------------------------- 1 | // Opacity 2 | 3 | .opacity(@opacity) { 4 | opacity: @opacity; 5 | // IE8 filter 6 | @opacity-ie: (@opacity * 100); 7 | filter: ~"alpha(opacity=@{opacity-ie})"; 8 | } 9 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/pagination.less: -------------------------------------------------------------------------------- 1 | // Pagination 2 | 3 | .pagination-size(@padding-vertical; @padding-horizontal; @font-size; @border-radius) { 4 | > li { 5 | > a, 6 | > span { 7 | padding: @padding-vertical @padding-horizontal; 8 | font-size: @font-size; 9 | } 10 | &:first-child { 11 | > a, 12 | > span { 13 | .border-left-radius(@border-radius); 14 | } 15 | } 16 | &:last-child { 17 | > a, 18 | > span { 19 | .border-right-radius(@border-radius); 20 | } 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/panels.less: -------------------------------------------------------------------------------- 1 | // Panels 2 | 3 | .panel-variant(@border; @heading-text-color; @heading-bg-color; @heading-border) { 4 | border-color: @border; 5 | 6 | & > .panel-heading { 7 | color: @heading-text-color; 8 | background-color: @heading-bg-color; 9 | border-color: @heading-border; 10 | 11 | + .panel-collapse > .panel-body { 12 | border-top-color: @border; 13 | } 14 | .badge { 15 | color: @heading-bg-color; 16 | background-color: @heading-text-color; 17 | } 18 | } 19 | & > .panel-footer { 20 | + .panel-collapse > .panel-body { 21 | border-bottom-color: @border; 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/progress-bar.less: -------------------------------------------------------------------------------- 1 | // Progress bars 2 | 3 | .progress-bar-variant(@color) { 4 | background-color: @color; 5 | 6 | // Deprecated parent class requirement as of v3.2.0 7 | .progress-striped & { 8 | #gradient > .striped(); 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/reset-filter.less: -------------------------------------------------------------------------------- 1 | // Reset filters for IE 2 | // 3 | // When you need to remove a gradient background, do not forget to use this to reset 4 | // the IE filter for IE9 and below. 5 | 6 | .reset-filter() { 7 | filter: e(%("progid:DXImageTransform.Microsoft.gradient(enabled = false)")); 8 | } 9 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/resize.less: -------------------------------------------------------------------------------- 1 | // Resize anything 2 | 3 | .resizable(@direction) { 4 | resize: @direction; // Options: horizontal, vertical, both 5 | overflow: auto; // Per CSS3 UI, `resize` only applies when `overflow` isn't `visible` 6 | } 7 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/responsive-visibility.less: -------------------------------------------------------------------------------- 1 | // Responsive utilities 2 | 3 | // 4 | // More easily include all the states for responsive-utilities.less. 5 | .responsive-visibility() { 6 | display: block !important; 7 | table& { display: table; } 8 | tr& { display: table-row !important; } 9 | th&, 10 | td& { display: table-cell !important; } 11 | } 12 | 13 | .responsive-invisibility() { 14 | display: none !important; 15 | } 16 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/size.less: -------------------------------------------------------------------------------- 1 | // Sizing shortcuts 2 | 3 | .size(@width; @height) { 4 | width: @width; 5 | height: @height; 6 | } 7 | 8 | .square(@size) { 9 | .size(@size; @size); 10 | } 11 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/tab-focus.less: -------------------------------------------------------------------------------- 1 | // WebKit-style focus 2 | 3 | .tab-focus() { 4 | // Default 5 | outline: thin dotted; 6 | // WebKit 7 | outline: 5px auto -webkit-focus-ring-color; 8 | outline-offset: -2px; 9 | } 10 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/table-row.less: -------------------------------------------------------------------------------- 1 | // Tables 2 | 3 | .table-row-variant(@state; @background) { 4 | // Exact selectors below required to override `.table-striped` and prevent 5 | // inheritance to nested tables. 6 | .table > thead > tr, 7 | .table > tbody > tr, 8 | .table > tfoot > tr { 9 | > td.@{state}, 10 | > th.@{state}, 11 | &.@{state} > td, 12 | &.@{state} > th { 13 | background-color: @background; 14 | } 15 | } 16 | 17 | // Hover states for `.table-hover` 18 | // Note: this is not available for cells or rows within `thead` or `tfoot`. 19 | .table-hover > tbody > tr { 20 | > td.@{state}:hover, 21 | > th.@{state}:hover, 22 | &.@{state}:hover > td, 23 | &:hover > .@{state}, 24 | &.@{state}:hover > th { 25 | background-color: darken(@background, 5%); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/text-emphasis.less: -------------------------------------------------------------------------------- 1 | // Typography 2 | 3 | .text-emphasis-variant(@color) { 4 | color: @color; 5 | a&:hover { 6 | color: darken(@color, 10%); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/mixins/text-overflow.less: -------------------------------------------------------------------------------- 1 | // Text overflow 2 | // Requires inline-block or block for proper styling 3 | 4 | .text-overflow() { 5 | overflow: hidden; 6 | text-overflow: ellipsis; 7 | white-space: nowrap; 8 | } 9 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/pager.less: -------------------------------------------------------------------------------- 1 | // 2 | // Pager pagination 3 | // -------------------------------------------------- 4 | 5 | 6 | .pager { 7 | padding-left: 0; 8 | margin: @line-height-computed 0; 9 | list-style: none; 10 | text-align: center; 11 | &:extend(.clearfix all); 12 | li { 13 | display: inline; 14 | > a, 15 | > span { 16 | display: inline-block; 17 | padding: 5px 14px; 18 | background-color: @pager-bg; 19 | border: 1px solid @pager-border; 20 | border-radius: @pager-border-radius; 21 | } 22 | 23 | > a:hover, 24 | > a:focus { 25 | text-decoration: none; 26 | background-color: @pager-hover-bg; 27 | } 28 | } 29 | 30 | .next { 31 | > a, 32 | > span { 33 | float: right; 34 | } 35 | } 36 | 37 | .previous { 38 | > a, 39 | > span { 40 | float: left; 41 | } 42 | } 43 | 44 | .disabled { 45 | > a, 46 | > a:hover, 47 | > a:focus, 48 | > span { 49 | color: @pager-disabled-color; 50 | background-color: @pager-bg; 51 | cursor: @cursor-disabled; 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/responsive-embed.less: -------------------------------------------------------------------------------- 1 | // Embeds responsive 2 | // 3 | // Credit: Nicolas Gallagher and SUIT CSS. 4 | 5 | .embed-responsive { 6 | position: relative; 7 | display: block; 8 | height: 0; 9 | padding: 0; 10 | overflow: hidden; 11 | 12 | .embed-responsive-item, 13 | iframe, 14 | embed, 15 | object, 16 | video { 17 | position: absolute; 18 | top: 0; 19 | left: 0; 20 | bottom: 0; 21 | height: 100%; 22 | width: 100%; 23 | border: 0; 24 | } 25 | } 26 | 27 | // Modifier class for 16:9 aspect ratio 28 | .embed-responsive-16by9 { 29 | padding-bottom: 56.25%; 30 | } 31 | 32 | // Modifier class for 4:3 aspect ratio 33 | .embed-responsive-4by3 { 34 | padding-bottom: 75%; 35 | } 36 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/thumbnails.less: -------------------------------------------------------------------------------- 1 | // 2 | // Thumbnails 3 | // -------------------------------------------------- 4 | 5 | 6 | // Mixin and adjust the regular image class 7 | .thumbnail { 8 | display: block; 9 | padding: @thumbnail-padding; 10 | margin-bottom: @line-height-computed; 11 | line-height: @line-height-base; 12 | background-color: @thumbnail-bg; 13 | border: 1px solid @thumbnail-border; 14 | border-radius: @thumbnail-border-radius; 15 | .transition(border .2s ease-in-out); 16 | 17 | > img, 18 | a > img { 19 | &:extend(.img-responsive); 20 | margin-left: auto; 21 | margin-right: auto; 22 | } 23 | 24 | // Add a hover state for linked versions only 25 | a&:hover, 26 | a&:focus, 27 | a&.active { 28 | border-color: @link-color; 29 | } 30 | 31 | // Image captions 32 | .caption { 33 | padding: @thumbnail-caption-padding; 34 | color: @thumbnail-caption-color; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/utilities.less: -------------------------------------------------------------------------------- 1 | // 2 | // Utility classes 3 | // -------------------------------------------------- 4 | 5 | 6 | // Floats 7 | // ------------------------- 8 | 9 | .clearfix { 10 | .clearfix(); 11 | } 12 | .center-block { 13 | .center-block(); 14 | } 15 | .pull-right { 16 | float: right !important; 17 | } 18 | .pull-left { 19 | float: left !important; 20 | } 21 | 22 | 23 | // Toggling content 24 | // ------------------------- 25 | 26 | // Note: Deprecated .hide in favor of .hidden or .sr-only (as appropriate) in v3.0.1 27 | .hide { 28 | display: none !important; 29 | } 30 | .show { 31 | display: block !important; 32 | } 33 | .invisible { 34 | visibility: hidden; 35 | } 36 | .text-hide { 37 | .text-hide(); 38 | } 39 | 40 | 41 | // Hide from screenreaders and browsers 42 | // 43 | // Credit: HTML5 Boilerplate 44 | 45 | .hidden { 46 | display: none !important; 47 | } 48 | 49 | 50 | // For Affix plugin 51 | // ------------------------- 52 | 53 | .affix { 54 | position: fixed; 55 | } 56 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/bootstrap/wells.less: -------------------------------------------------------------------------------- 1 | // 2 | // Wells 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base class 7 | .well { 8 | min-height: 20px; 9 | padding: 19px; 10 | margin-bottom: 20px; 11 | background-color: @well-bg; 12 | border: 1px solid @well-border; 13 | border-radius: @border-radius-base; 14 | .box-shadow(inset 0 1px 1px rgba(0,0,0,.05)); 15 | blockquote { 16 | border-color: #ddd; 17 | border-color: rgba(0,0,0,.15); 18 | } 19 | } 20 | 21 | // Sizes 22 | .well-lg { 23 | padding: 24px; 24 | border-radius: @border-radius-large; 25 | } 26 | .well-sm { 27 | padding: 9px; 28 | border-radius: @border-radius-small; 29 | } 30 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/contents.rst: -------------------------------------------------------------------------------- 1 | ######## 2 | Contents 3 | ######## 4 | 5 | .. toctree:: 6 | :maxdepth: 2 7 | 8 | usage 9 | api 10 | syntax 11 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/_sources/contents.rst.txt: -------------------------------------------------------------------------------- 1 | ######## 2 | Contents 3 | ######## 4 | 5 | .. toctree:: 6 | :maxdepth: 2 7 | 8 | usage 9 | api 10 | syntax 11 | -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/_static/documentation_options.js: -------------------------------------------------------------------------------- 1 | var DOCUMENTATION_OPTIONS = { 2 | URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'), 3 | VERSION: '10.0.0', 4 | LANGUAGE: 'None', 5 | COLLAPSE_INDEX: false, 6 | BUILDER: 'html', 7 | FILE_SUFFIX: '.html', 8 | LINK_SUFFIX: '.html', 9 | HAS_SOURCE: true, 10 | SOURCELINK_SUFFIX: '.txt', 11 | NAVIGATION_WITH_KEYS: false 12 | }; -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/_static/file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/html/_static/file.png -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/_static/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/html/_static/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/_static/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/html/_static/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/_static/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/html/_static/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/_static/minus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/html/_static/minus.png -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/_static/plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/html/_static/plus.png -------------------------------------------------------------------------------- /stark/extern/fmt/doc/html/objects.inv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/InteractiveComputerGraphics/stark_micropolar/ebbd3f8e5acbc5f24305de9442468927d7e3ac07/stark/extern/fmt/doc/html/objects.inv -------------------------------------------------------------------------------- /stark/extern/fmt/support/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH := $(call my-dir) 2 | include $(CLEAR_VARS) 3 | 4 | LOCAL_MODULE := fmt_static 5 | LOCAL_MODULE_FILENAME := libfmt 6 | 7 | LOCAL_SRC_FILES := ../src/format.cc 8 | 9 | LOCAL_C_INCLUDES := $(LOCAL_PATH) 10 | LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH) 11 | 12 | LOCAL_CFLAGS += -std=c++11 -fexceptions 13 | 14 | include $(BUILD_STATIC_LIBRARY) 15 | 16 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/README: -------------------------------------------------------------------------------- 1 | This directory contains build support files such as 2 | 3 | * CMake modules 4 | * Build scripts 5 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/Vagrantfile: -------------------------------------------------------------------------------- 1 | # -*- mode: ruby -*- 2 | # vi: set ft=ruby : 3 | 4 | # A vagrant config for testing against gcc-4.8. 5 | Vagrant.configure("2") do |config| 6 | config.vm.box = "ubuntu/xenial64" 7 | config.disksize.size = '15GB' 8 | 9 | config.vm.provider "virtualbox" do |vb| 10 | vb.memory = "4096" 11 | end 12 | 13 | config.vm.provision "shell", inline: <<-SHELL 14 | apt-get update 15 | apt-get install -y g++ make wget git 16 | wget -q https://github.com/Kitware/CMake/releases/download/v3.26.0/cmake-3.26.0-Linux-x86_64.tar.gz 17 | tar xzf cmake-3.26.0-Linux-x86_64.tar.gz 18 | ln -s `pwd`/cmake-3.26.0-Linux-x86_64/bin/cmake /usr/local/bin 19 | SHELL 20 | end 21 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/bazel/.bazelversion: -------------------------------------------------------------------------------- 1 | 6.1.2 2 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/bazel/BUILD.bazel: -------------------------------------------------------------------------------- 1 | cc_library( 2 | name = "fmt", 3 | srcs = [ 4 | #"src/fmt.cc", # No C++ module support 5 | "src/format.cc", 6 | "src/os.cc", 7 | ], 8 | hdrs = [ 9 | "include/fmt/args.h", 10 | "include/fmt/chrono.h", 11 | "include/fmt/color.h", 12 | "include/fmt/compile.h", 13 | "include/fmt/core.h", 14 | "include/fmt/format.h", 15 | "include/fmt/format-inl.h", 16 | "include/fmt/os.h", 17 | "include/fmt/ostream.h", 18 | "include/fmt/printf.h", 19 | "include/fmt/ranges.h", 20 | "include/fmt/std.h", 21 | "include/fmt/xchar.h", 22 | ], 23 | includes = [ 24 | "include", 25 | ], 26 | strip_include_prefix = "include", 27 | visibility = ["//visibility:public"], 28 | ) 29 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/bazel/WORKSPACE.bazel: -------------------------------------------------------------------------------- 1 | workspace(name = "fmt") 2 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/cmake/FindSetEnv.cmake: -------------------------------------------------------------------------------- 1 | # A CMake script to find SetEnv.cmd. 2 | 3 | find_program(WINSDK_SETENV NAMES SetEnv.cmd 4 | PATHS "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows;CurrentInstallFolder]/bin") 5 | if (WINSDK_SETENV AND PRINT_PATH) 6 | execute_process(COMMAND ${CMAKE_COMMAND} -E echo "${WINSDK_SETENV}") 7 | endif () 8 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/cmake/JoinPaths.cmake: -------------------------------------------------------------------------------- 1 | # This module provides function for joining paths 2 | # known from from most languages 3 | # 4 | # Original license: 5 | # SPDX-License-Identifier: (MIT OR CC0-1.0) 6 | # Explicit permission given to distribute this module under 7 | # the terms of the project as described in /LICENSE.rst. 8 | # Copyright 2020 Jan Tojnar 9 | # https://github.com/jtojnar/cmake-snips 10 | # 11 | # Modelled after Python’s os.path.join 12 | # https://docs.python.org/3.7/library/os.path.html#os.path.join 13 | # Windows not supported 14 | function(join_paths joined_path first_path_segment) 15 | set(temp_path "${first_path_segment}") 16 | foreach(current_segment IN LISTS ARGN) 17 | if(NOT ("${current_segment}" STREQUAL "")) 18 | if(IS_ABSOLUTE "${current_segment}") 19 | set(temp_path "${current_segment}") 20 | else() 21 | set(temp_path "${temp_path}/${current_segment}") 22 | endif() 23 | endif() 24 | endforeach() 25 | set(${joined_path} "${temp_path}" PARENT_SCOPE) 26 | endfunction() 27 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/cmake/fmt-config.cmake.in: -------------------------------------------------------------------------------- 1 | @PACKAGE_INIT@ 2 | 3 | if (NOT TARGET fmt::fmt) 4 | include(${CMAKE_CURRENT_LIST_DIR}/@targets_export_name@.cmake) 5 | endif () 6 | 7 | check_required_components(fmt) 8 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/cmake/fmt.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@CMAKE_INSTALL_PREFIX@ 2 | exec_prefix=@CMAKE_INSTALL_PREFIX@ 3 | libdir=@libdir_for_pc_file@ 4 | includedir=@includedir_for_pc_file@ 5 | 6 | Name: fmt 7 | Description: A modern formatting library 8 | Version: @FMT_VERSION@ 9 | Libs: -L${libdir} -l@FMT_LIB_NAME@ 10 | Cflags: -I${includedir} 11 | 12 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/rtd/conf.py: -------------------------------------------------------------------------------- 1 | # Sphinx configuration for readthedocs. 2 | 3 | import os, sys 4 | 5 | master_doc = 'index' 6 | html_theme = 'theme' 7 | html_theme_path = ["."] 8 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/rtd/index.rst: -------------------------------------------------------------------------------- 1 | If you are not redirected automatically, follow the 2 | `link to the fmt documentation `_. 3 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/rtd/theme/layout.html: -------------------------------------------------------------------------------- 1 | {% extends "basic/layout.html" %} 2 | 3 | {% block extrahead %} 4 | 5 | 6 | 9 | Page Redirection 10 | {% endblock %} 11 | 12 | {% block document %} 13 | If you are not redirected automatically, follow the link to the fmt documentation. 14 | {% endblock %} 15 | 16 | {% block footer %} 17 | {% endblock %} 18 | -------------------------------------------------------------------------------- /stark/extern/fmt/support/rtd/theme/theme.conf: -------------------------------------------------------------------------------- 1 | [theme] 2 | inherit = basic 3 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/add-subdirectory-test/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.8...3.25) 2 | 3 | project(fmt-test CXX) 4 | 5 | add_subdirectory(../.. fmt) 6 | 7 | add_executable(library-test main.cc) 8 | target_include_directories(library-test PUBLIC SYSTEM .) 9 | target_compile_options(library-test PRIVATE ${PEDANTIC_COMPILE_FLAGS}) 10 | target_link_libraries(library-test fmt::fmt) 11 | 12 | if (TARGET fmt::fmt-header-only) 13 | add_executable(header-only-test main.cc) 14 | target_include_directories(header-only-test PUBLIC SYSTEM .) 15 | target_compile_options(header-only-test PRIVATE ${PEDANTIC_COMPILE_FLAGS}) 16 | target_link_libraries(header-only-test fmt::fmt-header-only) 17 | endif () 18 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/add-subdirectory-test/main.cc: -------------------------------------------------------------------------------- 1 | #include "fmt/core.h" 2 | 3 | int main(int argc, char** argv) { 4 | for (int i = 0; i < argc; ++i) fmt::print("{}: {}\n", i, argv[i]); 5 | } 6 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/assert-test.cc: -------------------------------------------------------------------------------- 1 | // Formatting library for C++ - FMT_ASSERT test 2 | // 3 | // It is a separate test to minimize the number of EXPECT_DEBUG_DEATH checks 4 | // which are slow on some platforms. In other tests FMT_ASSERT is made to throw 5 | // an exception which is much faster and easier to check. 6 | // 7 | // Copyright (c) 2012 - present, Victor Zverovich 8 | // All rights reserved. 9 | // 10 | // For the license information refer to format.h. 11 | 12 | #include "fmt/core.h" 13 | #include "gtest/gtest.h" 14 | 15 | TEST(assert_test, fail) { 16 | #if GTEST_HAS_DEATH_TEST 17 | EXPECT_DEBUG_DEATH(FMT_ASSERT(false, "don't panic!"), "don't panic!"); 18 | #else 19 | fmt::print("warning: death tests are not supported\n"); 20 | #endif 21 | } 22 | 23 | TEST(assert_test, dangling_else) { 24 | bool test_condition = false; 25 | bool executed_else = false; 26 | if (test_condition) 27 | FMT_ASSERT(true, ""); 28 | else 29 | executed_else = true; 30 | EXPECT_TRUE(executed_else); 31 | } 32 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/cuda-test/cpp14.cc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | // The purpose of this part is to ensure NVCC's host compiler also supports 4 | // the standard version. See 'cuda-cpp14.cu'. 5 | // 6 | // https://en.cppreference.com/w/cpp/preprocessor/replace#Predefined_macros 7 | static_assert(__cplusplus >= 201402L, "expect C++ 2014 for host compiler"); 8 | 9 | auto make_message_cpp() -> std::string { 10 | return fmt::format("host compiler \t: __cplusplus == {}", __cplusplus); 11 | } 12 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/cuda-test/cuda-cpp14.cu: -------------------------------------------------------------------------------- 1 | // Direct NVCC command line example: 2 | // 3 | // nvcc ./cuda-cpp14.cu -x cu -I"../include" -l"fmtd" -L"../build/Debug" \ 4 | // -std=c++14 -Xcompiler /std:c++14 -Xcompiler /Zc:__cplusplus 5 | 6 | // Ensure that we are using the latest C++ standard for NVCC 7 | // The version is C++14 8 | // 9 | // https://docs.nvidia.com/cuda/cuda-c-programming-guide/index.html#c-cplusplus-language-support 10 | // https://en.cppreference.com/w/cpp/preprocessor/replace#Predefined_macros 11 | static_assert(__cplusplus >= 201402L, "expect C++ 2014 for nvcc"); 12 | 13 | #include 14 | 15 | #include 16 | #include 17 | 18 | extern auto make_message_cpp() -> std::string; 19 | extern auto make_message_cuda() -> std::string; 20 | 21 | int main() { 22 | std::cout << make_message_cuda() << std::endl; 23 | std::cout << make_message_cpp() << std::endl; 24 | } 25 | 26 | auto make_message_cuda() -> std::string { 27 | return fmt::format("nvcc compiler \t: __cplusplus == {}", __cplusplus); 28 | } 29 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/detect-stdfs.cc: -------------------------------------------------------------------------------- 1 | // Formatting library for C++ - tests of formatters for standard library types 2 | // 3 | // Copyright (c) 2012 - present, Victor Zverovich 4 | // All rights reserved. 5 | // 6 | // For the license information refer to format.h. 7 | 8 | #include // _GLIBCXX_RELEASE & _LIBCPP_VERSION 9 | 10 | #if defined(_GLIBCXX_RELEASE) && _GLIBCXX_RELEASE == 8 11 | # error libfound "stdc++fs" 12 | #elif !defined(__apple_build_version__) && defined(_LIBCPP_VERSION) && \ 13 | _LIBCPP_VERSION >= 7000 && _LIBCPP_VERSION < 9000 14 | # error libfound "c++fs" 15 | #else 16 | // none if std::filesystem does not require additional libraries 17 | # error libfound "" 18 | #endif 19 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/find-package-test/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.8...3.25) 2 | 3 | project(fmt-test) 4 | 5 | find_package(FMT REQUIRED) 6 | 7 | add_executable(library-test main.cc) 8 | target_link_libraries(library-test fmt::fmt) 9 | target_compile_options(library-test PRIVATE ${PEDANTIC_COMPILE_FLAGS}) 10 | target_include_directories(library-test PUBLIC SYSTEM .) 11 | 12 | if (TARGET fmt::fmt-header-only) 13 | add_executable(header-only-test main.cc) 14 | target_link_libraries(header-only-test fmt::fmt-header-only) 15 | target_compile_options(header-only-test PRIVATE ${PEDANTIC_COMPILE_FLAGS}) 16 | target_include_directories(header-only-test PUBLIC SYSTEM .) 17 | endif () 18 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/find-package-test/main.cc: -------------------------------------------------------------------------------- 1 | #include "fmt/format.h" 2 | 3 | int main(int argc, char** argv) { 4 | for (int i = 0; i < argc; ++i) fmt::print("{}: {}\n", i, argv[i]); 5 | } 6 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/fuzzing/README.md: -------------------------------------------------------------------------------- 1 | # Running the fuzzers locally 2 | 3 | There is a [helper script](build.sh) to build the fuzzers, which has only been 4 | tested on Debian and Ubuntu linux so far. There should be no problems fuzzing on 5 | Windows (using clang>=8) or on Mac, but the script will probably not work out of 6 | the box. 7 | 8 | Something along 9 | ```sh 10 | mkdir build 11 | cd build 12 | export CXX=clang++ 13 | export CXXFLAGS="-fsanitize=fuzzer-no-link -DFUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION= -g" 14 | cmake .. -DFMT_SAFE_DURATION_CAST=On -DFMT_FUZZ=On -DFMT_FUZZ_LINKMAIN=Off -DFMT_FUZZ_LDFLAGS="-fsanitize=fuzzer" 15 | cmake --build . 16 | ``` 17 | should work to build the fuzzers for all platforms which clang supports. 18 | 19 | Execute a fuzzer with for instance 20 | ```sh 21 | cd build 22 | export UBSAN_OPTIONS=halt_on_error=1 23 | mkdir out_chrono 24 | bin/fuzzer_chrono_duration out_chrono 25 | ``` 26 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/fuzzing/chrono-timepoint.cc: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2021, Paul Dreik 2 | // For license information refer to format.h. 3 | #include 4 | 5 | #include "fuzzer-common.h" 6 | 7 | /* 8 | * a fuzzer for the chrono timepoints formatters 9 | * C is a clock (std::chrono::system_clock etc) 10 | */ 11 | template void doit(const uint8_t* data, size_t size) { 12 | using Rep = typename C::time_point::rep; 13 | constexpr auto N = sizeof(Rep); 14 | if (size < N) return; 15 | 16 | const auto x = assign_from_buf(data); 17 | typename C::duration dur{x}; 18 | typename C::time_point timepoint{dur}; 19 | data += N; 20 | size -= N; 21 | data_to_string format_str(data, size); 22 | 23 | std::string message = fmt::format(format_str.get(), timepoint); 24 | } 25 | 26 | extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) { 27 | try { 28 | doit(data, size); 29 | } catch (...) { 30 | } 31 | return 0; 32 | } 33 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/fuzzing/main.cc: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | #include "fuzzer-common.h" 6 | 7 | extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size); 8 | 9 | int main(int argc, char** argv) { 10 | for (int i = 1; i < argc; ++i) { 11 | std::ifstream in(argv[i]); 12 | assert(in); 13 | in.seekg(0, std::ios_base::end); 14 | const auto size = in.tellg(); 15 | assert(size >= 0); 16 | in.seekg(0, std::ios_base::beg); 17 | std::vector buf(static_cast(size)); 18 | in.read(buf.data(), size); 19 | assert(in.gcount() == size); 20 | LLVMFuzzerTestOneInput(as_bytes(buf.data()), buf.size()); 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/gtest/.clang-format: -------------------------------------------------------------------------------- 1 | # Disable clang-format here 2 | DisableFormat: true 3 | SortIncludes: Never 4 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/header-only-test.cc: -------------------------------------------------------------------------------- 1 | // Header-only configuration test 2 | 3 | #include "fmt/core.h" 4 | #include "fmt/ostream.h" 5 | #include "gtest/gtest.h" 6 | 7 | #ifndef FMT_HEADER_ONLY 8 | # error "Not in the header-only mode." 9 | #endif 10 | 11 | TEST(header_only_test, format) { EXPECT_EQ(fmt::format("foo"), "foo"); } 12 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/noexception-test.cc: -------------------------------------------------------------------------------- 1 | // Formatting library for C++ - Noexception tests 2 | // 3 | // Copyright (c) 2012 - present, Victor Zverovich 4 | // All rights reserved. 5 | // 6 | // For the license information refer to format.h. 7 | 8 | #include "fmt/args.h" 9 | #include "fmt/chrono.h" 10 | #include "fmt/color.h" 11 | #include "fmt/compile.h" 12 | #include "fmt/core.h" 13 | #include "fmt/format.h" 14 | #include "fmt/os.h" 15 | #include "fmt/ostream.h" 16 | #include "fmt/printf.h" 17 | #include "fmt/ranges.h" 18 | #include "fmt/xchar.h" 19 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/ranges-odr-test.cc: -------------------------------------------------------------------------------- 1 | // Formatting library for C++ - the core API 2 | // 3 | // Copyright (c) 2012 - present, Victor Zverovich 4 | // All rights reserved. 5 | // 6 | // For the license information refer to format.h. 7 | 8 | #include 9 | 10 | #include "fmt/ranges.h" 11 | #include "gtest/gtest.h" 12 | 13 | // call fmt::format from another translation unit to test ODR 14 | TEST(ranges_odr_test, format_vector) { 15 | auto v = std::vector{1, 2, 3, 5, 7, 11}; 16 | EXPECT_EQ(fmt::format("{}", v), "[1, 2, 3, 5, 7, 11]"); 17 | } 18 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/static-export-test/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.8...3.25) 2 | 3 | project(fmt-link CXX) 4 | 5 | set(BUILD_SHARED_LIBS OFF) 6 | set(CMAKE_VISIBILITY_INLINES_HIDDEN TRUE) 7 | set(CMAKE_CXX_VISIBILITY_PRESET "hidden") 8 | 9 | # Broken LTO on GCC 4 10 | if (CMAKE_COMPILER_IS_GNUCXX AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 5) 11 | set(BROKEN_LTO ON) 12 | endif () 13 | 14 | if (NOT BROKEN_LTO AND CMAKE_VERSION VERSION_GREATER "3.8") 15 | # CMake 3.9+ 16 | include(CheckIPOSupported) 17 | check_ipo_supported(RESULT HAVE_IPO) 18 | if (HAVE_IPO) 19 | set(CMAKE_INTERPROCEDURAL_OPTIMIZATION TRUE) 20 | endif () 21 | endif () 22 | 23 | add_subdirectory(../.. fmt) 24 | set_property(TARGET fmt PROPERTY POSITION_INDEPENDENT_CODE ON) 25 | 26 | add_library(library-test SHARED library.cc) 27 | target_link_libraries(library-test PRIVATE fmt::fmt) 28 | 29 | add_executable(exe-test main.cc) 30 | target_link_libraries(exe-test PRIVATE library-test) 31 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/static-export-test/library.cc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | __attribute__((visibility("default"))) std::string foo() { 4 | return fmt::format(FMT_COMPILE("foo bar {}"), 4242); 5 | } 6 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/static-export-test/main.cc: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | extern std::string foo(); 5 | 6 | int main() { std::cout << foo() << std::endl; } 7 | -------------------------------------------------------------------------------- /stark/extern/fmt/test/test-assert.h: -------------------------------------------------------------------------------- 1 | // Formatting library for C++ - test version of FMT_ASSERT 2 | // 3 | // Copyright (c) 2012 - present, Victor Zverovich 4 | // All rights reserved. 5 | // 6 | // For the license information refer to format.h. 7 | 8 | #ifndef FMT_TEST_ASSERT_H_ 9 | #define FMT_TEST_ASSERT_H_ 10 | 11 | #include 12 | 13 | void throw_assertion_failure(const char* message); 14 | #define FMT_ASSERT(condition, message) \ 15 | if (!(condition)) throw_assertion_failure(message); 16 | 17 | #include "gtest/gtest.h" 18 | 19 | class assertion_failure : public std::logic_error { 20 | public: 21 | explicit assertion_failure(const char* message) : std::logic_error(message) {} 22 | 23 | private: 24 | virtual void avoid_weak_vtable(); 25 | }; 26 | 27 | void assertion_failure::avoid_weak_vtable() {} 28 | 29 | // We use a separate function (rather than throw directly from FMT_ASSERT) to 30 | // avoid GCC's -Wterminate warning when FMT_ASSERT is used in a destructor. 31 | inline void throw_assertion_failure(const char* message) { 32 | throw assertion_failure(message); 33 | } 34 | 35 | // Expects an assertion failure. 36 | #define EXPECT_ASSERT(stmt, message) \ 37 | FMT_TEST_THROW_(stmt, assertion_failure, message, GTEST_NONFATAL_FAILURE_) 38 | 39 | #endif // FMT_TEST_ASSERT_H_ 40 | -------------------------------------------------------------------------------- /stark/extern/symx/extern/BlockedSparseMatrix/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2022 Jose Antonio Fernandez 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /stark/extern/symx/extern/BlockedSparseMatrix/include/BlockedSparseMatrix/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2022 Jose Antonio Fernandez 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /stark/extern/symx/include/symx: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "../src/SymbolicWorkSpace.h" 3 | #include "../src/Scalar.h" 4 | #include "../src/Vector.h" 5 | #include "../src/Matrix.h" 6 | 7 | #include "../src/EvalSequence.h" 8 | #include "../src/utils.h" 9 | #include "../src/diff.h" 10 | 11 | #include "../src/Compilation.h" 12 | #include "../src/Compiled.h" 13 | #include "../src/CompiledInLoop.h" 14 | 15 | #include "../src/Energy.h" 16 | #include "../src/GlobalEnergy.h" 17 | #include "../src/Assembly.h" 18 | -------------------------------------------------------------------------------- /stark/extern/symx/src/Assembly.cpp: -------------------------------------------------------------------------------- 1 | #include "Assembly.h" 2 | 3 | void symx::Assembly::reset(const std::vector& dof_set_offsets, const int n_threads, const bool reset_hess, const bool reset_grad) 4 | { 5 | this->dof_set_offsets = dof_set_offsets; 6 | this->ndofs = dof_set_offsets.back(); 7 | this->n_threads = n_threads; 8 | if (this->n_threads == -1) { 9 | this->n_threads = omp_get_max_threads(); 10 | } 11 | if (reset_hess) { 12 | this->hess.start_insertion(this->ndofs, this->ndofs); 13 | } 14 | if (reset_grad) { 15 | this->grad.reset(this->n_threads, this->ndofs); 16 | } 17 | this->E.reset(this->n_threads); 18 | this->compiled_runtime = 0.0; 19 | } 20 | -------------------------------------------------------------------------------- /stark/extern/symx/src/Assembly.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | namespace symx 9 | { 10 | class Assembly 11 | { 12 | public: 13 | constexpr static std::size_t BLOCK_SIZE = 3; 14 | 15 | /* Fields */ 16 | bsm::BlockedSparseMatrix hess; 17 | bsm::ParallelVector grad; 18 | bsm::ParallelNumber E; 19 | int n_threads = -1; 20 | int ndofs = -1; 21 | double compiled_runtime = 0.0; 22 | std::vector dof_set_offsets; 23 | 24 | /* Methods */ 25 | void reset(const std::vector& dof_set_offsets, const int n_threads = -1, const bool reset_hess = true, const bool reset_grad = true); 26 | }; 27 | 28 | struct Assembled 29 | { 30 | bsm::BlockedSparseMatrix* hess; 31 | Eigen::VectorXd* grad; 32 | double* E; 33 | double compiled_runtime = 0.0; 34 | Assembled(Assembly& assembly) 35 | : hess(&assembly.hess), grad(&assembly.grad.get_solution()), E(&assembly.E.get_solution()) 36 | { 37 | this->compiled_runtime = assembly.compiled_runtime; 38 | } 39 | }; 40 | } 41 | -------------------------------------------------------------------------------- /stark/extern/symx/src/Element.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | namespace symx 6 | { 7 | struct Index { int idx; }; 8 | 9 | struct Element 10 | { 11 | Element(const int& n_items_per_element); 12 | Index operator[](const int i) const; 13 | Index operator[](const std::string label) const; 14 | std::vector slice(const int begin, const int end) const; 15 | std::vector all() const; 16 | void set_labels(const std::vector& labels); 17 | 18 | private: 19 | int size = -1; 20 | std::vector labels; 21 | }; 22 | } -------------------------------------------------------------------------------- /stark/extern/symx/src/EvalSequence.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include "Sequence.h" 4 | 5 | namespace symx 6 | { 7 | class EvalSequence 8 | { 9 | public: 10 | /* Fields */ 11 | Sequence seq; 12 | std::unordered_map buffer; 13 | std::vector output; 14 | 15 | /* Methods */ 16 | EvalSequence(const std::vector& expr); 17 | void set(const Scalar &symbol, const double& v); 18 | void set(const Vector &vector, const double* v); 19 | void set(const Matrix&matrix, const double* v); 20 | double* run(); 21 | }; 22 | } -------------------------------------------------------------------------------- /stark/extern/symx/src/SymbolicWorkSpace.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | #include "Expressions.h" 9 | #include "Scalar.h" 10 | #include "Vector.h" 11 | #include "Matrix.h" 12 | 13 | namespace symx 14 | { 15 | class SymbolicWorkSpace 16 | { 17 | public: 18 | 19 | /* Methods */ 20 | SymbolicWorkSpace(); 21 | void set_cse_mode(CSE mode = CSE::Safe); 22 | 23 | Scalar make_scalar(const std::string label); 24 | Vector make_vector(const std::string label, const int32_t size); 25 | Matrix make_matrix(const std::string label, const std::array shape); 26 | 27 | std::vector make_scalars(const std::string label, const int32_t n); 28 | std::vector make_vectors(const std::string label, const int32_t size, const int32_t n); 29 | 30 | Scalar make_branch(const Scalar& condition, const Scalar& positive_branch, const Scalar& negative_branch); 31 | Scalar get_zero(); 32 | Scalar get_one(); 33 | Vector get_zero_vector(const int32_t size); 34 | Matrix get_zero_matrix(const std::array shape); 35 | Matrix get_identity_matrix(const int32_t size); 36 | 37 | const Expressions& get_expression_graph() const; 38 | 39 | private: 40 | /* Fields */ 41 | Expressions expressions; 42 | }; 43 | } -------------------------------------------------------------------------------- /stark/extern/symx/src/diff.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | 6 | #include "utils.h" 7 | #include "Scalar.h" 8 | #include "Vector.h" 9 | #include "Matrix.h" 10 | 11 | namespace symx 12 | { 13 | Scalar diff(const Scalar& expr, const Scalar& symbol, std::unordered_map* diff_map = nullptr); 14 | Scalar diff_impl(const Scalar& expr, const Scalar& symbol, std::unordered_map* diff_map = nullptr); 15 | Vector gradient(const Scalar& expr, const std::vector& symbols); 16 | Matrix hessian(const Scalar& expr, const std::vector& symbols, const bool symmetric = true); 17 | std::vector value_gradient(const Scalar& expr, const std::vector& symbols); 18 | std::vector value_gradient_hessian(const Scalar& expr, const std::vector& symbols, const bool symmetric = true); 19 | std::vector value_gradient_hessian_blocked(const Scalar& expr, const std::vector& symbols, const int block_size, const bool symmetric = true); 20 | } -------------------------------------------------------------------------------- /stark/extern/symx/src/utils.cpp: -------------------------------------------------------------------------------- 1 | #include "utils.h" 2 | 3 | std::vector symx::gather(std::vector vectors) 4 | { 5 | std::vector variables; 6 | for (Vector& v : vectors) { 7 | for (int i = 0; i < v.size(); i++) { 8 | variables.push_back(v[i]); 9 | } 10 | } 11 | return variables; 12 | } 13 | 14 | void symx::reorder_in_blocks(Scalar* m, const int matrix_size, const int block_size) 15 | { 16 | std::vector tmp; 17 | tmp.reserve(matrix_size * matrix_size); 18 | 19 | const int n_block_rows = matrix_size / block_size; 20 | for (int bi = 0; bi < n_block_rows; bi++) { 21 | for (int bj = 0; bj < n_block_rows; bj++) { 22 | 23 | for (int i = 0; i < block_size; i++) { 24 | for (int j = 0; j < block_size; j++) { 25 | const int row = block_size * bi + i; 26 | const int col = block_size * bj + j; 27 | const int idx = row * matrix_size + col; 28 | tmp.push_back(m[idx]); 29 | } 30 | } 31 | } 32 | } 33 | 34 | for (int i = 0; i < matrix_size * matrix_size; i++) { 35 | m[i] = tmp[i]; 36 | } 37 | } 38 | 39 | -------------------------------------------------------------------------------- /stark/extern/symx/src/utils.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "Scalar.h" 3 | #include "Vector.h" 4 | #include "Matrix.h" 5 | 6 | namespace symx 7 | { 8 | void reorder_in_blocks(Scalar* m, const int matrix_size, const int block_size); 9 | std::vector gather(std::vector vectors); 10 | } 11 | -------------------------------------------------------------------------------- /stark/extern/vtkio/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 Jose Antonio Fernandez 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /stark/extern/vtkio/include/vtkio: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "../src/VTKFile.h" 3 | -------------------------------------------------------------------------------- /stark/include/stark: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "../src/core/include_ui.h" 3 | #include "../src/models/include.h" 4 | #include "../src/utils/include.h" 5 | 6 | -------------------------------------------------------------------------------- /stark/src/core/Console.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | #include 6 | 7 | namespace stark::core 8 | { 9 | enum class ConsoleVerbosity { NoOutput = 0, Frames = 1, TimeSteps = 2, NewtonIterations = 3 }; 10 | enum class ConsoleOutputTo { ConsoleOnly, FileOnly, FileAndConsole, NoOutput }; 11 | 12 | class Console 13 | { 14 | public: 15 | 16 | private: 17 | std::mutex g_pages_mutex; 18 | std::unique_ptr ofstream_ptr = nullptr; 19 | ConsoleOutputTo output_to = ConsoleOutputTo::FileAndConsole; 20 | ConsoleVerbosity verbosity = ConsoleVerbosity::TimeSteps; 21 | std::string path = ""; 22 | std::string error_msg; 23 | 24 | public: 25 | void initialize(const std::string path, const ConsoleVerbosity verbosity, const ConsoleOutputTo output_to); 26 | 27 | void set_path(const std::string path); 28 | std::string get_frame_path() const; 29 | void set_verbosity(const ConsoleVerbosity verbosity); 30 | void set_output_target(const ConsoleOutputTo output_to); 31 | void print(const std::string& msg, const ConsoleVerbosity verbosity); 32 | void add_error_msg(const std::string& msg); 33 | void print_error_msg_and_clear(const ConsoleVerbosity verbosity); 34 | 35 | private: 36 | void _exit_if_no_path(); 37 | }; 38 | } 39 | -------------------------------------------------------------------------------- /stark/src/core/EventDrivenScript.cpp: -------------------------------------------------------------------------------- 1 | #include "EventDrivenScript.h" 2 | 3 | int stark::EventDrivenScript::add_event(std::function action, std::function run_when, std::function delete_when) 4 | { 5 | Event event_(this->event_counter, run_when, action, delete_when); 6 | this->events.push_back(event_); 7 | return this->event_counter++; 8 | } 9 | 10 | void stark::EventDrivenScript::run_a_cycle(double time) 11 | { 12 | for (auto it = this->events.begin(); it != this->events.end();) { 13 | 14 | // Should be deleted? 15 | if (it->delete_when && it->delete_when(it->info)) { 16 | it = this->events.erase(it); // Returns iterator following the last removed element. 17 | } 18 | 19 | // Check if it should be run 20 | else { 21 | 22 | // Should be run? 23 | const bool run = it->run_when(it->info); 24 | 25 | // Run 26 | if (run) { 27 | 28 | // Activate if first call 29 | if (it->info.is_first_call()) { 30 | it->info.activate(time); 31 | } 32 | 33 | // Run 34 | it->action(it->info); 35 | it->info.increment_n_calls(); 36 | } 37 | 38 | // Run or not, next. 39 | ++it; 40 | } 41 | } 42 | } 43 | 44 | void stark::EventDrivenScript::clear() 45 | { 46 | this->events.clear(); 47 | } 48 | -------------------------------------------------------------------------------- /stark/src/core/Stark.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | 6 | #include "Settings.h" 7 | #include "Callbacks.h" 8 | #include "NewtonsMethod.h" 9 | #include "Console.h" 10 | #include "Logger.h" 11 | #include "EventDrivenScript.h" 12 | 13 | namespace stark::core 14 | { 15 | class Stark 16 | { 17 | public: 18 | /* Fields */ 19 | const Settings settings; 20 | symx::GlobalEnergy global_energy; 21 | Callbacks callbacks; 22 | Console console; 23 | Logger logger; 24 | EventDrivenScript script; 25 | 26 | // Parameters 27 | double current_time = 0.0; 28 | int current_frame = 0; 29 | double dt = -1.0; 30 | Eigen::Vector3d gravity = { 0.0, 0.0, -9.81 }; 31 | 32 | /* Methods */ 33 | Stark(const Settings& settings); 34 | bool run_one_step(); 35 | bool run(double duration, std::function callback = nullptr); 36 | std::string get_frame_path(std::string name) const; 37 | void print(); 38 | 39 | private: 40 | /* Fields */ 41 | NewtonsMethod newton; 42 | bool is_init = false; 43 | double next_frame_time = -std::numeric_limits::epsilon(); 44 | double execution_time = 0.0; 45 | 46 | /* Methods */ 47 | void _initialize(); 48 | void _write_frame(); 49 | }; 50 | } 51 | -------------------------------------------------------------------------------- /stark/src/core/include_ui.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "Settings.h" 3 | 4 | namespace stark 5 | { 6 | using core::Settings; 7 | using core::ConsoleOutputTo; 8 | using core::ConsoleVerbosity; 9 | } -------------------------------------------------------------------------------- /stark/src/models/MeshOutputGroups.cpp: -------------------------------------------------------------------------------- 1 | #include "MeshOutputGroups.h" 2 | 3 | void stark::MeshOutputGroups::add_to_group(const std::string label, const int body_id) 4 | { 5 | this->groups[label].insert(body_id); 6 | } 7 | 8 | void stark::MeshOutputGroups::add_to_group(const std::string label, const std::vector& ids) 9 | { 10 | for (int id : ids) { 11 | this->add_to_group(label, ids); 12 | } 13 | } 14 | 15 | int stark::MeshOutputGroups::size() const 16 | { 17 | return (int)this->groups.size(); 18 | } 19 | -------------------------------------------------------------------------------- /stark/src/models/MeshOutputGroups.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | #include 9 | 10 | 11 | namespace stark 12 | { 13 | class MeshOutputGroups 14 | { 15 | public: 16 | /* Fields */ 17 | std::unordered_map> groups; 18 | 19 | /* Methods */ 20 | void add_to_group(const std::string label, const int id); 21 | void add_to_group(const std::string label, const std::vector& ids); 22 | int size() const; 23 | }; 24 | } 25 | -------------------------------------------------------------------------------- /stark/src/models/deformables/Deformables.cpp: -------------------------------------------------------------------------------- 1 | #include "Deformables.h" 2 | 3 | #include "../../utils/include.h" 4 | 5 | stark::Deformables::Deformables(core::Stark& stark, spPointDynamics dyn) 6 | : point_sets(dyn) 7 | { 8 | this->output = std::make_shared(stark, dyn); 9 | this->lumped_inertia = std::make_shared(stark, dyn); 10 | this->prescribed_positions = std::make_shared(stark, dyn); 11 | this->segment_strain = std::make_shared(stark, dyn); 12 | this->triangle_strain = stark.settings.models.enable_default_tri_strain ? std::make_shared(stark, dyn) : nullptr; 13 | this->discrete_shells = std::make_shared(stark, dyn); 14 | this->tet_strain = stark.settings.models.enable_default_tet_strain ? std::make_shared(stark, dyn) : nullptr; 15 | 16 | this->strain_kim_20 = std::make_shared(stark, dyn); 17 | this->strain_wen_23 = stark.settings.models.enable_model_wen23 ? std::make_shared(stark, dyn) : nullptr; 18 | this->strain_micropolar_shells = stark.settings.models.enable_model_mp_shell ? std::make_shared(stark, dyn) : nullptr; 19 | } 20 | 21 | -------------------------------------------------------------------------------- /stark/src/models/deformables/Deformables.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "DeformablesMeshOutput.h" 3 | #include "deformables_energies_include.h" 4 | 5 | namespace stark 6 | { 7 | class Deformables 8 | { 9 | public: 10 | /* Methods */ 11 | Deformables(core::Stark& stark, spPointDynamics dyn); 12 | 13 | /* Fields */ 14 | std::shared_ptr output; 15 | 16 | // Models 17 | spPointDynamics point_sets; 18 | std::shared_ptr lumped_inertia; 19 | std::shared_ptr prescribed_positions; 20 | std::shared_ptr segment_strain; 21 | std::shared_ptr triangle_strain; 22 | std::shared_ptr discrete_shells; 23 | std::shared_ptr tet_strain; 24 | 25 | std::shared_ptr strain_kim_20; 26 | std::shared_ptr strain_wen_23; 27 | std::shared_ptr strain_micropolar_shells; 28 | }; 29 | } 30 | -------------------------------------------------------------------------------- /stark/src/models/deformables/deformable_tools.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | #include 5 | #include 6 | 7 | namespace stark 8 | { 9 | symx::Matrix triangle_jacobian(const std::vector& x); 10 | symx::Matrix tet_jacobian(const std::vector& x); 11 | 12 | std::array eigenvalues_sym_2x2(const symx::Matrix& A); 13 | std::array eigenvalues_sym_3x3(const symx::Matrix& A); 14 | } -------------------------------------------------------------------------------- /stark/src/models/deformables/deformables_energies_include.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "point/EnergyLumpedInertia.h" 4 | #include "point/EnergyPrescribedPositions.h" 5 | #include "line/EnergySegmentStrain.h" 6 | #include "surface/EnergyTriangleStrain.h" 7 | #include "surface/EnergyDiscreteShells.h" 8 | #include "surface/EnergyTriangleStrainKim20.h" 9 | #include "surface/EnergyTriangleStrainWen23.h" 10 | #include "surface/EnergyMicropolarShell.h" 11 | #include "volume/EnergyTetStrain.h" 12 | -------------------------------------------------------------------------------- /stark/src/models/include.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "Simulation.h" 3 | -------------------------------------------------------------------------------- /stark/src/models/interactions/Interactions.cpp: -------------------------------------------------------------------------------- 1 | #include "Interactions.h" 2 | 3 | using namespace stark; 4 | 5 | stark::Interactions::Interactions(core::Stark& stark, spPointDynamics dyn, spRigidBodyDynamics rb) 6 | : dyn(dyn), rb(rb) 7 | { 8 | this->attachments = std::make_shared(stark, dyn, rb); 9 | this->contact = std::make_shared(stark, dyn, rb); 10 | } 11 | -------------------------------------------------------------------------------- /stark/src/models/interactions/Interactions.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "EnergyFrictionalContact.h" 3 | #include "EnergyAttachments.h" 4 | #include "../rigidbodies/RigidBodyHandler.h" 5 | #include "../deformables/PointSetHandler.h" 6 | 7 | namespace stark 8 | { 9 | class Interactions 10 | { 11 | public: 12 | /* Methods */ 13 | Interactions(core::Stark& stark, spPointDynamics dyn, spRigidBodyDynamics rb); 14 | 15 | /* Fields */ 16 | std::shared_ptr attachments; 17 | std::shared_ptr contact; 18 | 19 | private: 20 | /* Fields */ 21 | spPointDynamics dyn; 22 | spRigidBodyDynamics rb; 23 | }; 24 | } 25 | -------------------------------------------------------------------------------- /stark/src/models/presets/Presets.cpp: -------------------------------------------------------------------------------- 1 | #include "Presets.h" 2 | 3 | stark::Presets::Presets(core::Stark& stark, std::shared_ptr deformables, std::shared_ptr rigidbodies, std::shared_ptr interactions) 4 | { 5 | this->deformables = std::make_shared(stark, deformables, interactions); 6 | this->rigidbodies = std::make_shared(stark, rigidbodies, interactions); 7 | } 8 | -------------------------------------------------------------------------------- /stark/src/models/presets/Presets.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "DeformablesPresets.h" 3 | #include "RigidBodyPresets.h" 4 | 5 | namespace stark 6 | { 7 | class Presets 8 | { 9 | public: 10 | /* Methods */ 11 | Presets(core::Stark& stark, std::shared_ptr deformables, std::shared_ptr rigidbodies, std::shared_ptr interactions); 12 | 13 | /* Fields */ 14 | std::shared_ptr deformables; 15 | std::shared_ptr rigidbodies; 16 | }; 17 | } 18 | -------------------------------------------------------------------------------- /stark/src/models/rigidbodies/EnergyRigidBodyInertia.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "RigidBodyDynamics.h" 3 | 4 | namespace stark 5 | { 6 | class EnergyRigidBodyInertia 7 | { 8 | public: 9 | /* Fields */ 10 | spRigidBodyDynamics rb; 11 | symx::LabelledConnectivity<1> conn{ { "rb" } }; 12 | std::vector linear_damping; // per obj 13 | std::vector angular_damping; // per obj 14 | std::vector J_loc; // Inertia tensor local coordinates 15 | std::vector mass; 16 | std::vector> J0_glob; // Inertia tensor local coordinates 17 | std::vector> J0_inv_glob; // Inverse inertia tensor local coordinates 18 | 19 | /* Methods */ 20 | EnergyRigidBodyInertia(core::Stark& stark, spRigidBodyDynamics rb); 21 | void add(const int rb_idx, const double mass, const Eigen::Matrix3d& inertia_loc, const double linear_damping, const double angular_damping); 22 | 23 | private: 24 | // Stark callbacks 25 | void _before_time_step(core::Stark& stark); 26 | }; 27 | } 28 | -------------------------------------------------------------------------------- /stark/src/models/rigidbodies/inertia_tensors.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | namespace stark 5 | { 6 | Eigen::Matrix3d inertia_tensor_sphere(double mass, double radius); 7 | Eigen::Matrix3d inertia_tensor_cylinder(double mass, double radius, double full_height); 8 | Eigen::Matrix3d inertia_tensor_box(double mass, double side); 9 | Eigen::Matrix3d inertia_tensor_box(double mass, const Eigen::Vector3d& size); 10 | Eigen::Matrix3d inertia_tensor_torus(double mass, double outer_radius, double inner_radius); 11 | } 12 | -------------------------------------------------------------------------------- /stark/src/models/rigidbodies/rigid_body_constraint_utils.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | #include 6 | #include 7 | 8 | #include "../../core/Logger.h" 9 | 10 | 11 | namespace stark 12 | { 13 | double inf_norm(const Eigen::Vector3d& x) 14 | { 15 | return x.cwiseAbs().maxCoeff(); 16 | } 17 | template 18 | void log_parameters(std::shared_ptr logger, const std::string& constraint, const int idx, const std::string& constraint_name, const std::string& param_name, T&& value, Args&&... args) { 19 | logger.append_to_series(fmt::format("{} {:d} {} | {}", constraint, idx, constraint_name, param_name), fmt::format("{:.4e}", std::forward(value))); 20 | log_parameters(logger, constraint, idx, constraint_name, std::forward(args)...); 21 | } 22 | //template<> 23 | void log_parameters(std::shared_ptr logger, const std::string& constraint, const int idx, const std::string& constraint_name) { 24 | // Base case for variadic template 25 | } 26 | } -------------------------------------------------------------------------------- /stark/src/models/time_integration.cpp: -------------------------------------------------------------------------------- 1 | #include "time_integration.h" 2 | 3 | symx::Vector stark::time_integration(const symx::Vector& x0, const symx::Vector& v1, const symx::Scalar& dt) 4 | { 5 | return x0 + dt * v1; 6 | } 7 | 8 | Eigen::Vector3d stark::time_integration(const Eigen::Vector3d& x0, const Eigen::Vector3d& v1, const double dt) 9 | { 10 | return x0 + dt * v1; 11 | } 12 | 13 | std::vector stark::time_integration(const std::vector& x0, const std::vector& v1, const symx::Scalar& dt) 14 | { 15 | std::vector x1; 16 | for (int i = 0; i < (int)x0.size(); i++) { 17 | x1.push_back(time_integration(x0[i], v1[i], dt)); 18 | } 19 | return x1; 20 | } 21 | -------------------------------------------------------------------------------- /stark/src/models/time_integration.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | #include 6 | #include 7 | 8 | namespace stark 9 | { 10 | symx::Vector time_integration(const symx::Vector& x0, const symx::Vector& v1, const symx::Scalar& dt); 11 | Eigen::Vector3d time_integration(const Eigen::Vector3d& x0, const Eigen::Vector3d& v1, const double dt); 12 | std::vector time_integration(const std::vector& x0, const std::vector& v1, const symx::Scalar& dt); 13 | } -------------------------------------------------------------------------------- /stark/src/utils/Mesh.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | #include 6 | 7 | namespace stark 8 | { 9 | template 10 | struct Mesh 11 | { 12 | std::vector vertices; 13 | std::vector> conn; 14 | }; 15 | } -------------------------------------------------------------------------------- /stark/src/utils/blends.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | namespace stark 5 | { 6 | enum class BlendType 7 | { 8 | Instant, 9 | Linear, 10 | EaseIn, 11 | EaseOut, 12 | EaseInOut 13 | }; 14 | 15 | double blend(double min, double max, double begin_time, double end_time, double current_time, BlendType blendType); 16 | } 17 | -------------------------------------------------------------------------------- /stark/src/utils/include.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "mesh_utils.h" 3 | #include "mesh_generators.h" 4 | #include "blends.h" 5 | -------------------------------------------------------------------------------- /stark/src/utils/unordered_array_set_and_map.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | #include 6 | 7 | namespace stark 8 | { 9 | template 10 | struct ArrayHasher { 11 | std::size_t operator()(const std::array& a) const { 12 | std::size_t h = 0; 13 | for (auto e : a) { 14 | h ^= std::hash{}(e)+0x9e3779b9 + (h << 6) + (h >> 2); 15 | } 16 | return h; 17 | } 18 | }; 19 | 20 | /** 21 | unordered_array_map = std::unordered_map, VAL>> 22 | */ 23 | template 24 | using unordered_array_map = std::unordered_map, VAL, ArrayHasher>; 25 | template 26 | using unordered_array_set = std::unordered_set, ArrayHasher>; 27 | } 28 | -------------------------------------------------------------------------------- /tests/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(EIGEN3_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../stark/extern/Eigen) 2 | if( NOT EIGEN3_INCLUDE_DIR ) 3 | message( FATAL_ERROR "Please point the environment variable EIGEN3_INCLUDE_DIR to the include directory of your Eigen3 installation.") 4 | endif() 5 | set (CMAKE_CXX_FLAGS "-DEIGEN_MPL2_ONLY") 6 | 7 | # Enable SIMD and suppress compiler warnings 8 | if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU") 9 | add_compile_options("-march=native") 10 | add_compile_options("-Wno-ignored-attributes") 11 | elseif (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") 12 | add_compile_options("/arch:AVX") 13 | elseif (CMAKE_CXX_COMPILER_ID STREQUAL "Clang") 14 | add_compile_options("-march=native") 15 | endif() 16 | 17 | # Dependencies 18 | add_subdirectory(extern/Catch2) 19 | 20 | # Source files 21 | set(SOURCE_FILES 22 | rb_constraints.cpp 23 | ) 24 | 25 | # Create executable 26 | add_executable(stark_tests ${SOURCE_FILES}) 27 | 28 | # Include/link dependencies 29 | ## Stark 30 | target_link_libraries(stark_tests PRIVATE stark) 31 | target_include_directories(stark_tests PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/../stark/include) 32 | 33 | ## Eigen 34 | target_include_directories(stark_tests PUBLIC ${EIGEN3_INCLUDE_DIR}) 35 | 36 | ## CMake 37 | target_link_libraries(stark_tests PRIVATE Catch2::Catch2WithMain) 38 | -------------------------------------------------------------------------------- /tests/extern/Catch2/CMake/Catch2Config.cmake.in: -------------------------------------------------------------------------------- 1 | @PACKAGE_INIT@ 2 | 3 | 4 | # Avoid repeatedly including the targets 5 | if(NOT TARGET Catch2::Catch2) 6 | # Provide path for scripts 7 | list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}") 8 | 9 | include(${CMAKE_CURRENT_LIST_DIR}/Catch2Targets.cmake) 10 | endif() 11 | -------------------------------------------------------------------------------- /tests/extern/Catch2/CMake/catch2-with-main.pc.in: -------------------------------------------------------------------------------- 1 | includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@ 2 | libdir=@CMAKE_INSTALL_FULL_LIBDIR@ 3 | pkg_version=@Catch2_VERSION@ 4 | 5 | Name: Catch2-With-Main 6 | Description: A modern, C++-native test framework for C++14 and above (links in default main) 7 | Version: ${pkg_version} 8 | Requires: catch2 = ${pkg_version} 9 | Cflags: -I${includedir} 10 | Libs: -L${libdir} -lCatch2Main 11 | -------------------------------------------------------------------------------- /tests/extern/Catch2/CMake/catch2.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@CMAKE_INSTALL_PREFIX@ 2 | exec_prefix=${prefix} 3 | includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@ 4 | libdir=@CMAKE_INSTALL_FULL_LIBDIR@ 5 | 6 | Name: Catch2 7 | Description: A modern, C++-native, test framework for C++14 and above 8 | URL: https://github.com/catchorg/Catch2 9 | Version: @Catch2_VERSION@ 10 | Cflags: -I${includedir} 11 | Libs: -L${libdir} -lCatch2 12 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/catch_chronometer.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | namespace Benchmark { 13 | namespace Detail { 14 | ChronometerConcept::~ChronometerConcept() = default; 15 | } // namespace Detail 16 | } // namespace Benchmark 17 | } // namespace Catch 18 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/catch_clock.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_CLOCK_HPP_INCLUDED 11 | #define CATCH_CLOCK_HPP_INCLUDED 12 | 13 | #include 14 | 15 | namespace Catch { 16 | namespace Benchmark { 17 | using IDuration = std::chrono::nanoseconds; 18 | using FDuration = std::chrono::duration; 19 | 20 | template 21 | using TimePoint = typename Clock::time_point; 22 | 23 | using default_clock = std::chrono::steady_clock; 24 | } // namespace Benchmark 25 | } // namespace Catch 26 | 27 | #endif // CATCH_CLOCK_HPP_INCLUDED 28 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/catch_environment.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_ENVIRONMENT_HPP_INCLUDED 11 | #define CATCH_ENVIRONMENT_HPP_INCLUDED 12 | 13 | #include 14 | #include 15 | 16 | namespace Catch { 17 | namespace Benchmark { 18 | struct EnvironmentEstimate { 19 | FDuration mean; 20 | OutlierClassification outliers; 21 | }; 22 | struct Environment { 23 | EnvironmentEstimate clock_resolution; 24 | EnvironmentEstimate clock_cost; 25 | }; 26 | } // namespace Benchmark 27 | } // namespace Catch 28 | 29 | #endif // CATCH_ENVIRONMENT_HPP_INCLUDED 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/catch_estimate.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_ESTIMATE_HPP_INCLUDED 11 | #define CATCH_ESTIMATE_HPP_INCLUDED 12 | 13 | namespace Catch { 14 | namespace Benchmark { 15 | template 16 | struct Estimate { 17 | Type point; 18 | Type lower_bound; 19 | Type upper_bound; 20 | double confidence_interval; 21 | }; 22 | } // namespace Benchmark 23 | } // namespace Catch 24 | 25 | #endif // CATCH_ESTIMATE_HPP_INCLUDED 26 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/catch_outlier_classification.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_OUTLIER_CLASSIFICATION_HPP_INCLUDED 11 | #define CATCH_OUTLIER_CLASSIFICATION_HPP_INCLUDED 12 | 13 | namespace Catch { 14 | namespace Benchmark { 15 | struct OutlierClassification { 16 | int samples_seen = 0; 17 | int low_severe = 0; // more than 3 times IQR below Q1 18 | int low_mild = 0; // 1.5 to 3 times IQR below Q1 19 | int high_mild = 0; // 1.5 to 3 times IQR above Q3 20 | int high_severe = 0; // more than 3 times IQR above Q3 21 | 22 | int total() const { 23 | return low_severe + low_mild + high_mild + high_severe; 24 | } 25 | }; 26 | } // namespace Benchmark 27 | } // namespace Catch 28 | 29 | #endif // CATCH_OUTLIERS_CLASSIFICATION_HPP_INCLUDED 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/catch_sample_analysis.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_SAMPLE_ANALYSIS_HPP_INCLUDED 11 | #define CATCH_SAMPLE_ANALYSIS_HPP_INCLUDED 12 | 13 | #include 14 | #include 15 | #include 16 | 17 | #include 18 | 19 | namespace Catch { 20 | namespace Benchmark { 21 | struct SampleAnalysis { 22 | std::vector samples; 23 | Estimate mean; 24 | Estimate standard_deviation; 25 | OutlierClassification outliers; 26 | double outlier_variance; 27 | }; 28 | } // namespace Benchmark 29 | } // namespace Catch 30 | 31 | #endif // CATCH_SAMPLE_ANALYSIS_HPP_INCLUDED 32 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/detail/catch_analyse.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_ANALYSE_HPP_INCLUDED 11 | #define CATCH_ANALYSE_HPP_INCLUDED 12 | 13 | #include 14 | #include 15 | 16 | 17 | namespace Catch { 18 | class IConfig; 19 | 20 | namespace Benchmark { 21 | namespace Detail { 22 | SampleAnalysis analyse(const IConfig &cfg, FDuration* first, FDuration* last); 23 | } // namespace Detail 24 | } // namespace Benchmark 25 | } // namespace Catch 26 | 27 | #endif // CATCH_ANALYSE_HPP_INCLUDED 28 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/detail/catch_benchmark_function.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | namespace Benchmark { 13 | namespace Detail { 14 | BenchmarkFunction::callable::~callable() = default; 15 | } // namespace Detail 16 | } // namespace Benchmark 17 | } // namespace Catch 18 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/detail/catch_benchmark_stats_fwd.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_BENCHMARK_STATS_FWD_HPP_INCLUDED 9 | #define CATCH_BENCHMARK_STATS_FWD_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | // We cannot forward declare the type with default template argument 16 | // multiple times, so it is split out into a separate header so that 17 | // we can prevent multiple declarations in dependees 18 | template 19 | struct BenchmarkStats; 20 | 21 | } // end namespace Catch 22 | 23 | #endif // CATCH_BENCHMARK_STATS_FWD_HPP_INCLUDED 24 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/detail/catch_measure.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_MEASURE_HPP_INCLUDED 11 | #define CATCH_MEASURE_HPP_INCLUDED 12 | 13 | #include 14 | #include 15 | #include 16 | 17 | namespace Catch { 18 | namespace Benchmark { 19 | namespace Detail { 20 | template 21 | TimingOf measure(Fun&& fun, Args&&... args) { 22 | auto start = Clock::now(); 23 | auto&& r = Detail::complete_invoke(fun, CATCH_FORWARD(args)...); 24 | auto end = Clock::now(); 25 | auto delta = end - start; 26 | return { delta, CATCH_FORWARD(r), 1 }; 27 | } 28 | } // namespace Detail 29 | } // namespace Benchmark 30 | } // namespace Catch 31 | 32 | #endif // CATCH_MEASURE_HPP_INCLUDED 33 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/detail/catch_repeat.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_REPEAT_HPP_INCLUDED 11 | #define CATCH_REPEAT_HPP_INCLUDED 12 | 13 | #include 14 | #include 15 | 16 | namespace Catch { 17 | namespace Benchmark { 18 | namespace Detail { 19 | template 20 | struct repeater { 21 | void operator()(int k) const { 22 | for (int i = 0; i < k; ++i) { 23 | fun(); 24 | } 25 | } 26 | Fun fun; 27 | }; 28 | template 29 | repeater> repeat(Fun&& fun) { 30 | return { CATCH_FORWARD(fun) }; 31 | } 32 | } // namespace Detail 33 | } // namespace Benchmark 34 | } // namespace Catch 35 | 36 | #endif // CATCH_REPEAT_HPP_INCLUDED 37 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/detail/catch_run_for_at_least.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | 12 | #include 13 | 14 | namespace Catch { 15 | namespace Benchmark { 16 | namespace Detail { 17 | struct optimized_away_error : std::exception { 18 | const char* what() const noexcept override; 19 | }; 20 | 21 | const char* optimized_away_error::what() const noexcept { 22 | return "could not measure benchmark, maybe it was optimized away"; 23 | } 24 | 25 | void throw_optimized_away_error() { 26 | Catch::throw_exception(optimized_away_error{}); 27 | } 28 | 29 | } // namespace Detail 30 | } // namespace Benchmark 31 | } // namespace Catch 32 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/benchmark/detail/catch_timing.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | // Adapted from donated nonius code. 9 | 10 | #ifndef CATCH_TIMING_HPP_INCLUDED 11 | #define CATCH_TIMING_HPP_INCLUDED 12 | 13 | #include 14 | #include 15 | 16 | #include 17 | 18 | namespace Catch { 19 | namespace Benchmark { 20 | template 21 | struct Timing { 22 | IDuration elapsed; 23 | Result result; 24 | int iterations; 25 | }; 26 | template 27 | using TimingOf = Timing>>; 28 | } // namespace Benchmark 29 | } // namespace Catch 30 | 31 | #endif // CATCH_TIMING_HPP_INCLUDED 32 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_assertion_info.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_ASSERTION_INFO_HPP_INCLUDED 9 | #define CATCH_ASSERTION_INFO_HPP_INCLUDED 10 | 11 | #include 12 | #include 13 | #include 14 | 15 | namespace Catch { 16 | 17 | struct AssertionInfo { 18 | // AssertionInfo() = delete; 19 | 20 | StringRef macroName; 21 | SourceLineInfo lineInfo; 22 | StringRef capturedExpression; 23 | ResultDisposition::Flags resultDisposition; 24 | }; 25 | 26 | } // end namespace Catch 27 | 28 | #endif // CATCH_ASSERTION_INFO_HPP_INCLUDED 29 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_get_random_seed.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | #include 12 | #include 13 | 14 | namespace Catch { 15 | std::uint32_t getSeed() { 16 | return getCurrentContext().getConfig()->rngSeed(); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_get_random_seed.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_GET_RANDOM_SEED_HPP_INCLUDED 9 | #define CATCH_GET_RANDOM_SEED_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | //! Returns Catch2's current RNG seed. 15 | std::uint32_t getSeed(); 16 | } 17 | 18 | #endif // CATCH_GET_RANDOM_SEED_HPP_INCLUDED 19 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_tag_alias.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TAG_ALIAS_HPP_INCLUDED 9 | #define CATCH_TAG_ALIAS_HPP_INCLUDED 10 | 11 | #include 12 | 13 | #include 14 | 15 | namespace Catch { 16 | 17 | struct TagAlias { 18 | TagAlias(std::string const& _tag, SourceLineInfo _lineInfo): 19 | tag(_tag), 20 | lineInfo(_lineInfo) 21 | {} 22 | 23 | std::string tag; 24 | SourceLineInfo lineInfo; 25 | }; 26 | 27 | } // end namespace Catch 28 | 29 | #endif // CATCH_TAG_ALIAS_HPP_INCLUDED 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_tag_alias_autoregistrar.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | namespace Catch { 14 | 15 | RegistrarForTagAliases::RegistrarForTagAliases(char const* alias, char const* tag, SourceLineInfo const& lineInfo) { 16 | CATCH_TRY { 17 | getMutableRegistryHub().registerTagAlias(alias, tag, lineInfo); 18 | } CATCH_CATCH_ALL { 19 | // Do not throw when constructing global objects, instead register the exception to be processed later 20 | getMutableRegistryHub().registerStartupException(); 21 | } 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_tag_alias_autoregistrar.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TAG_ALIAS_AUTOREGISTRAR_HPP_INCLUDED 9 | #define CATCH_TAG_ALIAS_AUTOREGISTRAR_HPP_INCLUDED 10 | 11 | #include 12 | #include 13 | #include 14 | 15 | namespace Catch { 16 | 17 | struct RegistrarForTagAliases { 18 | RegistrarForTagAliases( char const* alias, char const* tag, SourceLineInfo const& lineInfo ); 19 | }; 20 | 21 | } // end namespace Catch 22 | 23 | #define CATCH_REGISTER_TAG_ALIAS( alias, spec ) \ 24 | CATCH_INTERNAL_START_WARNINGS_SUPPRESSION \ 25 | CATCH_INTERNAL_SUPPRESS_GLOBALS_WARNINGS \ 26 | namespace{ Catch::RegistrarForTagAliases INTERNAL_CATCH_UNIQUE_NAME( AutoRegisterTagAlias )( alias, spec, CATCH_INTERNAL_LINEINFO ); } \ 27 | CATCH_INTERNAL_STOP_WARNINGS_SUPPRESSION 28 | 29 | #endif // CATCH_TAG_ALIAS_AUTOREGISTRAR_HPP_INCLUDED 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_timer.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TIMER_HPP_INCLUDED 9 | #define CATCH_TIMER_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | class Timer { 16 | uint64_t m_nanoseconds = 0; 17 | public: 18 | void start(); 19 | auto getElapsedNanoseconds() const -> uint64_t; 20 | auto getElapsedMicroseconds() const -> uint64_t; 21 | auto getElapsedMilliseconds() const -> unsigned int; 22 | auto getElapsedSeconds() const -> double; 23 | }; 24 | 25 | } // namespace Catch 26 | 27 | #endif // CATCH_TIMER_HPP_INCLUDED 28 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_totals.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TOTALS_HPP_INCLUDED 9 | #define CATCH_TOTALS_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | struct Counts { 16 | Counts operator - ( Counts const& other ) const; 17 | Counts& operator += ( Counts const& other ); 18 | 19 | std::uint64_t total() const; 20 | bool allPassed() const; 21 | bool allOk() const; 22 | 23 | std::uint64_t passed = 0; 24 | std::uint64_t failed = 0; 25 | std::uint64_t failedButOk = 0; 26 | std::uint64_t skipped = 0; 27 | }; 28 | 29 | struct Totals { 30 | 31 | Totals operator - ( Totals const& other ) const; 32 | Totals& operator += ( Totals const& other ); 33 | 34 | Totals delta( Totals const& prevTotals ) const; 35 | 36 | Counts assertions; 37 | Counts testCases; 38 | }; 39 | } 40 | 41 | #endif // CATCH_TOTALS_HPP_INCLUDED 42 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_translate_exception.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | 12 | namespace Catch { 13 | namespace Detail { 14 | void registerTranslatorImpl( 15 | Detail::unique_ptr&& translator ) { 16 | getMutableRegistryHub().registerTranslator( 17 | CATCH_MOVE( translator ) ); 18 | } 19 | } // namespace Detail 20 | } // namespace Catch 21 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/catch_version_macros.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_VERSION_MACROS_HPP_INCLUDED 9 | #define CATCH_VERSION_MACROS_HPP_INCLUDED 10 | 11 | #define CATCH_VERSION_MAJOR 3 12 | #define CATCH_VERSION_MINOR 4 13 | #define CATCH_VERSION_PATCH 0 14 | 15 | #endif // CATCH_VERSION_MACROS_HPP_INCLUDED 16 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/generators/catch_generator_exception.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | 13 | const char* GeneratorException::what() const noexcept { 14 | return m_msg; 15 | } 16 | 17 | } // end namespace Catch 18 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/generators/catch_generator_exception.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_GENERATOR_EXCEPTION_HPP_INCLUDED 9 | #define CATCH_GENERATOR_EXCEPTION_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | // Exception type to be thrown when a Generator runs into an error, 16 | // e.g. it cannot initialize the first return value based on 17 | // runtime information 18 | class GeneratorException : public std::exception { 19 | const char* const m_msg = ""; 20 | 21 | public: 22 | GeneratorException(const char* msg): 23 | m_msg(msg) 24 | {} 25 | 26 | const char* what() const noexcept override final; 27 | }; 28 | 29 | } // end namespace Catch 30 | 31 | #endif // CATCH_GENERATOR_EXCEPTION_HPP_INCLUDED 32 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/generators/catch_generators_random.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | #include 12 | 13 | std::uint32_t Catch::Generators::Detail::getSeed() { return sharedRng()(); } 14 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_capture.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | IResultCapture::~IResultCapture() = default; 13 | } 14 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_config.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | IConfig::~IConfig() = default; 13 | } 14 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_exception.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | IExceptionTranslator::~IExceptionTranslator() = default; 13 | IExceptionTranslatorRegistry::~IExceptionTranslatorRegistry() = default; 14 | } 15 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_generatortracker.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | 12 | namespace Catch { 13 | namespace Generators { 14 | 15 | bool GeneratorUntypedBase::countedNext() { 16 | auto ret = next(); 17 | if ( ret ) { 18 | m_stringReprCache.clear(); 19 | ++m_currentElementIndex; 20 | } 21 | return ret; 22 | } 23 | 24 | StringRef GeneratorUntypedBase::currentElementAsString() const { 25 | if ( m_stringReprCache.empty() ) { 26 | m_stringReprCache = stringifyImpl(); 27 | } 28 | return m_stringReprCache; 29 | } 30 | 31 | } // namespace Generators 32 | } // namespace Catch 33 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_registry_hub.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | IRegistryHub::~IRegistryHub() = default; 13 | IMutableRegistryHub::~IMutableRegistryHub() = default; 14 | } 15 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_reporter_factory.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | IReporterFactory::~IReporterFactory() = default; 13 | EventListenerFactory::~EventListenerFactory() = default; 14 | } 15 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_tag_alias_registry.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_INTERFACES_TAG_ALIAS_REGISTRY_HPP_INCLUDED 9 | #define CATCH_INTERFACES_TAG_ALIAS_REGISTRY_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | struct TagAlias; 16 | 17 | class ITagAliasRegistry { 18 | public: 19 | virtual ~ITagAliasRegistry(); // = default 20 | // Nullptr if not present 21 | virtual TagAlias const* find( std::string const& alias ) const = 0; 22 | virtual std::string expandAliases( std::string const& unexpandedTestSpec ) const = 0; 23 | 24 | static ITagAliasRegistry const& get(); 25 | }; 26 | 27 | } // end namespace Catch 28 | 29 | #endif // CATCH_INTERFACES_TAG_ALIAS_REGISTRY_HPP_INCLUDED 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_test_invoker.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_INTERFACES_TEST_INVOKER_HPP_INCLUDED 9 | #define CATCH_INTERFACES_TEST_INVOKER_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | 13 | class ITestInvoker { 14 | public: 15 | virtual void invoke() const = 0; 16 | virtual ~ITestInvoker(); // = default 17 | }; 18 | 19 | } // namespace Catch 20 | 21 | #endif // CATCH_INTERFACES_TEST_INVOKER_HPP_INCLUDED 22 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_testcase.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | ITestCaseRegistry::~ITestCaseRegistry() = default; 13 | } 14 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/interfaces/catch_interfaces_testcase.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_INTERFACES_TESTCASE_HPP_INCLUDED 9 | #define CATCH_INTERFACES_TESTCASE_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | struct TestCaseInfo; 16 | class TestCaseHandle; 17 | class IConfig; 18 | 19 | class ITestCaseRegistry { 20 | public: 21 | virtual ~ITestCaseRegistry(); // = default 22 | // TODO: this exists only for adding filenames to test cases -- let's expose this in a saner way later 23 | virtual std::vector const& getAllInfos() const = 0; 24 | virtual std::vector const& getAllTests() const = 0; 25 | virtual std::vector const& getAllTestsSorted( IConfig const& config ) const = 0; 26 | }; 27 | 28 | } 29 | 30 | #endif // CATCH_INTERFACES_TESTCASE_HPP_INCLUDED 31 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_case_insensitive_comparisons.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_CASE_INSENSITIVE_COMPARISONS_HPP_INCLUDED 9 | #define CATCH_CASE_INSENSITIVE_COMPARISONS_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | namespace Detail { 15 | //! Provides case-insensitive `op<` semantics when called 16 | struct CaseInsensitiveLess { 17 | bool operator()( StringRef lhs, 18 | StringRef rhs ) const; 19 | }; 20 | 21 | //! Provides case-insensitive `op==` semantics when called 22 | struct CaseInsensitiveEqualTo { 23 | bool operator()( StringRef lhs, 24 | StringRef rhs ) const; 25 | }; 26 | 27 | } // namespace Detail 28 | } // namespace Catch 29 | 30 | #endif // CATCH_CASE_INSENSITIVE_COMPARISONS_HPP_INCLUDED 31 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_case_sensitive.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_CASE_SENSITIVE_HPP_INCLUDED 9 | #define CATCH_CASE_SENSITIVE_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | 13 | enum class CaseSensitive { Yes, No }; 14 | 15 | } // namespace Catch 16 | 17 | #endif // CATCH_CASE_SENSITIVE_HPP_INCLUDED 18 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_commandline.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_COMMANDLINE_HPP_INCLUDED 9 | #define CATCH_COMMANDLINE_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | struct ConfigData; 16 | 17 | Clara::Parser makeCommandLineParser( ConfigData& config ); 18 | 19 | } // end namespace Catch 20 | 21 | #endif // CATCH_COMMANDLINE_HPP_INCLUDED 22 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_config_android_logwrite.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | /** \file 10 | * Wrapper for ANDROID_LOGWRITE configuration option 11 | * 12 | * We want to default to enabling it when compiled for android, but 13 | * users of the library should also be able to disable it if they want 14 | * to. 15 | */ 16 | 17 | #ifndef CATCH_CONFIG_ANDROID_LOGWRITE_HPP_INCLUDED 18 | #define CATCH_CONFIG_ANDROID_LOGWRITE_HPP_INCLUDED 19 | 20 | #include 21 | 22 | #if defined(__ANDROID__) 23 | # define CATCH_INTERNAL_CONFIG_ANDROID_LOGWRITE 24 | #endif 25 | 26 | 27 | #if defined( CATCH_INTERNAL_CONFIG_ANDROID_LOGWRITE ) && \ 28 | !defined( CATCH_CONFIG_NO_ANDROID_LOGWRITE ) && \ 29 | !defined( CATCH_CONFIG_ANDROID_LOGWRITE ) 30 | # define CATCH_CONFIG_ANDROID_LOGWRITE 31 | #endif 32 | 33 | #endif // CATCH_CONFIG_ANDROID_LOGWRITE_HPP_INCLUDED 34 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_config_counter.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | /** \file 10 | * Wrapper for the CONFIG configuration option 11 | * 12 | * When generating internal unique names, there are two options. Either 13 | * we mix in the current line number, or mix in an incrementing number. 14 | * We prefer the latter, using `__COUNTER__`, but users might want to 15 | * use the former. 16 | */ 17 | 18 | #ifndef CATCH_CONFIG_COUNTER_HPP_INCLUDED 19 | #define CATCH_CONFIG_COUNTER_HPP_INCLUDED 20 | 21 | #include 22 | 23 | #if ( !defined(__JETBRAINS_IDE__) || __JETBRAINS_IDE__ >= 20170300L ) 24 | #define CATCH_INTERNAL_CONFIG_COUNTER 25 | #endif 26 | 27 | #if defined( CATCH_INTERNAL_CONFIG_COUNTER ) && \ 28 | !defined( CATCH_CONFIG_NO_COUNTER ) && \ 29 | !defined( CATCH_CONFIG_COUNTER ) 30 | # define CATCH_CONFIG_COUNTER 31 | #endif 32 | 33 | 34 | #endif // CATCH_CONFIG_COUNTER_HPP_INCLUDED 35 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_config_prefix_messages.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | /** \file 10 | * Wrapper for the CATCH_CONFIG_PREFIX_MESSAGES configuration option 11 | * 12 | * CATCH_CONFIG_PREFIX_ALL can be used to avoid clashes with other macros 13 | * by prepending CATCH_. This may not be desirable if the only clashes are with 14 | * logger macros such as INFO and WARN. In this cases 15 | * CATCH_CONFIG_PREFIX_MESSAGES can be used to only prefix a small subset 16 | * of relevant macros. 17 | * 18 | */ 19 | 20 | #ifndef CATCH_CONFIG_PREFIX_MESSAGES_HPP_INCLUDED 21 | #define CATCH_CONFIG_PREFIX_MESSAGES_HPP_INCLUDED 22 | 23 | #include 24 | 25 | #if defined(CATCH_CONFIG_PREFIX_ALL) && !defined(CATCH_CONFIG_PREFIX_MESSAGES) 26 | #define CATCH_CONFIG_PREFIX_MESSAGES 27 | #endif 28 | 29 | #endif // CATCH_CONFIG_PREFIX_MESSAGES_HPP_INCLUDED 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_config_wchar.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | /** \file 10 | * Wrapper for the WCHAR configuration option 11 | * 12 | * We want to support platforms that do not provide `wchar_t`, so we 13 | * sometimes have to disable providing wchar_t overloads through Catch2, 14 | * e.g. the StringMaker specialization for `std::wstring`. 15 | */ 16 | 17 | #ifndef CATCH_CONFIG_WCHAR_HPP_INCLUDED 18 | #define CATCH_CONFIG_WCHAR_HPP_INCLUDED 19 | 20 | #include 21 | 22 | // We assume that WCHAR should be enabled by default, and only disabled 23 | // for a shortlist (so far only DJGPP) of compilers. 24 | 25 | #if defined(__DJGPP__) 26 | # define CATCH_INTERNAL_CONFIG_NO_WCHAR 27 | #endif // __DJGPP__ 28 | 29 | #if !defined( CATCH_INTERNAL_CONFIG_NO_WCHAR ) && \ 30 | !defined( CATCH_CONFIG_NO_WCHAR ) && \ 31 | !defined( CATCH_CONFIG_WCHAR ) 32 | # define CATCH_CONFIG_WCHAR 33 | #endif 34 | 35 | #endif // CATCH_CONFIG_WCHAR_HPP_INCLUDED 36 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_console_width.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_CONSOLE_WIDTH_HPP_INCLUDED 9 | #define CATCH_CONSOLE_WIDTH_HPP_INCLUDED 10 | 11 | // This include must be kept so that user's configured value for CONSOLE_WIDTH 12 | // is used before we attempt to provide a default value 13 | #include 14 | 15 | #ifndef CATCH_CONFIG_CONSOLE_WIDTH 16 | #define CATCH_CONFIG_CONSOLE_WIDTH 80 17 | #endif 18 | 19 | #endif // CATCH_CONSOLE_WIDTH_HPP_INCLUDED 20 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_debug_console.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_DEBUG_CONSOLE_HPP_INCLUDED 9 | #define CATCH_DEBUG_CONSOLE_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | void writeToDebugConsole( std::string const& text ); 15 | } 16 | 17 | #endif // CATCH_DEBUG_CONSOLE_HPP_INCLUDED 18 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_decomposer.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | 13 | ITransientExpression::~ITransientExpression() = default; 14 | 15 | void formatReconstructedExpression( std::ostream &os, std::string const& lhs, StringRef op, std::string const& rhs ) { 16 | if( lhs.size() + rhs.size() < 40 && 17 | lhs.find('\n') == std::string::npos && 18 | rhs.find('\n') == std::string::npos ) 19 | os << lhs << ' ' << op << ' ' << rhs; 20 | else 21 | os << lhs << '\n' << op << '\n' << rhs; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_errno_guard.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | #include 12 | 13 | namespace Catch { 14 | ErrnoGuard::ErrnoGuard():m_oldErrno(errno){} 15 | ErrnoGuard::~ErrnoGuard() { errno = m_oldErrno; } 16 | } 17 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_errno_guard.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_ERRNO_GUARD_HPP_INCLUDED 9 | #define CATCH_ERRNO_GUARD_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | 13 | //! Simple RAII class that stores the value of `errno` 14 | //! at construction and restores it at destruction. 15 | class ErrnoGuard { 16 | public: 17 | // Keep these outlined to avoid dragging in macros from 18 | 19 | ErrnoGuard(); 20 | ~ErrnoGuard(); 21 | private: 22 | int m_oldErrno; 23 | }; 24 | 25 | } 26 | 27 | #endif // CATCH_ERRNO_GUARD_HPP_INCLUDED 28 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_exception_translator_registry.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_EXCEPTION_TRANSLATOR_REGISTRY_HPP_INCLUDED 9 | #define CATCH_EXCEPTION_TRANSLATOR_REGISTRY_HPP_INCLUDED 10 | 11 | #include 12 | #include 13 | 14 | #include 15 | #include 16 | 17 | namespace Catch { 18 | 19 | class ExceptionTranslatorRegistry : public IExceptionTranslatorRegistry { 20 | public: 21 | ~ExceptionTranslatorRegistry() override; 22 | void registerTranslator( Detail::unique_ptr&& translator ); 23 | std::string translateActiveException() const override; 24 | 25 | private: 26 | ExceptionTranslators m_translators; 27 | }; 28 | } 29 | 30 | #endif // CATCH_EXCEPTION_TRANSLATOR_REGISTRY_HPP_INCLUDED 31 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_floating_point_helpers.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | #include 12 | 13 | namespace Catch { 14 | namespace Detail { 15 | 16 | uint32_t convertToBits(float f) { 17 | static_assert(sizeof(float) == sizeof(uint32_t), "Important ULP matcher assumption violated"); 18 | uint32_t i; 19 | std::memcpy(&i, &f, sizeof(f)); 20 | return i; 21 | } 22 | 23 | uint64_t convertToBits(double d) { 24 | static_assert(sizeof(double) == sizeof(uint64_t), "Important ULP matcher assumption violated"); 25 | uint64_t i; 26 | std::memcpy(&i, &d, sizeof(d)); 27 | return i; 28 | } 29 | 30 | } // end namespace Detail 31 | } // end namespace Catch 32 | 33 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_getenv.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | #include 12 | #include 13 | 14 | #include 15 | 16 | namespace Catch { 17 | namespace Detail { 18 | 19 | #if !defined (CATCH_CONFIG_GETENV) 20 | char const* getEnv( char const* ) { return nullptr; } 21 | #else 22 | 23 | char const* getEnv( char const* varName ) { 24 | # if defined( _MSC_VER ) 25 | # pragma warning( push ) 26 | # pragma warning( disable : 4996 ) // use getenv_s instead of getenv 27 | # endif 28 | 29 | return std::getenv( varName ); 30 | 31 | # if defined( _MSC_VER ) 32 | # pragma warning( pop ) 33 | # endif 34 | } 35 | #endif 36 | } // namespace Detail 37 | } // namespace Catch 38 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_getenv.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_GETENV_HPP_INCLUDED 9 | #define CATCH_GETENV_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | namespace Detail { 13 | 14 | //! Wrapper over `std::getenv` that compiles on UWP (and always returns nullptr there) 15 | char const* getEnv(char const* varName); 16 | 17 | } 18 | } 19 | 20 | #endif // CATCH_GETENV_HPP_INCLUDED 21 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_lazy_expr.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | 12 | namespace Catch { 13 | 14 | auto operator << (std::ostream& os, LazyExpression const& lazyExpr) -> std::ostream& { 15 | if (lazyExpr.m_isNegated) 16 | os << '!'; 17 | 18 | if (lazyExpr) { 19 | if (lazyExpr.m_isNegated && lazyExpr.m_transientExpression->isBinaryExpression()) 20 | os << '(' << *lazyExpr.m_transientExpression << ')'; 21 | else 22 | os << *lazyExpr.m_transientExpression; 23 | } else { 24 | os << "{** error - unchecked empty expression requested **}"; 25 | } 26 | return os; 27 | } 28 | 29 | } // namespace Catch 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_leak_detector.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_LEAK_DETECTOR_HPP_INCLUDED 9 | #define CATCH_LEAK_DETECTOR_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | 13 | struct LeakDetector { 14 | LeakDetector(); 15 | ~LeakDetector(); 16 | }; 17 | 18 | } 19 | #endif // CATCH_LEAK_DETECTOR_HPP_INCLUDED 20 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_list.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_LIST_HPP_INCLUDED 9 | #define CATCH_LIST_HPP_INCLUDED 10 | 11 | #include 12 | 13 | #include 14 | #include 15 | 16 | 17 | namespace Catch { 18 | 19 | class IEventListener; 20 | class Config; 21 | 22 | 23 | struct ReporterDescription { 24 | std::string name, description; 25 | }; 26 | struct ListenerDescription { 27 | StringRef name; 28 | std::string description; 29 | }; 30 | 31 | struct TagInfo { 32 | void add(StringRef spelling); 33 | std::string all() const; 34 | 35 | std::set spellings; 36 | std::size_t count = 0; 37 | }; 38 | 39 | bool list( IEventListener& reporter, Config const& config ); 40 | 41 | } // end namespace Catch 42 | 43 | #endif // CATCH_LIST_HPP_INCLUDED 44 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_message_info.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | namespace Catch { 12 | 13 | MessageInfo::MessageInfo( StringRef _macroName, 14 | SourceLineInfo const& _lineInfo, 15 | ResultWas::OfType _type ) 16 | : macroName( _macroName ), 17 | lineInfo( _lineInfo ), 18 | type( _type ), 19 | sequence( ++globalCount ) 20 | {} 21 | 22 | // This may need protecting if threading support is added 23 | unsigned int MessageInfo::globalCount = 0; 24 | 25 | } // end namespace Catch 26 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_move_and_forward.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_MOVE_AND_FORWARD_HPP_INCLUDED 9 | #define CATCH_MOVE_AND_FORWARD_HPP_INCLUDED 10 | 11 | #include 12 | 13 | //! Replacement for std::move with better compile time performance 14 | #define CATCH_MOVE(...) static_cast&&>(__VA_ARGS__) 15 | 16 | //! Replacement for std::forward with better compile time performance 17 | #define CATCH_FORWARD(...) static_cast(__VA_ARGS__) 18 | 19 | #endif // CATCH_MOVE_AND_FORWARD_HPP_INCLUDED 20 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_noncopyable.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_NONCOPYABLE_HPP_INCLUDED 9 | #define CATCH_NONCOPYABLE_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | namespace Detail { 13 | 14 | //! Deriving classes become noncopyable and nonmovable 15 | class NonCopyable { 16 | NonCopyable( NonCopyable const& ) = delete; 17 | NonCopyable( NonCopyable&& ) = delete; 18 | NonCopyable& operator=( NonCopyable const& ) = delete; 19 | NonCopyable& operator=( NonCopyable&& ) = delete; 20 | 21 | protected: 22 | NonCopyable() noexcept = default; 23 | }; 24 | 25 | } // namespace Detail 26 | } // namespace Catch 27 | 28 | #endif // CATCH_NONCOPYABLE_HPP_INCLUDED 29 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_parse_numbers.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_PARSE_NUMBERS_HPP_INCLUDED 9 | #define CATCH_PARSE_NUMBERS_HPP_INCLUDED 10 | 11 | #include 12 | 13 | #include 14 | 15 | namespace Catch { 16 | 17 | /** 18 | * Parses unsigned int from the input, using provided base 19 | * 20 | * Effectively a wrapper around std::stoul but with better error checking 21 | * e.g. "-1" is rejected, instead of being parsed as UINT_MAX. 22 | */ 23 | Optional parseUInt(std::string const& input, int base = 10); 24 | } 25 | 26 | #endif // CATCH_PARSE_NUMBERS_HPP_INCLUDED 27 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_polyfills.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | #include 14 | 15 | namespace Catch { 16 | 17 | #if !defined(CATCH_CONFIG_POLYFILL_ISNAN) 18 | bool isnan(float f) { 19 | return std::isnan(f); 20 | } 21 | bool isnan(double d) { 22 | return std::isnan(d); 23 | } 24 | #else 25 | // For now we only use this for embarcadero 26 | bool isnan(float f) { 27 | return std::_isnan(f); 28 | } 29 | bool isnan(double d) { 30 | return std::_isnan(d); 31 | } 32 | #endif 33 | 34 | } // end namespace Catch 35 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_polyfills.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_POLYFILLS_HPP_INCLUDED 9 | #define CATCH_POLYFILLS_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | bool isnan(float f); 13 | bool isnan(double d); 14 | } 15 | 16 | #endif // CATCH_POLYFILLS_HPP_INCLUDED 17 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_preprocessor_internal_stringify.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_PREPROCESSOR_INTERNAL_STRINGIFY_HPP_INCLUDED 9 | #define CATCH_PREPROCESSOR_INTERNAL_STRINGIFY_HPP_INCLUDED 10 | 11 | #include 12 | 13 | #if !defined(CATCH_CONFIG_DISABLE_STRINGIFICATION) 14 | #define CATCH_INTERNAL_STRINGIFY(...) #__VA_ARGS__##_catch_sr 15 | #else 16 | #define CATCH_INTERNAL_STRINGIFY(...) "Disabled by CATCH_CONFIG_DISABLE_STRINGIFICATION"_catch_sr 17 | #endif 18 | 19 | #endif // CATCH_PREPROCESSOR_INTERNAL_STRINGIFY_HPP_INCLUDED 20 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_preprocessor_remove_parens.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_PREPROCESSOR_REMOVE_PARENS_HPP_INCLUDED 9 | #define CATCH_PREPROCESSOR_REMOVE_PARENS_HPP_INCLUDED 10 | 11 | #define INTERNAL_CATCH_EXPAND1( param ) INTERNAL_CATCH_EXPAND2( param ) 12 | #define INTERNAL_CATCH_EXPAND2( ... ) INTERNAL_CATCH_NO##__VA_ARGS__ 13 | #define INTERNAL_CATCH_DEF( ... ) INTERNAL_CATCH_DEF __VA_ARGS__ 14 | #define INTERNAL_CATCH_NOINTERNAL_CATCH_DEF 15 | 16 | #define INTERNAL_CATCH_REMOVE_PARENS( ... ) \ 17 | INTERNAL_CATCH_EXPAND1( INTERNAL_CATCH_DEF __VA_ARGS__ ) 18 | 19 | #endif // CATCH_PREPROCESSOR_REMOVE_PARENS_HPP_INCLUDED 20 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_random_seed_generation.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | #include 12 | 13 | #include 14 | #include 15 | 16 | namespace Catch { 17 | 18 | std::uint32_t generateRandomSeed( GenerateFrom from ) { 19 | switch ( from ) { 20 | case GenerateFrom::Time: 21 | return static_cast( std::time( nullptr ) ); 22 | 23 | case GenerateFrom::Default: 24 | case GenerateFrom::RandomDevice: 25 | // In theory, a platform could have random_device that returns just 26 | // 16 bits. That is still some randomness, so we don't care too much 27 | return static_cast( std::random_device{}() ); 28 | 29 | default: 30 | CATCH_ERROR("Unknown generation method"); 31 | } 32 | } 33 | 34 | } // end namespace Catch 35 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_random_seed_generation.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_RANDOM_SEED_GENERATION_HPP_INCLUDED 9 | #define CATCH_RANDOM_SEED_GENERATION_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | enum class GenerateFrom { 16 | Time, 17 | RandomDevice, 18 | //! Currently equivalent to RandomDevice, but can change at any point 19 | Default 20 | }; 21 | 22 | std::uint32_t generateRandomSeed(GenerateFrom from); 23 | 24 | } // end namespace Catch 25 | 26 | #endif // CATCH_RANDOM_SEED_GENERATION_HPP_INCLUDED 27 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_result_type.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #include 9 | 10 | namespace Catch { 11 | 12 | bool isOk( ResultWas::OfType resultType ) { 13 | return ( resultType & ResultWas::FailureBit ) == 0; 14 | } 15 | bool isJustInfo( int flags ) { 16 | return flags == ResultWas::Info; 17 | } 18 | 19 | ResultDisposition::Flags operator | ( ResultDisposition::Flags lhs, ResultDisposition::Flags rhs ) { 20 | return static_cast( static_cast( lhs ) | static_cast( rhs ) ); 21 | } 22 | 23 | bool shouldContinueOnFailure( int flags ) { return ( flags & ResultDisposition::ContinueOnFailure ) != 0; } 24 | bool shouldSuppressFailure( int flags ) { return ( flags & ResultDisposition::SuppressFail ) != 0; } 25 | 26 | } // end namespace Catch 27 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_singletons.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #include 9 | 10 | #include 11 | 12 | namespace Catch { 13 | 14 | namespace { 15 | static auto getSingletons() -> std::vector*& { 16 | static std::vector* g_singletons = nullptr; 17 | if( !g_singletons ) 18 | g_singletons = new std::vector(); 19 | return g_singletons; 20 | } 21 | } 22 | 23 | ISingleton::~ISingleton() = default; 24 | 25 | void addSingleton(ISingleton* singleton ) { 26 | getSingletons()->push_back( singleton ); 27 | } 28 | void cleanupSingletons() { 29 | auto& singletons = getSingletons(); 30 | for( auto singleton : *singletons ) 31 | delete singleton; 32 | delete singletons; 33 | singletons = nullptr; 34 | } 35 | 36 | } // namespace Catch 37 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_source_line_info.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_SOURCE_LINE_INFO_HPP_INCLUDED 9 | #define CATCH_SOURCE_LINE_INFO_HPP_INCLUDED 10 | 11 | #include 12 | #include 13 | 14 | namespace Catch { 15 | 16 | struct SourceLineInfo { 17 | 18 | SourceLineInfo() = delete; 19 | constexpr SourceLineInfo( char const* _file, std::size_t _line ) noexcept: 20 | file( _file ), 21 | line( _line ) 22 | {} 23 | 24 | bool operator == ( SourceLineInfo const& other ) const noexcept; 25 | bool operator < ( SourceLineInfo const& other ) const noexcept; 26 | 27 | char const* file; 28 | std::size_t line; 29 | 30 | friend std::ostream& operator << (std::ostream& os, SourceLineInfo const& info); 31 | }; 32 | } 33 | 34 | #define CATCH_INTERNAL_LINEINFO \ 35 | ::Catch::SourceLineInfo( __FILE__, static_cast( __LINE__ ) ) 36 | 37 | #endif // CATCH_SOURCE_LINE_INFO_HPP_INCLUDED 38 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_startup_exception_registry.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | namespace Catch { 14 | #if !defined(CATCH_CONFIG_DISABLE_EXCEPTIONS) 15 | void StartupExceptionRegistry::add( std::exception_ptr const& exception ) noexcept { 16 | CATCH_TRY { 17 | m_exceptions.push_back(exception); 18 | } CATCH_CATCH_ALL { 19 | // If we run out of memory during start-up there's really not a lot more we can do about it 20 | std::terminate(); 21 | } 22 | } 23 | 24 | std::vector const& StartupExceptionRegistry::getExceptions() const noexcept { 25 | return m_exceptions; 26 | } 27 | #endif 28 | 29 | } // end namespace Catch 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_startup_exception_registry.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_STARTUP_EXCEPTION_REGISTRY_HPP_INCLUDED 9 | #define CATCH_STARTUP_EXCEPTION_REGISTRY_HPP_INCLUDED 10 | 11 | 12 | #include 13 | #include 14 | 15 | namespace Catch { 16 | 17 | class StartupExceptionRegistry { 18 | #if !defined(CATCH_CONFIG_DISABLE_EXCEPTIONS) 19 | public: 20 | void add(std::exception_ptr const& exception) noexcept; 21 | std::vector const& getExceptions() const noexcept; 22 | private: 23 | std::vector m_exceptions; 24 | #endif 25 | }; 26 | 27 | } // end namespace Catch 28 | 29 | #endif // CATCH_STARTUP_EXCEPTION_REGISTRY_HPP_INCLUDED 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_stdstreams.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | #include 12 | 13 | #include 14 | 15 | namespace Catch { 16 | 17 | // If you #define this you must implement these functions 18 | #if !defined( CATCH_CONFIG_NOSTDOUT ) 19 | std::ostream& cout() { return std::cout; } 20 | std::ostream& cerr() { return std::cerr; } 21 | std::ostream& clog() { return std::clog; } 22 | #endif 23 | 24 | } // namespace Catch 25 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_stdstreams.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #ifndef CATCH_STDSTREAMS_HPP_INCLUDED 10 | #define CATCH_STDSTREAMS_HPP_INCLUDED 11 | 12 | #include 13 | 14 | namespace Catch { 15 | 16 | std::ostream& cout(); 17 | std::ostream& cerr(); 18 | std::ostream& clog(); 19 | 20 | } // namespace Catch 21 | 22 | #endif 23 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_stream_end_stop.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_STREAM_END_STOP_HPP_INCLUDED 9 | #define CATCH_STREAM_END_STOP_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | // Use this in variadic streaming macros to allow 16 | // << +StreamEndStop 17 | // as well as 18 | // << stuff +StreamEndStop 19 | struct StreamEndStop { 20 | constexpr StringRef operator+() const { return StringRef(); } 21 | 22 | template 23 | constexpr friend T const& operator+( T const& value, StreamEndStop ) { 24 | return value; 25 | } 26 | }; 27 | 28 | } // namespace Catch 29 | 30 | #endif // CATCH_STREAM_END_STOP_HPP_INCLUDED 31 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_tag_alias_registry.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TAG_ALIAS_REGISTRY_HPP_INCLUDED 9 | #define CATCH_TAG_ALIAS_REGISTRY_HPP_INCLUDED 10 | 11 | #include 12 | #include 13 | 14 | #include 15 | #include 16 | 17 | namespace Catch { 18 | struct SourceLineInfo; 19 | 20 | class TagAliasRegistry : public ITagAliasRegistry { 21 | public: 22 | ~TagAliasRegistry() override; 23 | TagAlias const* find( std::string const& alias ) const override; 24 | std::string expandAliases( std::string const& unexpandedTestSpec ) const override; 25 | void add( std::string const& alias, std::string const& tag, SourceLineInfo const& lineInfo ); 26 | 27 | private: 28 | std::map m_registry; 29 | }; 30 | 31 | } // end namespace Catch 32 | 33 | #endif // CATCH_TAG_ALIAS_REGISTRY_HPP_INCLUDED 34 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_test_case_info_hasher.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TEST_CASE_INFO_HASHER_HPP_INCLUDED 9 | #define CATCH_TEST_CASE_INFO_HASHER_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | struct TestCaseInfo; 16 | 17 | class TestCaseInfoHasher { 18 | public: 19 | using hash_t = std::uint64_t; 20 | TestCaseInfoHasher( hash_t seed ); 21 | uint32_t operator()( TestCaseInfo const& t ) const; 22 | 23 | private: 24 | hash_t m_seed; 25 | }; 26 | 27 | } // namespace Catch 28 | 29 | #endif /* CATCH_TEST_CASE_INFO_HASHER_HPP_INCLUDED */ 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_test_failure_exception.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | #include 12 | 13 | namespace Catch { 14 | 15 | void throw_test_failure_exception() { 16 | #if !defined( CATCH_CONFIG_DISABLE_EXCEPTIONS ) 17 | throw TestFailureException{}; 18 | #else 19 | CATCH_ERROR( "Test failure requires aborting test!" ); 20 | #endif 21 | } 22 | 23 | void throw_test_skip_exception() { 24 | #if !defined( CATCH_CONFIG_DISABLE_EXCEPTIONS ) 25 | throw Catch::TestSkipException(); 26 | #else 27 | CATCH_ERROR( "Explicitly skipping tests during runtime requires exceptions" ); 28 | #endif 29 | } 30 | 31 | } // namespace Catch 32 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_test_failure_exception.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TEST_FAILURE_EXCEPTION_HPP_INCLUDED 9 | #define CATCH_TEST_FAILURE_EXCEPTION_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | 13 | //! Used to signal that an assertion macro failed 14 | struct TestFailureException{}; 15 | //! Used to signal that the remainder of a test should be skipped 16 | struct TestSkipException {}; 17 | 18 | /** 19 | * Outlines throwing of `TestFailureException` into a single TU 20 | * 21 | * Also handles `CATCH_CONFIG_DISABLE_EXCEPTIONS` for callers. 22 | */ 23 | [[noreturn]] void throw_test_failure_exception(); 24 | 25 | /** 26 | * Outlines throwing of `TestSkipException` into a single TU 27 | * 28 | * Also handles `CATCH_CONFIG_DISABLE_EXCEPTIONS` for callers. 29 | */ 30 | [[noreturn]] void throw_test_skip_exception(); 31 | 32 | } // namespace Catch 33 | 34 | #endif // CATCH_TEST_FAILURE_EXCEPTION_HPP_INCLUDED 35 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_test_run_info.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TEST_RUN_INFO_HPP_INCLUDED 9 | #define CATCH_TEST_RUN_INFO_HPP_INCLUDED 10 | 11 | #include 12 | 13 | namespace Catch { 14 | 15 | struct TestRunInfo { 16 | constexpr TestRunInfo(StringRef _name) : name(_name) {} 17 | StringRef name; 18 | }; 19 | 20 | } // end namespace Catch 21 | 22 | #endif // CATCH_TEST_RUN_INFO_HPP_INCLUDED 23 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_to_string.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_TO_STRING_HPP_INCLUDED 9 | #define CATCH_TO_STRING_HPP_INCLUDED 10 | 11 | #include 12 | 13 | #include 14 | #include 15 | 16 | namespace Catch { 17 | template 18 | std::string to_string(T const& t) { 19 | #if defined(CATCH_CONFIG_CPP11_TO_STRING) 20 | return std::to_string(t); 21 | #else 22 | ReusableStringStream rss; 23 | rss << t; 24 | return rss.str(); 25 | #endif 26 | } 27 | } // end namespace Catch 28 | 29 | #endif // CATCH_TO_STRING_HPP_INCLUDED 30 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_uncaught_exceptions.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | #include 12 | #include 13 | 14 | #include 15 | 16 | namespace Catch { 17 | bool uncaught_exceptions() { 18 | #if defined(CATCH_CONFIG_DISABLE_EXCEPTIONS) 19 | return false; 20 | #elif defined(CATCH_CONFIG_CPP17_UNCAUGHT_EXCEPTIONS) 21 | return std::uncaught_exceptions() > 0; 22 | #else 23 | return std::uncaught_exception(); 24 | #endif 25 | } 26 | } // end namespace Catch 27 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_uncaught_exceptions.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_UNCAUGHT_EXCEPTIONS_HPP_INCLUDED 9 | #define CATCH_UNCAUGHT_EXCEPTIONS_HPP_INCLUDED 10 | 11 | namespace Catch { 12 | bool uncaught_exceptions(); 13 | } // end namespace Catch 14 | 15 | #endif // CATCH_UNCAUGHT_EXCEPTIONS_HPP_INCLUDED 16 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_unique_name.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_UNIQUE_NAME_HPP_INCLUDED 9 | #define CATCH_UNIQUE_NAME_HPP_INCLUDED 10 | 11 | #include 12 | #define INTERNAL_CATCH_UNIQUE_NAME_LINE2( name, line ) name##line 13 | #define INTERNAL_CATCH_UNIQUE_NAME_LINE( name, line ) INTERNAL_CATCH_UNIQUE_NAME_LINE2( name, line ) 14 | #ifdef CATCH_CONFIG_COUNTER 15 | # define INTERNAL_CATCH_UNIQUE_NAME( name ) INTERNAL_CATCH_UNIQUE_NAME_LINE( name, __COUNTER__ ) 16 | #else 17 | # define INTERNAL_CATCH_UNIQUE_NAME( name ) INTERNAL_CATCH_UNIQUE_NAME_LINE( name, __LINE__ ) 18 | #endif 19 | 20 | #endif // CATCH_UNIQUE_NAME_HPP_INCLUDED 21 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_void_type.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_VOID_TYPE_HPP_INCLUDED 9 | #define CATCH_VOID_TYPE_HPP_INCLUDED 10 | 11 | 12 | namespace Catch { 13 | namespace Detail { 14 | 15 | template 16 | struct make_void { using type = void; }; 17 | 18 | template 19 | using void_t = typename make_void::type; 20 | 21 | } // namespace Detail 22 | } // namespace Catch 23 | 24 | 25 | #endif // CATCH_VOID_TYPE_HPP_INCLUDED 26 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_wildcard_pattern.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_WILDCARD_PATTERN_HPP_INCLUDED 9 | #define CATCH_WILDCARD_PATTERN_HPP_INCLUDED 10 | 11 | #include 12 | 13 | #include 14 | 15 | namespace Catch 16 | { 17 | class WildcardPattern { 18 | enum WildcardPosition { 19 | NoWildcard = 0, 20 | WildcardAtStart = 1, 21 | WildcardAtEnd = 2, 22 | WildcardAtBothEnds = WildcardAtStart | WildcardAtEnd 23 | }; 24 | 25 | public: 26 | 27 | WildcardPattern( std::string const& pattern, CaseSensitive caseSensitivity ); 28 | bool matches( std::string const& str ) const; 29 | 30 | private: 31 | std::string normaliseString( std::string const& str ) const; 32 | CaseSensitive m_caseSensitivity; 33 | WildcardPosition m_wildcard = NoWildcard; 34 | std::string m_pattern; 35 | }; 36 | } 37 | 38 | #endif // CATCH_WILDCARD_PATTERN_HPP_INCLUDED 39 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/internal/catch_windows_h_proxy.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_WINDOWS_H_PROXY_HPP_INCLUDED 9 | #define CATCH_WINDOWS_H_PROXY_HPP_INCLUDED 10 | 11 | #include 12 | 13 | #if defined(CATCH_PLATFORM_WINDOWS) 14 | 15 | // We might end up with the define made globally through the compiler, 16 | // and we don't want to trigger warnings for this 17 | #if !defined(NOMINMAX) 18 | # define NOMINMAX 19 | #endif 20 | #if !defined(WIN32_LEAN_AND_MEAN) 21 | # define WIN32_LEAN_AND_MEAN 22 | #endif 23 | 24 | #include 25 | 26 | #endif // defined(CATCH_PLATFORM_WINDOWS) 27 | 28 | #endif // CATCH_WINDOWS_H_PROXY_HPP_INCLUDED 29 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/matchers/catch_matchers.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | 10 | #include 11 | 12 | namespace Catch { 13 | namespace Matchers { 14 | 15 | std::string MatcherUntypedBase::toString() const { 16 | if (m_cachedToString.empty()) { 17 | m_cachedToString = describe(); 18 | } 19 | return m_cachedToString; 20 | } 21 | 22 | MatcherUntypedBase::~MatcherUntypedBase() = default; 23 | 24 | } // namespace Matchers 25 | } // namespace Catch 26 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/matchers/catch_matchers_container_properties.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | 12 | namespace Catch { 13 | namespace Matchers { 14 | 15 | std::string IsEmptyMatcher::describe() const { 16 | return "is empty"; 17 | } 18 | 19 | std::string HasSizeMatcher::describe() const { 20 | ReusableStringStream sstr; 21 | sstr << "has size == " << m_target_size; 22 | return sstr.str(); 23 | } 24 | 25 | IsEmptyMatcher IsEmpty() { 26 | return {}; 27 | } 28 | 29 | HasSizeMatcher SizeIs(std::size_t sz) { 30 | return HasSizeMatcher{ sz }; 31 | } 32 | 33 | } // end namespace Matchers 34 | } // end namespace Catch 35 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/matchers/catch_matchers_exception.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #include 9 | 10 | namespace Catch { 11 | namespace Matchers { 12 | 13 | bool ExceptionMessageMatcher::match(std::exception const& ex) const { 14 | return ex.what() == m_message; 15 | } 16 | 17 | std::string ExceptionMessageMatcher::describe() const { 18 | return "exception message matches \"" + m_message + '"'; 19 | } 20 | 21 | ExceptionMessageMatcher Message(std::string const& message) { 22 | return ExceptionMessageMatcher(message); 23 | } 24 | 25 | } // namespace Matchers 26 | } // namespace Catch 27 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/matchers/catch_matchers_predicate.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | 11 | std::string Catch::Matchers::Detail::finalizeDescription(const std::string& desc) { 12 | if (desc.empty()) { 13 | return "matches undescribed predicate"; 14 | } else { 15 | return "matches predicate: \"" + desc + '"'; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/matchers/catch_matchers_quantifiers.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #include 9 | 10 | namespace Catch { 11 | namespace Matchers { 12 | std::string AllTrueMatcher::describe() const { return "contains only true"; } 13 | 14 | AllTrueMatcher AllTrue() { return AllTrueMatcher{}; } 15 | 16 | std::string NoneTrueMatcher::describe() const { return "contains no true"; } 17 | 18 | NoneTrueMatcher NoneTrue() { return NoneTrueMatcher{}; } 19 | 20 | std::string AnyTrueMatcher::describe() const { return "contains at least one true"; } 21 | 22 | AnyTrueMatcher AnyTrue() { return AnyTrueMatcher{}; } 23 | } // namespace Matchers 24 | } // namespace Catch 25 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/matchers/internal/catch_matchers_impl.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | 9 | #include 10 | #include 11 | #include 12 | #include 13 | 14 | namespace Catch { 15 | 16 | // This is the general overload that takes a any string matcher 17 | // There is another overload, in catch_assertionhandler.h/.cpp, that only takes a string and infers 18 | // the Equals matcher (so the header does not mention matchers) 19 | void handleExceptionMatchExpr( AssertionHandler& handler, StringMatcher const& matcher ) { 20 | std::string exceptionMessage = Catch::translateActiveException(); 21 | MatchExpr expr( CATCH_MOVE(exceptionMessage), matcher ); 22 | handler.handleExpr( expr ); 23 | } 24 | 25 | } // namespace Catch 26 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/reporters/catch_reporter_compact.hpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #ifndef CATCH_REPORTER_COMPACT_HPP_INCLUDED 9 | #define CATCH_REPORTER_COMPACT_HPP_INCLUDED 10 | 11 | 12 | #include 13 | 14 | 15 | namespace Catch { 16 | 17 | class CompactReporter final : public StreamingReporterBase { 18 | public: 19 | using StreamingReporterBase::StreamingReporterBase; 20 | 21 | ~CompactReporter() override; 22 | 23 | static std::string getDescription(); 24 | 25 | void noMatchingTestCases( StringRef unmatchedSpec ) override; 26 | 27 | void testRunStarting( TestRunInfo const& _testInfo ) override; 28 | 29 | void assertionEnded(AssertionStats const& _assertionStats) override; 30 | 31 | void sectionEnded(SectionStats const& _sectionStats) override; 32 | 33 | void testRunEnded(TestRunStats const& _testRunStats) override; 34 | 35 | }; 36 | 37 | } // end namespace Catch 38 | 39 | #endif // CATCH_REPORTER_COMPACT_HPP_INCLUDED 40 | -------------------------------------------------------------------------------- /tests/extern/Catch2/src/catch2/reporters/catch_reporter_streaming_base.cpp: -------------------------------------------------------------------------------- 1 | 2 | // Copyright Catch2 Authors 3 | // Distributed under the Boost Software License, Version 1.0. 4 | // (See accompanying file LICENSE.txt or copy at 5 | // https://www.boost.org/LICENSE_1_0.txt) 6 | 7 | // SPDX-License-Identifier: BSL-1.0 8 | #include 9 | 10 | namespace Catch { 11 | 12 | StreamingReporterBase::~StreamingReporterBase() = default; 13 | 14 | void 15 | StreamingReporterBase::testRunStarting( TestRunInfo const& _testRunInfo ) { 16 | currentTestRunInfo = _testRunInfo; 17 | } 18 | 19 | void StreamingReporterBase::testRunEnded( TestRunStats const& ) { 20 | currentTestCaseInfo = nullptr; 21 | } 22 | 23 | } // end namespace Catch 24 | --------------------------------------------------------------------------------