From 33a1deb52ea71154bd7bc80bbe7794a243b41197 Mon Sep 17 00:00:00 2001 From: Tiago Macarios Date: Fri, 27 Oct 2017 01:31:14 -0700 Subject: [PATCH] Remove pragma once --- include/gsl/gsl | 8 +++----- include/gsl/gsl_algorithm | 8 +++----- include/gsl/gsl_assert | 8 +++----- include/gsl/gsl_byte | 8 +++----- include/gsl/gsl_util | 8 +++----- include/gsl/multi_span | 8 +++----- include/gsl/pointers | 8 +++----- include/gsl/span | 8 +++----- include/gsl/string_span | 8 +++----- 9 files changed, 27 insertions(+), 45 deletions(-) diff --git a/include/gsl/gsl b/include/gsl/gsl index 4f69bbf..4789e5e 100644 --- a/include/gsl/gsl +++ b/include/gsl/gsl @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_GSL_H -#define GSL_GSL_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_H +#define GUIDELINE_SUPPORT_LIBRARY_H #include // Ensures/Expects #include // finally()/narrow()/narrow_cast()... @@ -26,4 +24,4 @@ #include // zstring, string_span, zstring_builder... #include // owner, not_null -#endif // GSL_GSL_H +#endif // GUIDELINE_SUPPORT_LIBRARY_H diff --git a/include/gsl/gsl_algorithm b/include/gsl/gsl_algorithm index 88c1ff7..2e99cce 100644 --- a/include/gsl/gsl_algorithm +++ b/include/gsl/gsl_algorithm @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_ALGORITHM_H -#define GSL_ALGORITHM_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_ALGORITHM_H +#define GUIDELINE_SUPPORT_LIBRARY_ALGORITHM_H #include @@ -59,4 +57,4 @@ void copy(span src, span #pragma warning(pop) #endif // _MSC_VER -#endif // GSL_ALGORITHM_H +#endif // GUIDELINE_SUPPORT_LIBRARY_ALGORITHM_H diff --git a/include/gsl/gsl_assert b/include/gsl/gsl_assert index 43da231..9f2860f 100644 --- a/include/gsl/gsl_assert +++ b/include/gsl/gsl_assert @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_CONTRACTS_H -#define GSL_CONTRACTS_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_CONTRACTS_H +#define GUIDELINE_SUPPORT_LIBRARY_CONTRACTS_H #include #include @@ -94,4 +92,4 @@ struct fail_fast : public std::logic_error #define Expects(cond) GSL_CONTRACT_CHECK("Precondition", cond) #define Ensures(cond) GSL_CONTRACT_CHECK("Postcondition", cond) -#endif // GSL_CONTRACTS_H +#endif // GUIDELINE_SUPPORT_LIBRARY_CONTRACTS_H diff --git a/include/gsl/gsl_byte b/include/gsl/gsl_byte index 7155210..96aec4f 100644 --- a/include/gsl/gsl_byte +++ b/include/gsl/gsl_byte @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_BYTE_H -#define GSL_BYTE_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_BYTE_H +#define GUIDELINE_SUPPORT_LIBRARY_BYTE_H #include @@ -173,4 +171,4 @@ inline constexpr byte to_byte() noexcept #pragma warning(pop) #endif // _MSC_VER -#endif // GSL_BYTE_H +#endif // GUIDELINE_SUPPORT_LIBRARY_BYTE_H diff --git a/include/gsl/gsl_util b/include/gsl/gsl_util index d669b86..a9cb003 100644 --- a/include/gsl/gsl_util +++ b/include/gsl/gsl_util @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_UTIL_H -#define GSL_UTIL_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_UTIL_H +#define GUIDELINE_SUPPORT_LIBRARY_UTIL_H #include // Ensures/Expects @@ -150,4 +148,4 @@ inline constexpr T at(const std::initializer_list cont, const std::ptrdiff_t #endif // _MSC_VER -#endif // GSL_UTIL_H +#endif // GUIDELINE_SUPPORT_LIBRARY_UTIL_H diff --git a/include/gsl/multi_span b/include/gsl/multi_span index f9058b5..446885b 100644 --- a/include/gsl/multi_span +++ b/include/gsl/multi_span @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_MULTI_SPAN_H -#define GSL_MULTI_SPAN_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_MULTI_SPAN_H +#define GUIDELINE_SUPPORT_LIBRARY_MULTI_SPAN_H #include #include @@ -2231,4 +2229,4 @@ general_span_iterator operator+(typename general_span_iterator::diff #endif // _MSC_VER -#endif // GSL_MULTI_SPAN_H +#endif // GUIDELINE_SUPPORT_LIBRARY_MULTI_SPAN_H diff --git a/include/gsl/pointers b/include/gsl/pointers index 83ac9ea..333ad89 100644 --- a/include/gsl/pointers +++ b/include/gsl/pointers @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_POINTERS_H -#define GSL_POINTERS_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_POINTERS_H +#define GUIDELINE_SUPPORT_LIBRARY_POINTERS_H #include @@ -183,4 +181,4 @@ struct hash> #endif // defined(_MSC_VER) && _MSC_VER < 1910 -#endif // GSL_POINTERS_H +#endif // GUIDELINE_SUPPORT_LIBRARY_POINTERS_H diff --git a/include/gsl/span b/include/gsl/span index 7ea1a6c..a919c53 100644 --- a/include/gsl/span +++ b/include/gsl/span @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_SPAN_H -#define GSL_SPAN_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_SPAN_H +#define GUIDELINE_SUPPORT_LIBRARY_SPAN_H #include #include @@ -713,4 +711,4 @@ inline constexpr ElementType& at(const span& s, std::ptrdif #pragma warning(pop) #endif // _MSC_VER -#endif // GSL_SPAN_H +#endif // GUIDELINE_SUPPORT_LIBRARY_SPAN_H diff --git a/include/gsl/string_span b/include/gsl/string_span index 33e096a..b888782 100644 --- a/include/gsl/string_span +++ b/include/gsl/string_span @@ -14,10 +14,8 @@ // /////////////////////////////////////////////////////////////////////////////// -#pragma once - -#ifndef GSL_STRING_SPAN_H -#define GSL_STRING_SPAN_H +#ifndef GUIDELINE_SUPPORT_LIBRARY_STRING_SPAN_H +#define GUIDELINE_SUPPORT_LIBRARY_STRING_SPAN_H #include #include @@ -720,4 +718,4 @@ bool operator>=(const T& one, gsl::basic_string_span other) GSL_N #endif // _MSC_VER < 1910 #endif // _MSC_VER -#endif // GSL_STRING_SPAN_H +#endif // GUIDELINE_SUPPORT_LIBRARY_STRING_SPAN_H