Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/core
diff options
context:
space:
mode:
authorKae <80987908+Novaenia@users.noreply.github.com>2024-02-26 13:57:22 +1100
committerGitHub <noreply@github.com>2024-02-26 13:57:22 +1100
commita1addf1ec23ac8a30529ac5f6c2c70153b62b45c (patch)
treeb11726791ebbfa06a3b2f6c72278735e2d31444f /source/core
parent7d9c9d3b32bd0eef5115a1ba02aa8939f292b212 (diff)
parent3073a88cd16b6e85401363c814e5ac7ae11b9270 (diff)
Merge pull request #22 from kblaschke/use-pragma-once
Use "#pragma once" instead of include guards
Diffstat (limited to 'source/core')
-rw-r--r--source/core/StarAStar.hpp5
-rw-r--r--source/core/StarAlgorithm.hpp5
-rw-r--r--source/core/StarArray.hpp5
-rw-r--r--source/core/StarAssetPath.hpp5
-rw-r--r--source/core/StarAtomicSharedPtr.hpp5
-rw-r--r--source/core/StarAudio.hpp5
-rw-r--r--source/core/StarBTree.hpp6
-rw-r--r--source/core/StarBTreeDatabase.hpp5
-rw-r--r--source/core/StarBiMap.hpp5
-rw-r--r--source/core/StarBlockAllocator.hpp5
-rw-r--r--source/core/StarBuffer.hpp5
-rw-r--r--source/core/StarByteArray.hpp5
-rw-r--r--source/core/StarBytes.hpp5
-rw-r--r--source/core/StarCasting.hpp5
-rw-r--r--source/core/StarColor.hpp5
-rw-r--r--source/core/StarCompression.hpp5
-rw-r--r--source/core/StarConfig.hpp29
-rw-r--r--source/core/StarCurve25519.hpp6
-rw-r--r--source/core/StarDataStream.hpp5
-rw-r--r--source/core/StarDataStreamDevices.hpp5
-rw-r--r--source/core/StarDataStreamExtra.hpp5
-rw-r--r--source/core/StarDirectives.hpp5
-rw-r--r--source/core/StarDynamicLib.hpp5
-rw-r--r--source/core/StarEither.hpp5
-rw-r--r--source/core/StarEncode.hpp5
-rw-r--r--source/core/StarException.hpp5
-rw-r--r--source/core/StarFile.hpp5
-rw-r--r--source/core/StarFlatHashMap.hpp5
-rw-r--r--source/core/StarFlatHashSet.hpp5
-rw-r--r--source/core/StarFlatHashTable.hpp5
-rw-r--r--source/core/StarFont.hpp5
-rw-r--r--source/core/StarFormat.hpp5
-rw-r--r--source/core/StarFormattedJson.hpp5
-rw-r--r--source/core/StarHash.hpp5
-rw-r--r--source/core/StarHostAddress.hpp5
-rw-r--r--source/core/StarIODevice.hpp5
-rw-r--r--source/core/StarIdMap.hpp5
-rw-r--r--source/core/StarImage.hpp5
-rw-r--r--source/core/StarImageProcessing.hpp5
-rw-r--r--source/core/StarInputEvent.hpp5
-rw-r--r--source/core/StarInterpolation.hpp5
-rw-r--r--source/core/StarIterator.hpp5
-rw-r--r--source/core/StarJson.hpp5
-rw-r--r--source/core/StarJsonBuilder.hpp5
-rw-r--r--source/core/StarJsonExtra.hpp5
-rw-r--r--source/core/StarJsonParser.hpp5
-rw-r--r--source/core/StarJsonPatch.hpp5
-rw-r--r--source/core/StarJsonPath.hpp5
-rw-r--r--source/core/StarJsonRpc.hpp5
-rw-r--r--source/core/StarLexicalCast.hpp5
-rw-r--r--source/core/StarLine.hpp5
-rw-r--r--source/core/StarList.hpp5
-rw-r--r--source/core/StarListener.hpp5
-rw-r--r--source/core/StarLockFile.hpp5
-rw-r--r--source/core/StarLogging.hpp5
-rw-r--r--source/core/StarLruCache.hpp5
-rw-r--r--source/core/StarLua.hpp5
-rw-r--r--source/core/StarLuaConverters.hpp5
-rw-r--r--source/core/StarMap.hpp5
-rw-r--r--source/core/StarMathCommon.hpp5
-rw-r--r--source/core/StarMatrix3.hpp5
-rw-r--r--source/core/StarMaybe.hpp5
-rw-r--r--source/core/StarMemory.hpp5
-rw-r--r--source/core/StarMultiArray.hpp5
-rw-r--r--source/core/StarMultiArrayInterpolator.hpp5
-rw-r--r--source/core/StarMultiTable.hpp5
-rw-r--r--source/core/StarNetElement.hpp5
-rw-r--r--source/core/StarNetElementBasicFields.hpp5
-rw-r--r--source/core/StarNetElementContainers.hpp5
-rw-r--r--source/core/StarNetElementDynamicGroup.hpp5
-rw-r--r--source/core/StarNetElementFloatFields.hpp5
-rw-r--r--source/core/StarNetElementGroup.hpp5
-rw-r--r--source/core/StarNetElementSignal.hpp5
-rw-r--r--source/core/StarNetElementSyncGroup.hpp5
-rw-r--r--source/core/StarNetElementSystem.hpp5
-rw-r--r--source/core/StarNetImpl.hpp2
-rw-r--r--source/core/StarObserverStream.hpp5
-rw-r--r--source/core/StarOptionParser.hpp5
-rw-r--r--source/core/StarOrderedMap.hpp5
-rw-r--r--source/core/StarOrderedSet.hpp5
-rw-r--r--source/core/StarOutputProxy.hpp5
-rw-r--r--source/core/StarParametricFunction.hpp5
-rw-r--r--source/core/StarPch.hpp6
-rw-r--r--source/core/StarPeriodic.hpp5
-rw-r--r--source/core/StarPeriodicFunction.hpp5
-rw-r--r--source/core/StarPerlin.hpp5
-rw-r--r--source/core/StarPoly.hpp5
-rw-r--r--source/core/StarPythonic.hpp5
-rw-r--r--source/core/StarRandom.hpp5
-rw-r--r--source/core/StarRandomPoint.hpp5
-rw-r--r--source/core/StarRect.hpp5
-rw-r--r--source/core/StarRefPtr.hpp5
-rw-r--r--source/core/StarRpcPromise.hpp5
-rw-r--r--source/core/StarRpcThreadPromise.hpp5
-rw-r--r--source/core/StarSectorArray2D.hpp5
-rw-r--r--source/core/StarSecureRandom.hpp5
-rw-r--r--source/core/StarSet.hpp5
-rw-r--r--source/core/StarSha256.hpp5
-rw-r--r--source/core/StarShellParser.hpp5
-rw-r--r--source/core/StarSignalHandler.hpp5
-rw-r--r--source/core/StarSmallVector.hpp5
-rw-r--r--source/core/StarSocket.hpp5
-rw-r--r--source/core/StarSpatialHash2D.hpp5
-rw-r--r--source/core/StarSpline.hpp5
-rw-r--r--source/core/StarStaticRandom.hpp5
-rw-r--r--source/core/StarStaticVector.hpp5
-rw-r--r--source/core/StarString.hpp5
-rw-r--r--source/core/StarStringView.hpp5
-rw-r--r--source/core/StarString_windows.hpp5
-rw-r--r--source/core/StarStrongTypedef.hpp5
-rw-r--r--source/core/StarTcp.hpp5
-rw-r--r--source/core/StarText.hpp6
-rw-r--r--source/core/StarThread.hpp5
-rw-r--r--source/core/StarTickRateMonitor.hpp5
-rw-r--r--source/core/StarTime.hpp5
-rw-r--r--source/core/StarTtlCache.hpp5
-rw-r--r--source/core/StarUdp.hpp5
-rw-r--r--source/core/StarUnicode.hpp5
-rw-r--r--source/core/StarUuid.hpp5
-rw-r--r--source/core/StarVariant.hpp5
-rw-r--r--source/core/StarVector.hpp5
-rw-r--r--source/core/StarVlqEncoding.hpp5
-rw-r--r--source/core/StarWeightedPool.hpp5
-rw-r--r--source/core/StarWorkerPool.hpp5
-rw-r--r--source/core/StarXXHash.hpp5
125 files changed, 141 insertions, 509 deletions
diff --git a/source/core/StarAStar.hpp b/source/core/StarAStar.hpp
index eedac8c..13d7dbd 100644
--- a/source/core/StarAStar.hpp
+++ b/source/core/StarAStar.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_A_STAR_HPP
-#define STAR_A_STAR_HPP
+#pragma once
#include <queue>
@@ -272,5 +271,3 @@ namespace AStar {
}
}
-
-#endif
diff --git a/source/core/StarAlgorithm.hpp b/source/core/StarAlgorithm.hpp
index ef82cc8..1e5e85c 100644
--- a/source/core/StarAlgorithm.hpp
+++ b/source/core/StarAlgorithm.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ALGORITHM_HPP
-#define STAR_ALGORITHM_HPP
+#pragma once
#include "StarException.hpp"
@@ -654,5 +653,3 @@ template <typename T>
struct FunctionTraits<T const&&> : public FunctionTraits<T> {};
}
-
-#endif
diff --git a/source/core/StarArray.hpp b/source/core/StarArray.hpp
index 1b3e150..85ce71b 100644
--- a/source/core/StarArray.hpp
+++ b/source/core/StarArray.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ARRAY_H
-#define STAR_ARRAY_H
+#pragma once
#include <array>
@@ -250,5 +249,3 @@ size_t hash<Array<DataT, SizeT>>::operator()(Array<DataT, SizeT> const& a) const
}
}
-
-#endif
diff --git a/source/core/StarAssetPath.hpp b/source/core/StarAssetPath.hpp
index 3fc7849..f800f2b 100644
--- a/source/core/StarAssetPath.hpp
+++ b/source/core/StarAssetPath.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ASSET_PATH_HPP
-#define STAR_ASSET_PATH_HPP
+#pragma once
#include "StarDirectives.hpp"
#include "StarHash.hpp"
@@ -78,5 +77,3 @@ struct hash<AssetPath> {
}
template <> struct fmt::formatter<Star::AssetPath> : ostream_formatter {};
-
-#endif \ No newline at end of file
diff --git a/source/core/StarAtomicSharedPtr.hpp b/source/core/StarAtomicSharedPtr.hpp
index 306192f..3ca909b 100644
--- a/source/core/StarAtomicSharedPtr.hpp
+++ b/source/core/StarAtomicSharedPtr.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ATOMIC_SHARED_PTR_HPP
-#define STAR_ATOMIC_SHARED_PTR_HPP
+#pragma once
#include "StarThread.hpp"
@@ -117,5 +116,3 @@ AtomicSharedPtr<T>& AtomicSharedPtr<T>::operator=(SharedPtr p) {
}
}
-
-#endif
diff --git a/source/core/StarAudio.hpp b/source/core/StarAudio.hpp
index eda28d9..cf8f91f 100644
--- a/source/core/StarAudio.hpp
+++ b/source/core/StarAudio.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_AUDIO_HPP
-#define STAR_AUDIO_HPP
+#pragma once
#include "StarIODevice.hpp"
@@ -91,5 +90,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarBTree.hpp b/source/core/StarBTree.hpp
index 1ff53bd..cbfe899 100644
--- a/source/core/StarBTree.hpp
+++ b/source/core/StarBTree.hpp
@@ -1,5 +1,5 @@
-#ifndef STAR_B_TREE_HPP
-#define STAR_B_TREE_HPP
+#pragma once
+
#include "StarList.hpp"
#include "StarMaybe.hpp"
@@ -933,5 +933,3 @@ size_t BTreeMixin<Base>::indexFind(Index const& index, Key const& key) {
}
}
-
-#endif
diff --git a/source/core/StarBTreeDatabase.hpp b/source/core/StarBTreeDatabase.hpp
index aff45d3..8f7a4fd 100644
--- a/source/core/StarBTreeDatabase.hpp
+++ b/source/core/StarBTreeDatabase.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_BTREE_DATABASE_HPP
-#define STAR_BTREE_DATABASE_HPP
+#pragma once
#include "StarSet.hpp"
#include "StarBTree.hpp"
@@ -340,5 +339,3 @@ public:
};
}
-
-#endif
diff --git a/source/core/StarBiMap.hpp b/source/core/StarBiMap.hpp
index 8e3d616..07c9618 100644
--- a/source/core/StarBiMap.hpp
+++ b/source/core/StarBiMap.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_BI_MAP_HPP
-#define STAR_BI_MAP_HPP
+#pragma once
#include "StarString.hpp"
@@ -415,5 +414,3 @@ bool BiMap<LeftT, RightT, LeftMapT, RightMapT>::operator==(BiMap const& m) const
}
}
-
-#endif
diff --git a/source/core/StarBlockAllocator.hpp b/source/core/StarBlockAllocator.hpp
index 23e0201..8528699 100644
--- a/source/core/StarBlockAllocator.hpp
+++ b/source/core/StarBlockAllocator.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_BLOCK_ALLOCATOR_HPP
-#define STAR_BLOCK_ALLOCATOR_HPP
+#pragma once
#include <array>
#include <vector>
@@ -264,5 +263,3 @@ typename BlockAllocator<T, BlockSize>::Data* BlockAllocator<T, BlockSize>::getAl
}
}
-
-#endif
diff --git a/source/core/StarBuffer.hpp b/source/core/StarBuffer.hpp
index a92138b..0e1213e 100644
--- a/source/core/StarBuffer.hpp
+++ b/source/core/StarBuffer.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_BUFFER_HPP
-#define STAR_BUFFER_HPP
+#pragma once
#include "StarIODevice.hpp"
#include "StarString.hpp"
@@ -118,5 +117,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarByteArray.hpp b/source/core/StarByteArray.hpp
index cb5633b..9b3e410 100644
--- a/source/core/StarByteArray.hpp
+++ b/source/core/StarByteArray.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_BYTE_ARRAY_H
-#define STAR_BYTE_ARRAY_H
+#pragma once
#include "StarHash.hpp"
#include "StarException.hpp"
@@ -257,5 +256,3 @@ inline size_t hash<ByteArray>::operator()(ByteArray const& b) const {
}
template <> struct fmt::formatter<Star::ByteArray> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarBytes.hpp b/source/core/StarBytes.hpp
index 3dd013f..ce77483 100644
--- a/source/core/StarBytes.hpp
+++ b/source/core/StarBytes.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_BYTES_HPP
-#define STAR_BYTES_HPP
+#pragma once
#include "StarMemory.hpp"
@@ -105,5 +104,3 @@ inline void fromByteOrder(ByteOrder order, void* dest, void const* src, size_t l
}
}
-
-#endif
diff --git a/source/core/StarCasting.hpp b/source/core/StarCasting.hpp
index 0c2ed12..2b8d15a 100644
--- a/source/core/StarCasting.hpp
+++ b/source/core/StarCasting.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_CASTING_HPP
-#define STAR_CASTING_HPP
+#pragma once
#include "StarException.hpp"
#include "StarFormat.hpp"
@@ -89,5 +88,3 @@ weak_ptr<Type const> asWeak(shared_ptr<Type const> const& p) {
}
}
-
-#endif
diff --git a/source/core/StarColor.hpp b/source/core/StarColor.hpp
index 18ae0a0..47e6896 100644
--- a/source/core/StarColor.hpp
+++ b/source/core/StarColor.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_COLOR_HPP
-#define STAR_COLOR_HPP
+#pragma once
#include "StarStringView.hpp"
#include "StarVector.hpp"
@@ -171,5 +170,3 @@ inline Vec4B Color::v4fToByte(Vec4F const& f, bool doClamp) {
}
template <> struct fmt::formatter<Star::Color> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarCompression.hpp b/source/core/StarCompression.hpp
index ba36dc7..56dc774 100644
--- a/source/core/StarCompression.hpp
+++ b/source/core/StarCompression.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_COMPRESSION_HPP
-#define STAR_COMPRESSION_HPP
+#pragma once
#include "StarIODevice.hpp"
#include "StarString.hpp"
@@ -55,5 +54,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarConfig.hpp b/source/core/StarConfig.hpp
index 5a95569..fffc7da 100644
--- a/source/core/StarConfig.hpp
+++ b/source/core/StarConfig.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_CONFIG_HPP
-#define STAR_CONFIG_HPP
+#pragma once
#include "StarPch.hpp"
@@ -75,25 +74,23 @@ typedef int64_t StreamOffset;
#define STAR_CLASS(ClassName) \
class ClassName; \
- typedef std::shared_ptr<ClassName> ClassName##Ptr; \
- typedef std::shared_ptr<const ClassName> ClassName##ConstPtr; \
- typedef std::weak_ptr<ClassName> ClassName##WeakPtr; \
- typedef std::weak_ptr<const ClassName> ClassName##ConstWeakPtr; \
- typedef std::unique_ptr<ClassName> ClassName##UPtr; \
- typedef std::unique_ptr<const ClassName> ClassName##ConstUPtr
+ using ClassName##Ptr = std::shared_ptr<ClassName>; \
+ using ClassName##ConstPtr = std::shared_ptr<const ClassName>; \
+ using ClassName##WeakPtr = std::weak_ptr<ClassName>; \
+ using ClassName##ConstWeakPtr = std::weak_ptr<const ClassName>; \
+ using ClassName##UPtr = std::unique_ptr<ClassName>; \
+ using ClassName##ConstUPtr = std::unique_ptr<const ClassName>
#define STAR_STRUCT(StructName) \
struct StructName; \
- typedef std::shared_ptr<StructName> StructName##Ptr; \
- typedef std::shared_ptr<const StructName> StructName##ConstPtr; \
- typedef std::weak_ptr<StructName> StructName##WeakPtr; \
- typedef std::weak_ptr<const StructName> StructName##ConstWeakPtr; \
- typedef std::unique_ptr<StructName> StructName##UPtr; \
- typedef std::unique_ptr<const StructName> StructName##ConstUPtr
+ using StructName##Ptr = std::shared_ptr<StructName>; \
+ using StructName##ConstPtr = std::shared_ptr<const StructName>; \
+ using StructName##WeakPtr = std::weak_ptr<StructName>; \
+ using StructName##ConstWeakPtr = std::weak_ptr<const StructName>; \
+ using StructName##UPtr = std::unique_ptr<StructName>; \
+ using StructName##ConstUPtr = std::unique_ptr<const StructName>
#define STAR_QUOTE(name) #name
#define STAR_STR(macro) STAR_QUOTE(macro)
}
-
-#endif
diff --git a/source/core/StarCurve25519.hpp b/source/core/StarCurve25519.hpp
index 15fe4d1..d1eac1c 100644
--- a/source/core/StarCurve25519.hpp
+++ b/source/core/StarCurve25519.hpp
@@ -1,5 +1,5 @@
-#ifndef STAR_CURVE_25519_HPP
-#define STAR_CURVE_25519_HPP
+#pragma once
+
#include "StarEncode.hpp"
#include "StarByteArray.hpp"
#include "StarArray.hpp"
@@ -21,5 +21,3 @@ Signature sign(void* data, size_t len);
bool verify(uint8_t const* signature, uint8_t const* publicKey, void* data, size_t len);
}
-
-#endif \ No newline at end of file
diff --git a/source/core/StarDataStream.hpp b/source/core/StarDataStream.hpp
index c8cd805..02cb922 100644
--- a/source/core/StarDataStream.hpp
+++ b/source/core/StarDataStream.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_DATA_STREAM_HPP
-#define STAR_DATA_STREAM_HPP
+#pragma once
#include "StarString.hpp"
@@ -389,5 +388,3 @@ void DataStream::readMapContainer(Container& container) {
}
}
-
-#endif
diff --git a/source/core/StarDataStreamDevices.hpp b/source/core/StarDataStreamDevices.hpp
index cec315e..dce7dcf 100644
--- a/source/core/StarDataStreamDevices.hpp
+++ b/source/core/StarDataStreamDevices.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_DATA_STREAM_BUFFER_HPP
-#define STAR_DATA_STREAM_BUFFER_HPP
+#pragma once
#include "StarBuffer.hpp"
#include "StarDataStream.hpp"
@@ -248,5 +247,3 @@ T DataStreamBuffer::deserializeMapContainer(ByteArray data, ReadFunction readFun
}
}
-
-#endif
diff --git a/source/core/StarDataStreamExtra.hpp b/source/core/StarDataStreamExtra.hpp
index 3c8565a..d8a5091 100644
--- a/source/core/StarDataStreamExtra.hpp
+++ b/source/core/StarDataStreamExtra.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_DATA_STREAM_EXTRA_HPP
-#define STAR_DATA_STREAM_EXTRA_HPP
+#pragma once
#include "StarDataStream.hpp"
#include "StarMultiArray.hpp"
@@ -389,5 +388,3 @@ DataStream& operator<<(DataStream& ds, tuple<T...> const& t) {
}
}
-
-#endif
diff --git a/source/core/StarDirectives.hpp b/source/core/StarDirectives.hpp
index b7575ed..ec43b9d 100644
--- a/source/core/StarDirectives.hpp
+++ b/source/core/StarDirectives.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_DIRECTIVES_HPP
-#define STAR_DIRECTIVES_HPP
+#pragma once
#include "StarImageProcessing.hpp"
#include "StarHash.hpp"
@@ -122,5 +121,3 @@ struct hash<DirectivesGroup> {
typedef DirectivesGroup ImageDirectives;
}
-
-#endif
diff --git a/source/core/StarDynamicLib.hpp b/source/core/StarDynamicLib.hpp
index c479d8b..4795786 100644
--- a/source/core/StarDynamicLib.hpp
+++ b/source/core/StarDynamicLib.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_PLATFORM_HPP
-#define STAR_PLATFORM_HPP
+#pragma once
#include "StarString.hpp"
@@ -34,5 +33,3 @@ inline DynamicLibUPtr DynamicLib::loadLibraryBase(String const& baseName) {
}
}
-
-#endif
diff --git a/source/core/StarEither.hpp b/source/core/StarEither.hpp
index bed6fd7..b45cd94 100644
--- a/source/core/StarEither.hpp
+++ b/source/core/StarEither.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_EITHER_HPP
-#define STAR_EITHER_HPP
+#pragma once
#include "StarVariant.hpp"
@@ -239,5 +238,3 @@ Right* Either<Left, Right>::rightPtr() {
}
}
-
-#endif
diff --git a/source/core/StarEncode.hpp b/source/core/StarEncode.hpp
index 62350ae..a69b790 100644
--- a/source/core/StarEncode.hpp
+++ b/source/core/StarEncode.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ENCODE_HPP
-#define STAR_ENCODE_HPP
+#pragma once
#include "StarString.hpp"
#include "StarByteArray.hpp"
@@ -23,5 +22,3 @@ String base64Encode(ByteArray const& data);
ByteArray base64Decode(String const& encodedData);
}
-
-#endif
diff --git a/source/core/StarException.hpp b/source/core/StarException.hpp
index 2805c9d..f9009bc 100644
--- a/source/core/StarException.hpp
+++ b/source/core/StarException.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_EXCEPTION_HPP
-#define STAR_EXCEPTION_HPP
+#pragma once
#include "StarMemory.hpp"
#include "StarOutputProxy.hpp"
@@ -103,5 +102,3 @@ StarException StarException::format(fmt::format_string<Args...> fmt, Args const&
}
}
-
-#endif
diff --git a/source/core/StarFile.hpp b/source/core/StarFile.hpp
index 517c148..fb489ab 100644
--- a/source/core/StarFile.hpp
+++ b/source/core/StarFile.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_FILE_HPP
-#define STAR_FILE_HPP
+#pragma once
#include "StarIODevice.hpp"
#include "StarString.hpp"
@@ -146,5 +145,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarFlatHashMap.hpp b/source/core/StarFlatHashMap.hpp
index 7fd21ff..091844d 100644
--- a/source/core/StarFlatHashMap.hpp
+++ b/source/core/StarFlatHashMap.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_FLAT_HASH_MAP_HPP
-#define STAR_FLAT_HASH_MAP_HPP
+#pragma once
#include <type_traits>
@@ -541,5 +540,3 @@ bool FlatHashMap<Key, Mapped, Hash, Equals, Allocator>::operator!=(FlatHashMap c
}
}
-
-#endif
diff --git a/source/core/StarFlatHashSet.hpp b/source/core/StarFlatHashSet.hpp
index 51d01f7..350b03a 100644
--- a/source/core/StarFlatHashSet.hpp
+++ b/source/core/StarFlatHashSet.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_FLAT_HASH_SET_HPP
-#define STAR_FLAT_HASH_SET_HPP
+#pragma once
#include "StarFlatHashTable.hpp"
#include "StarHash.hpp"
@@ -493,5 +492,3 @@ bool FlatHashSet<Key, Hash, Equals, Allocator>::operator!=(FlatHashSet const& rh
}
}
-
-#endif
diff --git a/source/core/StarFlatHashTable.hpp b/source/core/StarFlatHashTable.hpp
index 793c573..9b9248b 100644
--- a/source/core/StarFlatHashTable.hpp
+++ b/source/core/StarFlatHashTable.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_FLAT_HASH_TABLE_HPP
-#define STAR_FLAT_HASH_TABLE_HPP
+#pragma once
#include <vector>
@@ -553,5 +552,3 @@ void FlatHashTable<Value, Key, GetKey, Hash, Equals, Allocator>::checkCapacity(s
}
}
-
-#endif
diff --git a/source/core/StarFont.hpp b/source/core/StarFont.hpp
index a3b3ced..1fa5c8c 100644
--- a/source/core/StarFont.hpp
+++ b/source/core/StarFont.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_FONT_HPP
-#define STAR_FONT_HPP
+#pragma once
#include "StarString.hpp"
#include "StarImage.hpp"
@@ -47,5 +46,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarFormat.hpp b/source/core/StarFormat.hpp
index f159928..5f9754a 100644
--- a/source/core/StarFormat.hpp
+++ b/source/core/StarFormat.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_FORMAT_HPP
-#define STAR_FORMAT_HPP
+#pragma once
#include "StarMemory.hpp"
#include "StarException.hpp"
@@ -46,5 +45,3 @@ inline std::string toString(Type const& t) {
}
}
-
-#endif
diff --git a/source/core/StarFormattedJson.hpp b/source/core/StarFormattedJson.hpp
index df94523..f7e6b11 100644
--- a/source/core/StarFormattedJson.hpp
+++ b/source/core/StarFormattedJson.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_JSON_COMMENTS_HPP
-#define STAR_JSON_COMMENTS_HPP
+#pragma once
#include <list>
@@ -131,5 +130,3 @@ std::ostream& operator<<(std::ostream& os, FormattedJson const& json);
}
template <> struct fmt::formatter<Star::FormattedJson> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarHash.hpp b/source/core/StarHash.hpp
index 7ad942f..52e2fc3 100644
--- a/source/core/StarHash.hpp
+++ b/source/core/StarHash.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_HASH_HPP
-#define STAR_HASH_HPP
+#pragma once
#include "StarBytes.hpp"
@@ -96,5 +95,3 @@ size_t hashOf(T1 const& t1, T2 const& t2, TL const&... rest) {
};
}
-
-#endif
diff --git a/source/core/StarHostAddress.hpp b/source/core/StarHostAddress.hpp
index 6948b0e..07f27a9 100644
--- a/source/core/StarHostAddress.hpp
+++ b/source/core/StarHostAddress.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_HOST_ADDRESS_HPP
-#define STAR_HOST_ADDRESS_HPP
+#pragma once
#include "StarString.hpp"
#include "StarEither.hpp"
@@ -88,5 +87,3 @@ struct hash<HostAddressWithPort> {
template <> struct fmt::formatter<Star::HostAddress> : ostream_formatter {};
template <> struct fmt::formatter<Star::HostAddressWithPort> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarIODevice.hpp b/source/core/StarIODevice.hpp
index 834b1d4..b375e81 100644
--- a/source/core/StarIODevice.hpp
+++ b/source/core/StarIODevice.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_IO_DEVICE_H
-#define STAR_IO_DEVICE_H
+#pragma once
#include "StarByteArray.hpp"
#include "StarString.hpp"
@@ -129,5 +128,3 @@ inline bool IODevice::isWritable() const {
}
}
-
-#endif
diff --git a/source/core/StarIdMap.hpp b/source/core/StarIdMap.hpp
index 964b899..7f13b40 100644
--- a/source/core/StarIdMap.hpp
+++ b/source/core/StarIdMap.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ID_MAP_HPP
-#define STAR_ID_MAP_HPP
+#pragma once
#include "StarMap.hpp"
#include "StarMathCommon.hpp"
@@ -147,5 +146,3 @@ DataStream& operator<<(DataStream& ds, IdMapWrapper<BaseMap> const& map) {
}
}
-
-#endif
diff --git a/source/core/StarImage.hpp b/source/core/StarImage.hpp
index cce0d2f..6f186df 100644
--- a/source/core/StarImage.hpp
+++ b/source/core/StarImage.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_IMAGE_HPP
-#define STAR_IMAGE_HPP
+#pragma once
#include "StarString.hpp"
#include "StarVector.hpp"
@@ -309,5 +308,3 @@ void Image::forEachPixel(CallbackType&& callback) {
}
}
-
-#endif
diff --git a/source/core/StarImageProcessing.hpp b/source/core/StarImageProcessing.hpp
index ed3319b..71ce6fc 100644
--- a/source/core/StarImageProcessing.hpp
+++ b/source/core/StarImageProcessing.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_IMAGE_PROCESSING_HPP
-#define STAR_IMAGE_PROCESSING_HPP
+#pragma once
#include "StarList.hpp"
#include "StarRect.hpp"
@@ -164,5 +163,3 @@ void processImageOperation(ImageOperation const& operation, Image& input, ImageR
Image processImageOperations(List<ImageOperation> const& operations, Image input, ImageReferenceCallback refCallback = {});
}
-
-#endif
diff --git a/source/core/StarInputEvent.hpp b/source/core/StarInputEvent.hpp
index 896b192..fefca1b 100644
--- a/source/core/StarInputEvent.hpp
+++ b/source/core/StarInputEvent.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_INPUT_EVENT_HPP
-#define STAR_INPUT_EVENT_HPP
+#pragma once
#include "StarString.hpp"
#include "StarBiMap.hpp"
@@ -308,5 +307,3 @@ inline KeyMod& operator&=(KeyMod& a, KeyMod b) {
}
}
-
-#endif
diff --git a/source/core/StarInterpolation.hpp b/source/core/StarInterpolation.hpp
index 426f37d..fb991d6 100644
--- a/source/core/StarInterpolation.hpp
+++ b/source/core/StarInterpolation.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_INTERPOLATE_BASE
-#define STAR_INTERPOLATE_BASE
+#pragma once
#include "StarMathCommon.hpp"
#include "StarArray.hpp"
@@ -450,5 +449,3 @@ typename YContainer::value_type parametricInterpolate4(XContainer const& xvals,
}
}
-
-#endif
diff --git a/source/core/StarIterator.hpp b/source/core/StarIterator.hpp
index 389740a..fd7853c 100644
--- a/source/core/StarIterator.hpp
+++ b/source/core/StarIterator.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ITERATOR_H
-#define STAR_ITERATOR_H
+#pragma once
#include <algorithm>
@@ -433,5 +432,3 @@ SMutableMapIterator<Container> makeSMutableMapIterator(Container& c) {
}
}
-
-#endif
diff --git a/source/core/StarJson.hpp b/source/core/StarJson.hpp
index 19f390e..4aa6f7b 100644
--- a/source/core/StarJson.hpp
+++ b/source/core/StarJson.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_JSON_HPP
-#define STAR_JSON_HPP
+#pragma once
#include "StarDataStream.hpp"
#include "StarVariant.hpp"
@@ -360,5 +359,3 @@ Json jsonMergeQueryDef(String const& key, Json def, Json const& first, T const&.
template <> struct fmt::formatter<Star::Json> : ostream_formatter {};
template <> struct fmt::formatter<Star::JsonObject> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarJsonBuilder.hpp b/source/core/StarJsonBuilder.hpp
index 6be9e54..ea0df46 100644
--- a/source/core/StarJsonBuilder.hpp
+++ b/source/core/StarJsonBuilder.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_JSON_BUILDER_HPP
-#define STAR_JSON_BUILDER_HPP
+#pragma once
#include "StarJsonParser.hpp"
#include "StarJson.hpp"
@@ -100,5 +99,3 @@ void outputUtf32Json(Jsonlike const& val, OutputIterator out, int pretty, bool s
}
}
-
-#endif
diff --git a/source/core/StarJsonExtra.hpp b/source/core/StarJsonExtra.hpp
index 98de98b..2a0ca28 100644
--- a/source/core/StarJsonExtra.hpp
+++ b/source/core/StarJsonExtra.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_JSON_EXTRA_HPP
-#define STAR_JSON_EXTRA_HPP
+#pragma once
#include "StarJson.hpp"
#include "StarPoly.hpp"
@@ -383,5 +382,3 @@ Polygon<Float> fixInsideOutPoly(Polygon<Float> p) {
}
}
-
-#endif
diff --git a/source/core/StarJsonParser.hpp b/source/core/StarJsonParser.hpp
index 522f434..91d93bb 100644
--- a/source/core/StarJsonParser.hpp
+++ b/source/core/StarJsonParser.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_JSON_PARSER_HPP
-#define STAR_JSON_PARSER_HPP
+#pragma once
#include <vector>
@@ -730,5 +729,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarJsonPatch.hpp b/source/core/StarJsonPatch.hpp
index 1cf689c..bd331c4 100644
--- a/source/core/StarJsonPatch.hpp
+++ b/source/core/StarJsonPatch.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_JSON_PATCH_HPP
-#define STAR_JSON_PATCH_HPP
+#pragma once
#include "StarJson.hpp"
@@ -37,5 +36,3 @@ namespace JsonPatching {
}
}
-
-#endif
diff --git a/source/core/StarJsonPath.hpp b/source/core/StarJsonPath.hpp
index bd60dad..e1f758b 100644
--- a/source/core/StarJsonPath.hpp
+++ b/source/core/StarJsonPath.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_JSON_PATH_HPP
-#define STAR_JSON_PATH_HPP
+#pragma once
#include "StarLexicalCast.hpp"
#include "StarJson.hpp"
@@ -328,5 +327,3 @@ namespace JsonPath {
}
}
-
-#endif
diff --git a/source/core/StarJsonRpc.hpp b/source/core/StarJsonRpc.hpp
index 651e717..b767703 100644
--- a/source/core/StarJsonRpc.hpp
+++ b/source/core/StarJsonRpc.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_JSON_RPC_HPP
-#define STAR_JSON_RPC_HPP
+#pragma once
#include "StarJson.hpp"
#include "StarByteArray.hpp"
@@ -50,5 +49,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarLexicalCast.hpp b/source/core/StarLexicalCast.hpp
index 7c43137..9c671e9 100644
--- a/source/core/StarLexicalCast.hpp
+++ b/source/core/StarLexicalCast.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LEXICAL_CAST_HPP
-#define STAR_LEXICAL_CAST_HPP
+#pragma once
#include "StarFormat.hpp"
#include "StarString.hpp"
@@ -43,5 +42,3 @@ Type lexicalCast(StringView s, std::ios_base::fmtflags flags = std::ios_base::bo
}
}
-
-#endif
diff --git a/source/core/StarLine.hpp b/source/core/StarLine.hpp
index 2ca8cdd..30c1705 100644
--- a/source/core/StarLine.hpp
+++ b/source/core/StarLine.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LINE_HPP
-#define STAR_LINE_HPP
+#pragma once
#include "StarMatrix3.hpp"
@@ -288,5 +287,3 @@ struct hash<Line<T, N>> {
template <typename T, size_t N>
struct fmt::formatter<Star::Line<T, N>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarList.hpp b/source/core/StarList.hpp
index cf7c6a6..1637dea 100644
--- a/source/core/StarList.hpp
+++ b/source/core/StarList.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LIST_HPP
-#define STAR_LIST_HPP
+#pragma once
#include <vector>
#include <deque>
@@ -1137,5 +1136,3 @@ typename ListEnumerateTypes<Container>::Result enumerate(Container&& container)
template <typename BaseList>
struct fmt::formatter<Star::ListMixin<BaseList>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarListener.hpp b/source/core/StarListener.hpp
index 51a8237..6c38e37 100644
--- a/source/core/StarListener.hpp
+++ b/source/core/StarListener.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LISTENER_HPP
-#define STAR_LISTENER_HPP
+#pragma once
#include "StarThread.hpp"
@@ -63,5 +62,3 @@ inline void TrackerListener::trigger() {
}
}
-
-#endif
diff --git a/source/core/StarLockFile.hpp b/source/core/StarLockFile.hpp
index af89c7f..a836cee 100644
--- a/source/core/StarLockFile.hpp
+++ b/source/core/StarLockFile.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LOCK_FILE_HPP
-#define STAR_LOCK_FILE_HPP
+#pragma once
#include "StarMaybe.hpp"
#include "StarString.hpp"
@@ -38,5 +37,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarLogging.hpp b/source/core/StarLogging.hpp
index 6e909fb..4f93d8a 100644
--- a/source/core/StarLogging.hpp
+++ b/source/core/StarLogging.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LOGGING_HPP
-#define STAR_LOGGING_HPP
+#pragma once
#include "StarThread.hpp"
#include "StarSet.hpp"
@@ -197,5 +196,3 @@ void LogMap::set(String const& key, T const& t) {
}
}
-
-#endif
diff --git a/source/core/StarLruCache.hpp b/source/core/StarLruCache.hpp
index a59ed03..c4cde0f 100644
--- a/source/core/StarLruCache.hpp
+++ b/source/core/StarLruCache.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LRU_CACHE_HPP
-#define STAR_LRU_CACHE_HPP
+#pragma once
#include "StarOrderedMap.hpp"
#include "StarBlockAllocator.hpp"
@@ -145,5 +144,3 @@ void LruCacheBase<OrderedMapType>::clear() {
}
}
-
-#endif
diff --git a/source/core/StarLua.hpp b/source/core/StarLua.hpp
index d138c8b..84fc256 100644
--- a/source/core/StarLua.hpp
+++ b/source/core/StarLua.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LUA_HPP
-#define STAR_LUA_HPP
+#pragma once
#include <typeindex>
#include <type_traits>
@@ -2224,5 +2223,3 @@ size_t LuaEngine::pushArguments(lua_State* state, Args const&... args) {
}
template <> struct fmt::formatter<Star::LuaValue> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarLuaConverters.hpp b/source/core/StarLuaConverters.hpp
index 277f691..d9dfc67 100644
--- a/source/core/StarLuaConverters.hpp
+++ b/source/core/StarLuaConverters.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_LUA_CONVERTERS_HPP
-#define STAR_LUA_CONVERTERS_HPP
+#pragma once
#include "StarRect.hpp"
#include "StarVector.hpp"
@@ -284,5 +283,3 @@ struct LuaConverter<LuaCallbacks> {
};
}
-
-#endif
diff --git a/source/core/StarMap.hpp b/source/core/StarMap.hpp
index 187f4cf..b50add2 100644
--- a/source/core/StarMap.hpp
+++ b/source/core/StarMap.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_MAP_HPP
-#define STAR_MAP_HPP
+#pragma once
#include <map>
#include <unordered_map>
@@ -317,5 +316,3 @@ std::ostream& operator<<(std::ostream& os, MapMixin<BaseMap> const& m) {
template <typename BaseMap>
struct fmt::formatter<Star::MapMixin<BaseMap>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarMathCommon.hpp b/source/core/StarMathCommon.hpp
index 27d2976..1627edb 100644
--- a/source/core/StarMathCommon.hpp
+++ b/source/core/StarMathCommon.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_MATH_COMMON_HPP
-#define STAR_MATH_COMMON_HPP
+#pragma once
#include <type_traits>
#include <limits>
@@ -324,5 +323,3 @@ Integer cycleIncrement(Integer val, Integer min, Integer max) {
}
}
-
-#endif
diff --git a/source/core/StarMatrix3.hpp b/source/core/StarMatrix3.hpp
index 3fb8162..04d8005 100644
--- a/source/core/StarMatrix3.hpp
+++ b/source/core/StarMatrix3.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_MATRIX3_HPP
-#define STAR_MATRIX3_HPP
+#pragma once
#include "StarVector.hpp"
@@ -455,5 +454,3 @@ std::ostream& operator<<(std::ostream& os, Matrix3<T> m) {
template <typename T>
struct fmt::formatter<Star::Matrix3<T>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarMaybe.hpp b/source/core/StarMaybe.hpp
index 2c53bcb..9576ee6 100644
--- a/source/core/StarMaybe.hpp
+++ b/source/core/StarMaybe.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_MAYBE_HPP
-#define STAR_MAYBE_HPP
+#pragma once
#include "StarException.hpp"
#include "StarHash.hpp"
@@ -399,5 +398,3 @@ size_t hash<Maybe<T>>::operator()(Maybe<T> const& m) const {
template <typename T>
struct fmt::formatter<Star::Maybe<T>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarMemory.hpp b/source/core/StarMemory.hpp
index a75ee20..b498e27 100644
--- a/source/core/StarMemory.hpp
+++ b/source/core/StarMemory.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_MEMORY_HPP
-#define STAR_MEMORY_HPP
+#pragma once
#include <new>
@@ -16,5 +15,3 @@ void free(void* ptr);
void free(void* ptr, size_t size);
}
-
-#endif
diff --git a/source/core/StarMultiArray.hpp b/source/core/StarMultiArray.hpp
index bb33490..057653e 100644
--- a/source/core/StarMultiArray.hpp
+++ b/source/core/StarMultiArray.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_MULTI_ARRAY_HPP
-#define STAR_MULTI_ARRAY_HPP
+#pragma once
#include "StarArray.hpp"
#include "StarList.hpp"
@@ -509,5 +508,3 @@ std::ostream& operator<<(std::ostream& os, MultiArray<Element, Rank> const& arra
template <typename Element, size_t Rank>
struct fmt::formatter<Star::MultiArray<Element, Rank>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarMultiArrayInterpolator.hpp b/source/core/StarMultiArrayInterpolator.hpp
index 40a708d..93cdcc5 100644
--- a/source/core/StarMultiArrayInterpolator.hpp
+++ b/source/core/StarMultiArrayInterpolator.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_MULTI_ARRAY_INTERPOLATOR_HPP
-#define STAR_MULTI_ARRAY_INTERPOLATOR_HPP
+#pragma once
#include "StarMultiArray.hpp"
#include "StarInterpolation.hpp"
@@ -535,5 +534,3 @@ struct MultiArrayInterpolator4<MultiArray<ElementT, 3>, PositionT> {
};
}
-
-#endif
diff --git a/source/core/StarMultiTable.hpp b/source/core/StarMultiTable.hpp
index 3a44634..ca00de4 100644
--- a/source/core/StarMultiTable.hpp
+++ b/source/core/StarMultiTable.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_MULTI_TABLE_HPP
-#define STAR_MULTI_TABLE_HPP
+#pragma once
#include "StarMultiArrayInterpolator.hpp"
@@ -165,5 +164,3 @@ typedef MultiTable<float, float, 4> MultiTable4F;
typedef MultiTable<double, double, 4> MultiTable4D;
}
-
-#endif
diff --git a/source/core/StarNetElement.hpp b/source/core/StarNetElement.hpp
index 5d21fe3..dd909b8 100644
--- a/source/core/StarNetElement.hpp
+++ b/source/core/StarNetElement.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_ELEMENT_HPP
-#define STAR_NET_ELEMENT_HPP
+#pragma once
#include "StarDataStream.hpp"
@@ -58,5 +57,3 @@ public:
};
}
-
-#endif
diff --git a/source/core/StarNetElementBasicFields.hpp b/source/core/StarNetElementBasicFields.hpp
index 2d9f8e5..693c6c3 100644
--- a/source/core/StarNetElementBasicFields.hpp
+++ b/source/core/StarNetElementBasicFields.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_STEP_STATES_HPP
-#define STAR_NET_STEP_STATES_HPP
+#pragma once
#include <type_traits>
@@ -327,5 +326,3 @@ void NetElementData<T>::writeData(DataStream& ds, T const& v) const {
}
}
-
-#endif
diff --git a/source/core/StarNetElementContainers.hpp b/source/core/StarNetElementContainers.hpp
index b48755d..62cce86 100644
--- a/source/core/StarNetElementContainers.hpp
+++ b/source/core/StarNetElementContainers.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_ELEMENT_CONTAINERS_HPP
-#define STAR_NET_ELEMENT_CONTAINERS_HPP
+#pragma once
#include "StarMap.hpp"
#include "StarDataStreamExtra.hpp"
@@ -448,5 +447,3 @@ void NetElementMapWrapper<BaseMap>::applyChange(ElementChange change) {
}
}
-
-#endif
diff --git a/source/core/StarNetElementDynamicGroup.hpp b/source/core/StarNetElementDynamicGroup.hpp
index 75d11c8..4f3a2d3 100644
--- a/source/core/StarNetElementDynamicGroup.hpp
+++ b/source/core/StarNetElementDynamicGroup.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_ELEMENT_DYNAMIC_GROUP_HPP
-#define STAR_NET_ELEMENT_DYNAMIC_GROUP_HPP
+#pragma once
#include "StarNetElement.hpp"
#include "StarIdMap.hpp"
@@ -313,5 +312,3 @@ void NetElementDynamicGroup<Element>::readyElement(ElementPtr const& element) {
}
}
-
-#endif
diff --git a/source/core/StarNetElementFloatFields.hpp b/source/core/StarNetElementFloatFields.hpp
index 20895cd..57f74a9 100644
--- a/source/core/StarNetElementFloatFields.hpp
+++ b/source/core/StarNetElementFloatFields.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_ELEMENT_FLOAT_FIELDS_HPP
-#define STAR_NET_ELEMENT_FLOAT_FIELDS_HPP
+#pragma once
#include <type_traits>
@@ -242,5 +241,3 @@ T NetElementFloating<T>::interpolate() const {
}
}
-
-#endif
diff --git a/source/core/StarNetElementGroup.hpp b/source/core/StarNetElementGroup.hpp
index d583818..fd1bf58 100644
--- a/source/core/StarNetElementGroup.hpp
+++ b/source/core/StarNetElementGroup.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_ELEMENT_GROUP_HPP
-#define STAR_NET_ELEMENT_GROUP_HPP
+#pragma once
#include "StarSet.hpp"
#include "StarNetElement.hpp"
@@ -62,5 +61,3 @@ inline float NetElementGroup::netExtrapolationHint() const {
}
}
-
-#endif
diff --git a/source/core/StarNetElementSignal.hpp b/source/core/StarNetElementSignal.hpp
index 03a2586..9faa127 100644
--- a/source/core/StarNetElementSignal.hpp
+++ b/source/core/StarNetElementSignal.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_ELEMENT_SIGNAL_HPP
-#define STAR_NET_ELEMENT_SIGNAL_HPP
+#pragma once
#include "StarNetElement.hpp"
@@ -141,5 +140,3 @@ List<Signal> NetElementSignal<Signal>::receive() {
}
}
-
-#endif
diff --git a/source/core/StarNetElementSyncGroup.hpp b/source/core/StarNetElementSyncGroup.hpp
index 2162ebe..b01200b 100644
--- a/source/core/StarNetElementSyncGroup.hpp
+++ b/source/core/StarNetElementSyncGroup.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_ELEMENT_SYNC_GROUP_HPP
-#define STAR_NET_ELEMENT_SYNC_GROUP_HPP
+#pragma once
#include "StarNetElementGroup.hpp"
@@ -50,5 +49,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarNetElementSystem.hpp b/source/core/StarNetElementSystem.hpp
index d5a3560..c651de7 100644
--- a/source/core/StarNetElementSystem.hpp
+++ b/source/core/StarNetElementSystem.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_NET_ELEMENT_SYSTEM_HPP
-#define STAR_NET_ELEMENT_SYSTEM_HPP
+#pragma once
#include "StarNetElementBasicFields.hpp"
#include "StarNetElementFloatFields.hpp"
@@ -15,5 +14,3 @@ namespace Star {
typedef NetElementTop<NetElementCallbackGroup> NetElementTopGroup;
}
-
-#endif
diff --git a/source/core/StarNetImpl.hpp b/source/core/StarNetImpl.hpp
index 076b181..a84da6d 100644
--- a/source/core/StarNetImpl.hpp
+++ b/source/core/StarNetImpl.hpp
@@ -1,3 +1,5 @@
+#pragma once
+
#ifdef STAR_SYSTEM_FAMILY_WINDOWS
#include <winsock2.h>
#include <ws2tcpip.h>
diff --git a/source/core/StarObserverStream.hpp b/source/core/StarObserverStream.hpp
index 61c4f91..f78f07f 100644
--- a/source/core/StarObserverStream.hpp
+++ b/source/core/StarObserverStream.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_OBSERVER_STREAM_HPP
-#define STAR_OBSERVER_STREAM_HPP
+#pragma once
#include "StarList.hpp"
@@ -94,5 +93,3 @@ void ObserverStream<T>::reset() {
}
}
-
-#endif
diff --git a/source/core/StarOptionParser.hpp b/source/core/StarOptionParser.hpp
index b17b040..946724c 100644
--- a/source/core/StarOptionParser.hpp
+++ b/source/core/StarOptionParser.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_OPTION_PARSER_HPP
-#define STAR_OPTION_PARSER_HPP
+#pragma once
#include "StarString.hpp"
#include "StarVariant.hpp"
@@ -80,5 +79,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarOrderedMap.hpp b/source/core/StarOrderedMap.hpp
index 50482bf..11d1b78 100644
--- a/source/core/StarOrderedMap.hpp
+++ b/source/core/StarOrderedMap.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ORDERED_MAP_HPP
-#define STAR_ORDERED_MAP_HPP
+#pragma once
#include "StarMap.hpp"
@@ -656,5 +655,3 @@ std::ostream& operator<<(std::ostream& os, OrderedMapWrapper<Map, Key, Value, Al
template <template <typename...> class Map, typename Key, typename Value, typename Allocator, typename... MapArgs>
struct fmt::formatter<Star::OrderedMapWrapper<Map, Key, Value, Allocator, MapArgs...>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarOrderedSet.hpp b/source/core/StarOrderedSet.hpp
index 4645a38..b9ebc58 100644
--- a/source/core/StarOrderedSet.hpp
+++ b/source/core/StarOrderedSet.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_ORDERED_SET_HPP
-#define STAR_ORDERED_SET_HPP
+#pragma once
#include <map>
@@ -429,5 +428,3 @@ std::ostream& operator<<(std::ostream& os, OrderedSetWrapper<Map, Value, Allocat
template <template <typename...> class Map, typename Value, typename Allocator, typename... Args>
struct fmt::formatter<Star::OrderedSetWrapper<Map, Value, Allocator, Args...>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarOutputProxy.hpp b/source/core/StarOutputProxy.hpp
index d8761fa..bd8be65 100644
--- a/source/core/StarOutputProxy.hpp
+++ b/source/core/StarOutputProxy.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_OUTPUT_PROXY_HPP
-#define STAR_OUTPUT_PROXY_HPP
+#pragma once
#include "StarMemory.hpp"
@@ -64,5 +63,3 @@ inline std::ostream& operator<<(std::ostream& os, OutputProxy const& p) {
template <typename T>
struct fmt::formatter<Star::OutputAnyDetail::Wrapper<T>> : ostream_formatter {};
template <> struct fmt::formatter<Star::OutputProxy> : ostream_formatter {};
-
-#endif \ No newline at end of file
diff --git a/source/core/StarParametricFunction.hpp b/source/core/StarParametricFunction.hpp
index 64bede2..b4e6d32 100644
--- a/source/core/StarParametricFunction.hpp
+++ b/source/core/StarParametricFunction.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_PARAMETRIC_FUNCTION_HPP
-#define STAR_PARAMETRIC_FUNCTION_HPP
+#pragma once
#include "StarInterpolation.hpp"
@@ -284,5 +283,3 @@ ValueType ParametricFunction<IndexType, ValueType>::operator()(IndexType index)
}
}
-
-#endif
diff --git a/source/core/StarPch.hpp b/source/core/StarPch.hpp
index 7757a41..6837f14 100644
--- a/source/core/StarPch.hpp
+++ b/source/core/StarPch.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_PCH_HPP
-#define STAR_PCH_HPP
+#pragma once
#include <cstdint>
#include <cstdlib>
@@ -21,6 +20,3 @@
#include <iterator>
#include <type_traits>
#include <vector>
-
-
-#endif \ No newline at end of file
diff --git a/source/core/StarPeriodic.hpp b/source/core/StarPeriodic.hpp
index 2cf24cc..4940c1d 100644
--- a/source/core/StarPeriodic.hpp
+++ b/source/core/StarPeriodic.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_PERIODIC_HPP
-#define STAR_PERIODIC_HPP
+#pragma once
#include "StarMathCommon.hpp"
#include "StarRandom.hpp"
@@ -94,5 +93,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarPeriodicFunction.hpp b/source/core/StarPeriodicFunction.hpp
index ee74808..cb9e444 100644
--- a/source/core/StarPeriodicFunction.hpp
+++ b/source/core/StarPeriodicFunction.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_PERIODIC_FUNCTION_HPP
-#define STAR_PERIODIC_FUNCTION_HPP
+#pragma once
#include "StarInterpolation.hpp"
#include "StarRandom.hpp"
@@ -78,5 +77,3 @@ Float PeriodicFunction<Float>::value(WeightOperator weightOperator) const {
}
}
-
-#endif
diff --git a/source/core/StarPerlin.hpp b/source/core/StarPerlin.hpp
index 294f80f..e3ed68a 100644
--- a/source/core/StarPerlin.hpp
+++ b/source/core/StarPerlin.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_PERLIN_HPP
-#define STAR_PERLIN_HPP
+#pragma once
#include "StarJson.hpp"
#include "StarBiMap.hpp"
@@ -714,5 +713,3 @@ inline Float Perlin<Float>::billow(Float x, Float y, Float z) const {
}
}
-
-#endif
diff --git a/source/core/StarPoly.hpp b/source/core/StarPoly.hpp
index 806b495..8dc2c19 100644
--- a/source/core/StarPoly.hpp
+++ b/source/core/StarPoly.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_POLY_HPP
-#define STAR_POLY_HPP
+#pragma once
#include <numeric>
@@ -746,5 +745,3 @@ std::ostream& operator<<(std::ostream& os, Polygon<DataType> const& poly) {
}
}
-
-#endif
diff --git a/source/core/StarPythonic.hpp b/source/core/StarPythonic.hpp
index 0131130..a5f76dc 100644
--- a/source/core/StarPythonic.hpp
+++ b/source/core/StarPythonic.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_PYTHONIC_HPP
-#define STAR_PYTHONIC_HPP
+#pragma once
#include "StarAlgorithm.hpp"
@@ -605,5 +604,3 @@ ResultContainer enumerateConstruct(Iterable&& list) {
}
}
-
-#endif
diff --git a/source/core/StarRandom.hpp b/source/core/StarRandom.hpp
index c39f6ef..a67a2c5 100644
--- a/source/core/StarRandom.hpp
+++ b/source/core/StarRandom.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_RANDOM_HPP
-#define STAR_RANDOM_HPP
+#pragma once
#include "StarStaticRandom.hpp"
#include "StarByteArray.hpp"
@@ -214,5 +213,3 @@ void Random::shuffle(Container& container) {
}
}
-
-#endif
diff --git a/source/core/StarRandomPoint.hpp b/source/core/StarRandomPoint.hpp
index ac9fcd9..5fa73ab 100644
--- a/source/core/StarRandomPoint.hpp
+++ b/source/core/StarRandomPoint.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_RANDOM_POINT_HPP
-#define STAR_RANDOM_POINT_HPP
+#pragma once
#include "StarRandom.hpp"
#include "StarPoly.hpp"
@@ -76,5 +75,3 @@ auto Random2dPointGenerator<PointData, DataType>::generate(Poly const& area, Poi
}
}
-
-#endif
diff --git a/source/core/StarRect.hpp b/source/core/StarRect.hpp
index 3525204..a32ba91 100644
--- a/source/core/StarRect.hpp
+++ b/source/core/StarRect.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_RECT_HPP
-#define STAR_RECT_HPP
+#pragma once
#include "StarLine.hpp"
#include "StarList.hpp"
@@ -1075,5 +1074,3 @@ auto Box<T, N>::nearestCoordTo(Coord const& c) const -> Coord {
template <typename T, size_t N>
struct fmt::formatter<Star::Box<T, N>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarRefPtr.hpp b/source/core/StarRefPtr.hpp
index 8fabcdb..6309332 100644
--- a/source/core/StarRefPtr.hpp
+++ b/source/core/StarRefPtr.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_REF_PTR_HPP
-#define STAR_REF_PTR_HPP
+#pragma once
#include "StarException.hpp"
#include "StarHash.hpp"
@@ -299,5 +298,3 @@ inline RefCounter::RefCounter()
: m_refCounter(0) {}
}
-
-#endif
diff --git a/source/core/StarRpcPromise.hpp b/source/core/StarRpcPromise.hpp
index 7a08750..f8ae47a 100644
--- a/source/core/StarRpcPromise.hpp
+++ b/source/core/StarRpcPromise.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_RPC_PROMISE_HPP
-#define STAR_RPC_PROMISE_HPP
+#pragma once
#include "StarEither.hpp"
#include "StarString.hpp"
@@ -171,5 +170,3 @@ decltype(auto) RpcPromise<Result, Error>::wrap(Function function) {
}
}
-
-#endif
diff --git a/source/core/StarRpcThreadPromise.hpp b/source/core/StarRpcThreadPromise.hpp
index 043d0e7..896d21d 100644
--- a/source/core/StarRpcThreadPromise.hpp
+++ b/source/core/StarRpcThreadPromise.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_RPC_THREAD_PROMISE_HPP
-#define STAR_RPC_THREAD_PROMISE_HPP
+#pragma once
#include "StarEither.hpp"
#include "StarString.hpp"
@@ -160,5 +159,3 @@ Maybe<Error> RpcThreadPromise<Result, Error>::error() const {
}
}
-
-#endif
diff --git a/source/core/StarSectorArray2D.hpp b/source/core/StarSectorArray2D.hpp
index 1dd88a1..0fea5b0 100644
--- a/source/core/StarSectorArray2D.hpp
+++ b/source/core/StarSectorArray2D.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SECTOR_SET_HPP
-#define STAR_SECTOR_SET_HPP
+#pragma once
#include "StarMultiArray.hpp"
#include "StarSet.hpp"
@@ -374,5 +373,3 @@ bool SectorArray2D<ElementT, SectorSize>::evalColumnsPriv(
}
}
-
-#endif
diff --git a/source/core/StarSecureRandom.hpp b/source/core/StarSecureRandom.hpp
index e4110b0..d8b9754 100644
--- a/source/core/StarSecureRandom.hpp
+++ b/source/core/StarSecureRandom.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SECURE_RANDOM_HPP
-#define STAR_SECURE_RANDOM_HPP
+#pragma once
#include "StarByteArray.hpp"
@@ -10,5 +9,3 @@ namespace Star {
ByteArray secureRandomBytes(size_t size);
}
-
-#endif
diff --git a/source/core/StarSet.hpp b/source/core/StarSet.hpp
index f32a46c..3d7af0b 100644
--- a/source/core/StarSet.hpp
+++ b/source/core/StarSet.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SET_HPP
-#define STAR_SET_HPP
+#pragma once
#include <set>
#include <unordered_set>
@@ -318,5 +317,3 @@ HashSetMixin<BaseMap> HashSetMixin<BaseMap>::combination(HashSetMixin const& s)
}
}
-
-#endif
diff --git a/source/core/StarSha256.hpp b/source/core/StarSha256.hpp
index 6a9abd4..91d2591 100644
--- a/source/core/StarSha256.hpp
+++ b/source/core/StarSha256.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SHA_256_HPP
-#define STAR_SHA_256_HPP
+#pragma once
#include "StarString.hpp"
#include "StarByteArray.hpp"
@@ -40,5 +39,3 @@ ByteArray sha256(ByteArray const& in);
ByteArray sha256(String const& in);
}
-
-#endif
diff --git a/source/core/StarShellParser.hpp b/source/core/StarShellParser.hpp
index 8e89273..b8e77d0 100644
--- a/source/core/StarShellParser.hpp
+++ b/source/core/StarShellParser.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SHELL_PARSER_HPP
-#define STAR_SHELL_PARSER_HPP
+#pragma once
#include "StarString.hpp"
#include "StarEncode.hpp"
@@ -62,5 +61,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarSignalHandler.hpp b/source/core/StarSignalHandler.hpp
index 0b70d71..6bb8381 100644
--- a/source/core/StarSignalHandler.hpp
+++ b/source/core/StarSignalHandler.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SIGNAL_HANDLER_HPP
-#define STAR_SIGNAL_HANDLER_HPP
+#pragma once
#include "StarException.hpp"
@@ -33,5 +32,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarSmallVector.hpp b/source/core/StarSmallVector.hpp
index 77dc7a5..986a3a3 100644
--- a/source/core/StarSmallVector.hpp
+++ b/source/core/StarSmallVector.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SMALL_VECTOR_HPP
-#define STAR_SMALL_VECTOR_HPP
+#pragma once
#include "StarAlgorithm.hpp"
@@ -443,5 +442,3 @@ bool SmallVector<Element, MaxStackSize>::isHeapAllocated() const {
}
}
-
-#endif
diff --git a/source/core/StarSocket.hpp b/source/core/StarSocket.hpp
index 1efe2c2..252f1ba 100644
--- a/source/core/StarSocket.hpp
+++ b/source/core/StarSocket.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SOCKET_HPP
-#define STAR_SOCKET_HPP
+#pragma once
#include "StarHostAddress.hpp"
#include "StarThread.hpp"
@@ -94,5 +93,3 @@ protected:
};
}
-
-#endif
diff --git a/source/core/StarSpatialHash2D.hpp b/source/core/StarSpatialHash2D.hpp
index 87f70e3..9534d31 100644
--- a/source/core/StarSpatialHash2D.hpp
+++ b/source/core/StarSpatialHash2D.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SPATIAL_HASH_2D_HPP
-#define STAR_SPATIAL_HASH_2D_HPP
+#pragma once
#include "StarRect.hpp"
#include "StarMap.hpp"
@@ -333,5 +332,3 @@ void SpatialHash2D<KeyT, ScalarT, ValueT, IntT, AllocatorBlockSize>::updateSpati
}
}
-
-#endif
diff --git a/source/core/StarSpline.hpp b/source/core/StarSpline.hpp
index 4656eaa..3de7a28 100644
--- a/source/core/StarSpline.hpp
+++ b/source/core/StarSpline.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_SPLINE_HPP
-#define STAR_SPLINE_HPP
+#pragma once
#include "StarVector.hpp"
#include "StarInterpolation.hpp"
@@ -154,5 +153,3 @@ protected:
typedef Spline<float, 2, 3, Vec2F> CSplineF;
}
-
-#endif
diff --git a/source/core/StarStaticRandom.hpp b/source/core/StarStaticRandom.hpp
index b55b411..1b355c4 100644
--- a/source/core/StarStaticRandom.hpp
+++ b/source/core/StarStaticRandom.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_STATIC_RANDOM_HPP
-#define STAR_STATIC_RANDOM_HPP
+#pragma once
#include "StarString.hpp"
#include "StarXXHash.hpp"
@@ -143,5 +142,3 @@ void staticRandomShuffle(Container& container, T const& d, TL const&... rest) {
}
}
-
-#endif
diff --git a/source/core/StarStaticVector.hpp b/source/core/StarStaticVector.hpp
index 91a2e41..0407400 100644
--- a/source/core/StarStaticVector.hpp
+++ b/source/core/StarStaticVector.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_STATIC_VECTOR_HPP
-#define STAR_STATIC_VECTOR_HPP
+#pragma once
#include "StarException.hpp"
#include "StarFormat.hpp"
@@ -400,5 +399,3 @@ bool StaticVector<Element, MaxSize>::operator<(StaticVector const& other) const
}
}
-
-#endif
diff --git a/source/core/StarString.hpp b/source/core/StarString.hpp
index 10f5b9f..154a4bc 100644
--- a/source/core/StarString.hpp
+++ b/source/core/StarString.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_STRING_HPP
-#define STAR_STRING_HPP
+#pragma once
#include "StarUnicode.hpp"
#include "StarHash.hpp"
@@ -522,5 +521,3 @@ StringList StringList::sorted(Comparator&& comparator) const {
template <> struct fmt::formatter<Star::String> : formatter<std::string> {
fmt::appender format(Star::String const& s, format_context& ctx) const;
};
-
-#endif
diff --git a/source/core/StarStringView.hpp b/source/core/StarStringView.hpp
index 5598d0f..1412342 100644
--- a/source/core/StarStringView.hpp
+++ b/source/core/StarStringView.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_STRING_VIEW_HPP
-#define STAR_STRING_VIEW_HPP
+#pragma once
#include "StarString.hpp"
@@ -120,5 +119,3 @@ private:
template <> struct fmt::formatter<Star::StringView> : formatter<std::string_view> {
fmt::appender format(Star::StringView const& s, format_context& ctx) const;
};
-
-#endif \ No newline at end of file
diff --git a/source/core/StarString_windows.hpp b/source/core/StarString_windows.hpp
index e681a9b..30665ba 100644
--- a/source/core/StarString_windows.hpp
+++ b/source/core/StarString_windows.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_STRING_WINDOWS_HPP
-#define STAR_STRING_WINDOWS_HPP
+#pragma once
#include <windows.h>
@@ -11,5 +10,3 @@ String utf16ToString(WCHAR const* s);
unique_ptr<WCHAR[]> stringToUtf16(String const& s);
}
-
-#endif
diff --git a/source/core/StarStrongTypedef.hpp b/source/core/StarStrongTypedef.hpp
index f5cb5ac..4ee12cd 100644
--- a/source/core/StarStrongTypedef.hpp
+++ b/source/core/StarStrongTypedef.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_STRONG_TYPEDEF_HPP
-#define STAR_STRONG_TYPEDEF_HPP
+#pragma once
#include <type_traits>
@@ -101,5 +100,3 @@
return t >= rhs.t; \
} \
}
-
-#endif
diff --git a/source/core/StarTcp.hpp b/source/core/StarTcp.hpp
index 362788e..f4b9073 100644
--- a/source/core/StarTcp.hpp
+++ b/source/core/StarTcp.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_TCP_HPP
-#define STAR_TCP_HPP
+#pragma once
#include "StarIODevice.hpp"
#include "StarSocket.hpp"
@@ -71,5 +70,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarText.hpp b/source/core/StarText.hpp
index 63034a8..4f6a97a 100644
--- a/source/core/StarText.hpp
+++ b/source/core/StarText.hpp
@@ -1,5 +1,5 @@
-#ifndef STAR_TEXT_HPP
-#define STAR_TEXT_HPP
+#pragma once
+
#include "StarString.hpp"
#include "StarStringView.hpp"
@@ -22,5 +22,3 @@ namespace Text {
}
}
-
-#endif \ No newline at end of file
diff --git a/source/core/StarThread.hpp b/source/core/StarThread.hpp
index 25d51b6..4198737 100644
--- a/source/core/StarThread.hpp
+++ b/source/core/StarThread.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_THREAD_HPP
-#define STAR_THREAD_HPP
+#pragma once
#include "StarException.hpp"
#include "StarString.hpp"
@@ -421,5 +420,3 @@ inline bool SpinLock::tryLock() {
}
}
-
-#endif
diff --git a/source/core/StarTickRateMonitor.hpp b/source/core/StarTickRateMonitor.hpp
index a50ff5e..6b5ab71 100644
--- a/source/core/StarTickRateMonitor.hpp
+++ b/source/core/StarTickRateMonitor.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_TICK_RATE_MONITOR_HPP
-#define STAR_TICK_RATE_MONITOR_HPP
+#pragma once
#include "StarList.hpp"
@@ -74,5 +73,3 @@ private:
};
};
-
-#endif
diff --git a/source/core/StarTime.hpp b/source/core/StarTime.hpp
index 0905a5d..c230a5c 100644
--- a/source/core/StarTime.hpp
+++ b/source/core/StarTime.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_TIME_HPP
-#define STAR_TIME_HPP
+#pragma once
#include "StarThread.hpp"
@@ -108,5 +107,3 @@ public:
};
}
-
-#endif
diff --git a/source/core/StarTtlCache.hpp b/source/core/StarTtlCache.hpp
index 0824880..d0ac729 100644
--- a/source/core/StarTtlCache.hpp
+++ b/source/core/StarTtlCache.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_TTL_CACHE_HPP
-#define STAR_TTL_CACHE_HPP
+#pragma once
#include "StarLruCache.hpp"
#include "StarTime.hpp"
@@ -199,5 +198,3 @@ void TtlCacheBase<LruCacheType>::cleanup(function<bool(Key const&, Value const&)
}
}
-
-#endif
diff --git a/source/core/StarUdp.hpp b/source/core/StarUdp.hpp
index 81d28a4..7dccd3a 100644
--- a/source/core/StarUdp.hpp
+++ b/source/core/StarUdp.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_UDP_HPP
-#define STAR_UDP_HPP
+#pragma once
#include "StarSocket.hpp"
@@ -37,5 +36,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarUnicode.hpp b/source/core/StarUnicode.hpp
index 9abff3e..d2aa602 100644
--- a/source/core/StarUnicode.hpp
+++ b/source/core/StarUnicode.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_UTF8_HPP
-#define STAR_UTF8_HPP
+#pragma once
#include "StarByteArray.hpp"
#include "StarMaybe.hpp"
@@ -229,5 +228,3 @@ private:
};
}
-
-#endif
diff --git a/source/core/StarUuid.hpp b/source/core/StarUuid.hpp
index 3b540fc..05e1abd 100644
--- a/source/core/StarUuid.hpp
+++ b/source/core/StarUuid.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_UUID_HPP
-#define STAR_UUID_HPP
+#pragma once
#include "StarArray.hpp"
#include "StarDataStream.hpp"
@@ -40,5 +39,3 @@ DataStream& operator>>(DataStream& ds, Uuid& uuid);
DataStream& operator<<(DataStream& ds, Uuid const& uuid);
}
-
-#endif
diff --git a/source/core/StarVariant.hpp b/source/core/StarVariant.hpp
index d70d960..049779a 100644
--- a/source/core/StarVariant.hpp
+++ b/source/core/StarVariant.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_VARIANT_HPP
-#define STAR_VARIANT_HPP
+#pragma once
#include <type_traits>
#include <utility>
@@ -943,5 +942,3 @@ void MVariant<Types...>::ConstRefCaller<Function>::operator()(T const& t) {
template <typename FirstType, typename... RestTypes>
struct fmt::formatter<Star::Variant<FirstType, RestTypes...>> : ostream_formatter {};
-
-#endif
diff --git a/source/core/StarVector.hpp b/source/core/StarVector.hpp
index 16d9d42..367c1a6 100644
--- a/source/core/StarVector.hpp
+++ b/source/core/StarVector.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_VECTOR_HPP
-#define STAR_VECTOR_HPP
+#pragma once
#include "StarArray.hpp"
#include "StarMathCommon.hpp"
@@ -920,5 +919,3 @@ T operator^(Vector<T, 2> const& v1, Vector<T, 2> const& v2) {
}
}
-
-#endif
diff --git a/source/core/StarVlqEncoding.hpp b/source/core/StarVlqEncoding.hpp
index 2139ed1..c247f11 100644
--- a/source/core/StarVlqEncoding.hpp
+++ b/source/core/StarVlqEncoding.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_VLQ_ENCODING_HPP
-#define STAR_VLQ_ENCODING_HPP
+#pragma once
#include "StarMemory.hpp"
@@ -102,5 +101,3 @@ size_t readVlqI(int64_t& v, InputIterator in, size_t maxBytes = 10) {
}
}
-
-#endif
diff --git a/source/core/StarWeightedPool.hpp b/source/core/StarWeightedPool.hpp
index ce09f40..fbd53af 100644
--- a/source/core/StarWeightedPool.hpp
+++ b/source/core/StarWeightedPool.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_WEIGHTED_POOL_HPP
-#define STAR_WEIGHTED_POOL_HPP
+#pragma once
#include "StarRandom.hpp"
@@ -192,5 +191,3 @@ size_t WeightedPool<Item>::selectIndex(double target) const {
}
}
-
-#endif
diff --git a/source/core/StarWorkerPool.hpp b/source/core/StarWorkerPool.hpp
index fcbd41c..4d07aad 100644
--- a/source/core/StarWorkerPool.hpp
+++ b/source/core/StarWorkerPool.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_WORKER_POOL_HPP
-#define STAR_WORKER_POOL_HPP
+#pragma once
#include "StarThread.hpp"
@@ -218,5 +217,3 @@ WorkerPoolPromise<ResultType> WorkerPool::addProducer(function<ResultType()> pro
}
}
-
-#endif
diff --git a/source/core/StarXXHash.hpp b/source/core/StarXXHash.hpp
index bce7566..eb29991 100644
--- a/source/core/StarXXHash.hpp
+++ b/source/core/StarXXHash.hpp
@@ -1,5 +1,4 @@
-#ifndef STAR_XXHASH_HPP
-#define STAR_XXHASH_HPP
+#pragma once
#include "StarString.hpp"
#include "StarByteArray.hpp"
@@ -204,5 +203,3 @@ inline uint64_t xxHash3(String const& in) {
return xxHash3(in.utf8Ptr(), in.utf8Size());
}
}
-
-#endif