diff options
| author | 2014-08-17 13:45:50 -0400 | |
|---|---|---|
| committer | 2014-08-17 13:45:55 -0400 | |
| commit | 90e994471a385d2b965e3843e1f693ccba6fb699 (patch) | |
| tree | b5835e0b235225f8478f26814205337d26a5d91a | |
| parent | Merge pull request #47 from archshift/stdstring (diff) | |
| download | yuzu-90e994471a385d2b965e3843e1f693ccba6fb699.tar.gz yuzu-90e994471a385d2b965e3843e1f693ccba6fb699.tar.xz yuzu-90e994471a385d2b965e3843e1f693ccba6fb699.zip | |
Common: Move header guards over to pragma once
Also replaced C headers with the C++ equivalent ones
Diffstat (limited to '')
33 files changed, 41 insertions, 146 deletions
diff --git a/src/common/atomic.h b/src/common/atomic.h index ff2fb23d3..941f5ad5e 100644 --- a/src/common/atomic.h +++ b/src/common/atomic.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _ATOMIC_H_ | 5 | #pragma once |
| 6 | #define _ATOMIC_H_ | ||
| 7 | 6 | ||
| 8 | #ifdef _WIN32 | 7 | #ifdef _WIN32 |
| 9 | 8 | ||
| @@ -15,5 +14,3 @@ | |||
| 15 | #include "common/atomic_gcc.h" | 14 | #include "common/atomic_gcc.h" |
| 16 | 15 | ||
| 17 | #endif | 16 | #endif |
| 18 | |||
| 19 | #endif | ||
diff --git a/src/common/atomic_gcc.h b/src/common/atomic_gcc.h index 953c82c6c..117e342f6 100644 --- a/src/common/atomic_gcc.h +++ b/src/common/atomic_gcc.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _ATOMIC_GCC_H_ | 5 | #pragma once |
| 6 | #define _ATOMIC_GCC_H_ | ||
| 7 | 6 | ||
| 8 | #include "common/common.h" | 7 | #include "common/common.h" |
| 9 | 8 | ||
| @@ -109,5 +108,3 @@ LONG SyncInterlockedExchange(LONG *Dest, LONG Val) | |||
| 109 | #endif | 108 | #endif |
| 110 | } | 109 | } |
| 111 | #endif | 110 | #endif |
| 112 | |||
| 113 | #endif | ||
diff --git a/src/common/atomic_win32.h b/src/common/atomic_win32.h index f8ec80520..0808905f0 100644 --- a/src/common/atomic_win32.h +++ b/src/common/atomic_win32.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _ATOMIC_WIN32_H_ | 5 | #pragma once |
| 6 | #define _ATOMIC_WIN32_H_ | ||
| 7 | 6 | ||
| 8 | #include "common/common.h" | 7 | #include "common/common.h" |
| 9 | #include <intrin.h> | 8 | #include <intrin.h> |
| @@ -68,5 +67,3 @@ inline void AtomicStoreRelease(volatile u32& dest, u32 value) { | |||
| 68 | } | 67 | } |
| 69 | 68 | ||
| 70 | } | 69 | } |
| 71 | |||
| 72 | #endif | ||
diff --git a/src/common/break_points.h b/src/common/break_points.h index da14ca7f3..cf3884fbc 100644 --- a/src/common/break_points.h +++ b/src/common/break_points.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _DEBUGGER_BREAKPOINTS_H | 5 | #pragma once |
| 6 | #define _DEBUGGER_BREAKPOINTS_H | ||
| 7 | 6 | ||
| 8 | #include <vector> | 7 | #include <vector> |
| 9 | #include <string> | 8 | #include <string> |
| @@ -98,5 +97,3 @@ public: | |||
| 98 | 97 | ||
| 99 | void Clear() { m_MemChecks.clear(); }; | 98 | void Clear() { m_MemChecks.clear(); }; |
| 100 | }; | 99 | }; |
| 101 | |||
| 102 | #endif | ||
diff --git a/src/common/chunk_file.h b/src/common/chunk_file.h index 8c9f839da..2b0f120e6 100644 --- a/src/common/chunk_file.h +++ b/src/common/chunk_file.h | |||
| @@ -15,8 +15,7 @@ | |||
| 15 | // Official SVN repository and contact information can be found at | 15 | // Official SVN repository and contact information can be found at |
| 16 | // http://code.google.com/p/dolphin-emu/ | 16 | // http://code.google.com/p/dolphin-emu/ |
| 17 | 17 | ||
| 18 | #ifndef _POINTERWRAP_H_ | 18 | #pragma once |
| 19 | #define _POINTERWRAP_H_ | ||
| 20 | 19 | ||
| 21 | // Extremely simple serialization framework. | 20 | // Extremely simple serialization framework. |
| 22 | 21 | ||
| @@ -871,5 +870,3 @@ private: | |||
| 871 | char GitVersion[32]; | 870 | char GitVersion[32]; |
| 872 | }; | 871 | }; |
| 873 | }; */ | 872 | }; */ |
| 874 | |||
| 875 | #endif // _POINTERWRAP_H_ | ||
diff --git a/src/common/common.h b/src/common/common.h index 09027cae1..cb69eabe4 100644 --- a/src/common/common.h +++ b/src/common/common.h | |||
| @@ -2,15 +2,14 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _COMMON_H_ | 5 | #pragma once |
| 6 | #define _COMMON_H_ | ||
| 7 | 6 | ||
| 8 | // DO NOT EVER INCLUDE <windows.h> directly _or indirectly_ from this file | 7 | // DO NOT EVER INCLUDE <windows.h> directly _or indirectly_ from this file |
| 9 | // since it slows down the build a lot. | 8 | // since it slows down the build a lot. |
| 10 | 9 | ||
| 11 | #include <stdlib.h> | 10 | #include <cstdlib> |
| 12 | #include <stdio.h> | 11 | #include <cstdio> |
| 13 | #include <string.h> | 12 | #include <cstring> |
| 14 | 13 | ||
| 15 | // Force enable logging in the right modes. For some reason, something had changed | 14 | // Force enable logging in the right modes. For some reason, something had changed |
| 16 | // so that debugfast no longer logged. | 15 | // so that debugfast no longer logged. |
| @@ -200,5 +199,3 @@ inline double bswapd(double f) { | |||
| 200 | } | 199 | } |
| 201 | 200 | ||
| 202 | #include "swap.h" | 201 | #include "swap.h" |
| 203 | |||
| 204 | #endif // _COMMON_H_ | ||
diff --git a/src/common/common_funcs.h b/src/common/common_funcs.h index dca4dc47f..c18afe119 100644 --- a/src/common/common_funcs.h +++ b/src/common/common_funcs.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _COMMONFUNCS_H_ | 5 | #pragma once |
| 6 | #define _COMMONFUNCS_H_ | ||
| 7 | 6 | ||
| 8 | #ifdef _WIN32 | 7 | #ifdef _WIN32 |
| 9 | #define SLEEP(x) Sleep(x) | 8 | #define SLEEP(x) Sleep(x) |
| @@ -233,5 +232,3 @@ inline T FromBigEndian(T data) | |||
| 233 | } | 232 | } |
| 234 | 233 | ||
| 235 | } // Namespace Common | 234 | } // Namespace Common |
| 236 | |||
| 237 | #endif // _COMMONFUNCS_H_ | ||
diff --git a/src/common/common_paths.h b/src/common/common_paths.h index 252e93fa9..a36de9227 100644 --- a/src/common/common_paths.h +++ b/src/common/common_paths.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _COMMON_PATHS_H_ | 5 | #pragma once |
| 6 | #define _COMMON_PATHS_H_ | ||
| 7 | 6 | ||
| 8 | // Make sure we pick up USER_DIR if set in config.h | 7 | // Make sure we pick up USER_DIR if set in config.h |
| 9 | #include "common/common.h" | 8 | #include "common/common.h" |
| @@ -75,5 +74,3 @@ | |||
| 75 | 74 | ||
| 76 | // Files in the directory returned by GetUserPath(D_SYSCONF_IDX) | 75 | // Files in the directory returned by GetUserPath(D_SYSCONF_IDX) |
| 77 | #define SYSCONF "SYSCONF" | 76 | #define SYSCONF "SYSCONF" |
| 78 | |||
| 79 | #endif // _COMMON_PATHS_H_ | ||
diff --git a/src/common/common_types.h b/src/common/common_types.h index 402410507..9d41e5971 100644 --- a/src/common/common_types.h +++ b/src/common/common_types.h | |||
| @@ -24,7 +24,7 @@ | |||
| 24 | 24 | ||
| 25 | #pragma once | 25 | #pragma once |
| 26 | 26 | ||
| 27 | #include <math.h> | 27 | #include <cmath> |
| 28 | #include <xmmintrin.h> // data_types__m128.cpp | 28 | #include <xmmintrin.h> // data_types__m128.cpp |
| 29 | 29 | ||
| 30 | #ifdef _WIN32 | 30 | #ifdef _WIN32 |
diff --git a/src/common/console_listener.h b/src/common/console_listener.h index 224d17017..3c0e420c6 100644 --- a/src/common/console_listener.h +++ b/src/common/console_listener.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _CONSOLELISTENER_H | 5 | #pragma once |
| 6 | #define _CONSOLELISTENER_H | ||
| 7 | 6 | ||
| 8 | #include "common/log_manager.h" | 7 | #include "common/log_manager.h" |
| 9 | 8 | ||
| @@ -37,5 +36,3 @@ private: | |||
| 37 | #endif | 36 | #endif |
| 38 | bool bUseColor; | 37 | bool bUseColor; |
| 39 | }; | 38 | }; |
| 40 | |||
| 41 | #endif // _CONSOLELISTENER_H | ||
diff --git a/src/common/cpu_detect.h b/src/common/cpu_detect.h index e93cf333a..def6afdee 100644 --- a/src/common/cpu_detect.h +++ b/src/common/cpu_detect.h | |||
| @@ -4,8 +4,7 @@ | |||
| 4 | 4 | ||
| 5 | 5 | ||
| 6 | // Detect the cpu, so we'll know which optimizations to use | 6 | // Detect the cpu, so we'll know which optimizations to use |
| 7 | #ifndef _CPUDETECT_H_ | 7 | #pragma once |
| 8 | #define _CPUDETECT_H_ | ||
| 9 | 8 | ||
| 10 | #include <string> | 9 | #include <string> |
| 11 | 10 | ||
| @@ -77,5 +76,3 @@ private: | |||
| 77 | }; | 76 | }; |
| 78 | 77 | ||
| 79 | extern CPUInfo cpu_info; | 78 | extern CPUInfo cpu_info; |
| 80 | |||
| 81 | #endif // _CPUDETECT_H_ | ||
diff --git a/src/common/debug_interface.h b/src/common/debug_interface.h index 49cc54a80..32f55cb59 100644 --- a/src/common/debug_interface.h +++ b/src/common/debug_interface.h | |||
| @@ -1,8 +1,7 @@ | |||
| 1 | #ifndef _DEBUGINTERFACE_H | 1 | #pragma once |
| 2 | #define _DEBUGINTERFACE_H | ||
| 3 | 2 | ||
| 3 | #include <cstring> | ||
| 4 | #include <string> | 4 | #include <string> |
| 5 | #include <string.h> | ||
| 6 | 5 | ||
| 7 | class DebugInterface | 6 | class DebugInterface |
| 8 | { | 7 | { |
| @@ -35,5 +34,3 @@ public: | |||
| 35 | virtual int getColor(unsigned int /*address*/){return 0xFFFFFFFF;} | 34 | virtual int getColor(unsigned int /*address*/){return 0xFFFFFFFF;} |
| 36 | virtual std::string getDescription(unsigned int /*address*/) = 0; | 35 | virtual std::string getDescription(unsigned int /*address*/) = 0; |
| 37 | }; | 36 | }; |
| 38 | |||
| 39 | #endif | ||
diff --git a/src/common/extended_trace.h b/src/common/extended_trace.h index 1552e901b..ed3113a24 100644 --- a/src/common/extended_trace.h +++ b/src/common/extended_trace.h | |||
| @@ -12,8 +12,7 @@ | |||
| 12 | // | 12 | // |
| 13 | // ---------------------------------------------------------------------------------------- | 13 | // ---------------------------------------------------------------------------------------- |
| 14 | 14 | ||
| 15 | #ifndef _EXTENDEDTRACE_H_INCLUDED_ | 15 | #pragma once |
| 16 | #define _EXTENDEDTRACE_H_INCLUDED_ | ||
| 17 | 16 | ||
| 18 | #if defined(WIN32) | 17 | #if defined(WIN32) |
| 19 | 18 | ||
| @@ -49,5 +48,3 @@ extern char g_uefbuf[UEFBUFSIZE]; | |||
| 49 | #define STACKTRACE2(file, eip, esp, ebp) ((void)0) | 48 | #define STACKTRACE2(file, eip, esp, ebp) ((void)0) |
| 50 | 49 | ||
| 51 | #endif // WIN32 | 50 | #endif // WIN32 |
| 52 | |||
| 53 | #endif // _EXTENDEDTRACE_H_INCLUDED_ | ||
diff --git a/src/common/fifo_queue.h b/src/common/fifo_queue.h index 4e80f53b4..78a8f561d 100644 --- a/src/common/fifo_queue.h +++ b/src/common/fifo_queue.h | |||
| @@ -1,6 +1,4 @@ | |||
| 1 | 1 | #pragma once | |
| 2 | #ifndef _FIFO_QUEUE_H_ | ||
| 3 | #define _FIFO_QUEUE_H_ | ||
| 4 | 2 | ||
| 5 | // a simple lockless thread-safe, | 3 | // a simple lockless thread-safe, |
| 6 | // single reader, single writer queue | 4 | // single reader, single writer queue |
| @@ -111,5 +109,3 @@ private: | |||
| 111 | }; | 109 | }; |
| 112 | 110 | ||
| 113 | } | 111 | } |
| 114 | |||
| 115 | #endif | ||
diff --git a/src/common/file_search.h b/src/common/file_search.h index 2a9ff801f..f966a008d 100644 --- a/src/common/file_search.h +++ b/src/common/file_search.h | |||
| @@ -2,9 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | 5 | #pragma once | |
| 6 | #ifndef _FILESEARCH_H_ | ||
| 7 | #define _FILESEARCH_H_ | ||
| 8 | 6 | ||
| 9 | #include <string> | 7 | #include <string> |
| 10 | #include <vector> | 8 | #include <vector> |
| @@ -23,6 +21,3 @@ private: | |||
| 23 | 21 | ||
| 24 | XStringVector m_FileNames; | 22 | XStringVector m_FileNames; |
| 25 | }; | 23 | }; |
| 26 | |||
| 27 | #endif // _FILESEARCH_H_ | ||
| 28 | |||
diff --git a/src/common/file_util.h b/src/common/file_util.h index 5edb43f6a..0871734d4 100644 --- a/src/common/file_util.h +++ b/src/common/file_util.h | |||
| @@ -2,9 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | 5 | #pragma once | |
| 6 | #ifndef _FILEUTIL_H_ | ||
| 7 | #define _FILEUTIL_H_ | ||
| 8 | 6 | ||
| 9 | #include <fstream> | 7 | #include <fstream> |
| 10 | #include <cstdio> | 8 | #include <cstdio> |
| @@ -220,5 +218,3 @@ void OpenFStream(T& fstream, const std::string& filename, std::ios_base::openmod | |||
| 220 | fstream.open(filename.c_str(), openmode); | 218 | fstream.open(filename.c_str(), openmode); |
| 221 | #endif | 219 | #endif |
| 222 | } | 220 | } |
| 223 | |||
| 224 | #endif | ||
diff --git a/src/common/fixed_size_queue.h b/src/common/fixed_size_queue.h index 1f507f4ae..1e3a5dea6 100644 --- a/src/common/fixed_size_queue.h +++ b/src/common/fixed_size_queue.h | |||
| @@ -2,9 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | 5 | #pragma once | |
| 6 | #ifndef _FIXED_SIZE_QUEUE_H_ | ||
| 7 | #define _FIXED_SIZE_QUEUE_H_ | ||
| 8 | 6 | ||
| 9 | // STL-look-a-like interface, but name is mixed case to distinguish it clearly from the | 7 | // STL-look-a-like interface, but name is mixed case to distinguish it clearly from the |
| 10 | // real STL classes. | 8 | // real STL classes. |
| @@ -70,6 +68,3 @@ public: | |||
| 70 | return count; | 68 | return count; |
| 71 | } | 69 | } |
| 72 | }; | 70 | }; |
| 73 | |||
| 74 | #endif // _FIXED_SIZE_QUEUE_H_ | ||
| 75 | |||
diff --git a/src/common/hash.h b/src/common/hash.h index c69908415..29f699d7f 100644 --- a/src/common/hash.h +++ b/src/common/hash.h | |||
| @@ -2,9 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | 5 | #pragma once | |
| 6 | #ifndef _HASH_H_ | ||
| 7 | #define _HASH_H_ | ||
| 8 | 6 | ||
| 9 | #include "common/common.h" | 7 | #include "common/common.h" |
| 10 | 8 | ||
| @@ -17,4 +15,3 @@ u64 GetHashHiresTexture(const u8 *src, int len, u32 samples); | |||
| 17 | u64 GetMurmurHash3(const u8 *src, int len, u32 samples); | 15 | u64 GetMurmurHash3(const u8 *src, int len, u32 samples); |
| 18 | u64 GetHash64(const u8 *src, int len, u32 samples); | 16 | u64 GetHash64(const u8 *src, int len, u32 samples); |
| 19 | void SetHash64Function(bool useHiresTextures); | 17 | void SetHash64Function(bool useHiresTextures); |
| 20 | #endif // _HASH_H_ | ||
diff --git a/src/common/linear_disk_cache.h b/src/common/linear_disk_cache.h index a24687615..96dce3155 100644 --- a/src/common/linear_disk_cache.h +++ b/src/common/linear_disk_cache.h | |||
| @@ -2,9 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | 5 | #pragma once | |
| 6 | #ifndef _LINEAR_DISKCACHE | ||
| 7 | #define _LINEAR_DISKCACHE | ||
| 8 | 6 | ||
| 9 | #include "common/common.h" | 7 | #include "common/common.h" |
| 10 | #include <fstream> | 8 | #include <fstream> |
| @@ -187,5 +185,3 @@ private: | |||
| 187 | std::fstream m_file; | 185 | std::fstream m_file; |
| 188 | u32 m_num_entries; | 186 | u32 m_num_entries; |
| 189 | }; | 187 | }; |
| 190 | |||
| 191 | #endif // _LINEAR_DISKCACHE | ||
diff --git a/src/common/log.h b/src/common/log.h index e923224ed..f1f6ffae6 100644 --- a/src/common/log.h +++ b/src/common/log.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _LOG_H_ | 5 | #pragma once |
| 6 | #define _LOG_H_ | ||
| 7 | 6 | ||
| 8 | #define LOGGING | 7 | #define LOGGING |
| 9 | 8 | ||
| @@ -160,5 +159,3 @@ void GenericLog(LOGTYPES_LEVELS level, LOGTYPES_TYPE type, const char*file, int | |||
| 160 | #else // GEKKO | 159 | #else // GEKKO |
| 161 | #define _assert_msg_(_t_, _a_, _fmt_, ...) | 160 | #define _assert_msg_(_t_, _a_, _fmt_, ...) |
| 162 | #endif | 161 | #endif |
| 163 | |||
| 164 | #endif // _LOG_H_ | ||
diff --git a/src/common/log_manager.h b/src/common/log_manager.h index 6d3d7c7ff..81d808825 100644 --- a/src/common/log_manager.h +++ b/src/common/log_manager.h | |||
| @@ -2,16 +2,15 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _LOGMANAGER_H_ | 5 | #pragma once |
| 6 | #define _LOGMANAGER_H_ | ||
| 7 | 6 | ||
| 8 | #include "common/log.h" | 7 | #include "common/log.h" |
| 9 | #include "common/string_util.h" | 8 | #include "common/string_util.h" |
| 10 | #include "common/thread.h" | 9 | #include "common/thread.h" |
| 11 | #include "common/file_util.h" | 10 | #include "common/file_util.h" |
| 12 | 11 | ||
| 12 | #include <cstring> | ||
| 13 | #include <set> | 13 | #include <set> |
| 14 | #include <string.h> | ||
| 15 | 14 | ||
| 16 | #define MAX_MESSAGES 8000 | 15 | #define MAX_MESSAGES 8000 |
| 17 | #define MAX_MSGLEN 1024 | 16 | #define MAX_MSGLEN 1024 |
| @@ -165,5 +164,3 @@ public: | |||
| 165 | static void Init(); | 164 | static void Init(); |
| 166 | static void Shutdown(); | 165 | static void Shutdown(); |
| 167 | }; | 166 | }; |
| 168 | |||
| 169 | #endif // _LOGMANAGER_H_ | ||
diff --git a/src/common/math_util.h b/src/common/math_util.h index 9167d2012..65220fbdf 100644 --- a/src/common/math_util.h +++ b/src/common/math_util.h | |||
| @@ -2,9 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | 5 | #pragma once | |
| 6 | #ifndef _MATH_UTIL_H_ | ||
| 7 | #define _MATH_UTIL_H_ | ||
| 8 | 6 | ||
| 9 | #include "common/common.h" | 7 | #include "common/common.h" |
| 10 | 8 | ||
| @@ -196,5 +194,3 @@ public: | |||
| 196 | 194 | ||
| 197 | float data[16]; | 195 | float data[16]; |
| 198 | }; | 196 | }; |
| 199 | |||
| 200 | #endif // _MATH_UTIL_H_ | ||
diff --git a/src/common/mem_arena.h b/src/common/mem_arena.h index 667efbea9..b5f0aa890 100644 --- a/src/common/mem_arena.h +++ b/src/common/mem_arena.h | |||
| @@ -15,8 +15,7 @@ | |||
| 15 | // Official SVN repository and contact information can be found at | 15 | // Official SVN repository and contact information can be found at |
| 16 | // http://code.google.com/p/dolphin-emu/ | 16 | // http://code.google.com/p/dolphin-emu/ |
| 17 | 17 | ||
| 18 | #ifndef _MEMARENA_H_ | 18 | #pragma once |
| 19 | #define _MEMARENA_H_ | ||
| 20 | 19 | ||
| 21 | #ifdef _WIN32 | 20 | #ifdef _WIN32 |
| 22 | #include <windows.h> | 21 | #include <windows.h> |
| @@ -77,5 +76,3 @@ struct MemoryView | |||
| 77 | // a passed-in list of MemoryView structures. | 76 | // a passed-in list of MemoryView structures. |
| 78 | u8 *MemoryMap_Setup(const MemoryView *views, int num_views, u32 flags, MemArena *arena); | 77 | u8 *MemoryMap_Setup(const MemoryView *views, int num_views, u32 flags, MemArena *arena); |
| 79 | void MemoryMap_Shutdown(const MemoryView *views, int num_views, u32 flags, MemArena *arena); | 78 | void MemoryMap_Shutdown(const MemoryView *views, int num_views, u32 flags, MemArena *arena); |
| 80 | |||
| 81 | #endif // _MEMARENA_H_ | ||
diff --git a/src/common/memory_util.h b/src/common/memory_util.h index 49b2589da..922bd44b2 100644 --- a/src/common/memory_util.h +++ b/src/common/memory_util.h | |||
| @@ -2,9 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | 5 | #pragma once | |
| 6 | #ifndef _MEMORYUTIL_H | ||
| 7 | #define _MEMORYUTIL_H | ||
| 8 | 6 | ||
| 9 | #ifndef _WIN32 | 7 | #ifndef _WIN32 |
| 10 | #include <sys/mman.h> | 8 | #include <sys/mman.h> |
| @@ -21,5 +19,3 @@ void UnWriteProtectMemory(void* ptr, size_t size, bool allowExecute = false); | |||
| 21 | std::string MemUsage(); | 19 | std::string MemUsage(); |
| 22 | 20 | ||
| 23 | inline int GetPageSize() { return 4096; } | 21 | inline int GetPageSize() { return 4096; } |
| 24 | |||
| 25 | #endif | ||
diff --git a/src/common/msg_handler.h b/src/common/msg_handler.h index bde2808fa..7c5319ec3 100644 --- a/src/common/msg_handler.h +++ b/src/common/msg_handler.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _MSGHANDLER_H_ | 5 | #pragma once |
| 6 | #define _MSGHANDLER_H_ | ||
| 7 | 6 | ||
| 8 | #include <string> | 7 | #include <string> |
| 9 | 8 | ||
| @@ -69,5 +68,3 @@ void SetEnableAlert(bool enable); | |||
| 69 | #define AskYesNoT(format, ...) ; | 68 | #define AskYesNoT(format, ...) ; |
| 70 | #define CriticalAlertT(format, ...) ; | 69 | #define CriticalAlertT(format, ...) ; |
| 71 | #endif | 70 | #endif |
| 72 | |||
| 73 | #endif // _MSGHANDLER_H_ | ||
diff --git a/src/common/platform.h b/src/common/platform.h index b02b52cd2..d9f095433 100644 --- a/src/common/platform.h +++ b/src/common/platform.h | |||
| @@ -22,8 +22,7 @@ | |||
| 22 | * http://code.google.com/p/gekko-gc-emu/ | 22 | * http://code.google.com/p/gekko-gc-emu/ |
| 23 | */ | 23 | */ |
| 24 | 24 | ||
| 25 | #ifndef COMMON_PLATFORM_H_ | 25 | #pragma once |
| 26 | #define COMMON_PLATFORM_H_ | ||
| 27 | 26 | ||
| 28 | #include "common/common_types.h" | 27 | #include "common/common_types.h" |
| 29 | 28 | ||
| @@ -110,5 +109,3 @@ typedef void EXCEPTION_POINTERS; | |||
| 110 | 109 | ||
| 111 | #define GCC_VERSION_AVAILABLE(major, minor) (defined(__GNUC__) && (__GNUC__ > (major) || \ | 110 | #define GCC_VERSION_AVAILABLE(major, minor) (defined(__GNUC__) && (__GNUC__ > (major) || \ |
| 112 | (__GNUC__ == (major) && __GNUC_MINOR__ >= (minor)))) | 111 | (__GNUC__ == (major) && __GNUC_MINOR__ >= (minor)))) |
| 113 | |||
| 114 | #endif // COMMON_PLATFORM_H_ | ||
diff --git a/src/common/std_condition_variable.h b/src/common/std_condition_variable.h index 8964b4f6f..ad2022f5a 100644 --- a/src/common/std_condition_variable.h +++ b/src/common/std_condition_variable.h | |||
| @@ -1,6 +1,5 @@ | |||
| 1 | 1 | ||
| 2 | #ifndef CONDITION_VARIABLE_H_ | 2 | #pragma once |
| 3 | #define CONDITION_VARIABLE_H_ | ||
| 4 | 3 | ||
| 5 | #define GCC_VER(x,y,z) ((x) * 10000 + (y) * 100 + (z)) | 4 | #define GCC_VER(x,y,z) ((x) * 10000 + (y) * 100 + (z)) |
| 6 | #define GCC_VERSION GCC_VER(__GNUC__, __GNUC_MINOR__, __GNUC_PATCHLEVEL__) | 5 | #define GCC_VERSION GCC_VER(__GNUC__, __GNUC_MINOR__, __GNUC_PATCHLEVEL__) |
| @@ -167,4 +166,3 @@ private: | |||
| 167 | } | 166 | } |
| 168 | 167 | ||
| 169 | #endif | 168 | #endif |
| 170 | #endif | ||
diff --git a/src/common/std_mutex.h b/src/common/std_mutex.h index 26eb58b62..5711d791b 100644 --- a/src/common/std_mutex.h +++ b/src/common/std_mutex.h | |||
| @@ -1,6 +1,4 @@ | |||
| 1 | 1 | #pragma once | |
| 2 | #ifndef MUTEX_H_ | ||
| 3 | #define MUTEX_H_ | ||
| 4 | 2 | ||
| 5 | #define GCC_VER(x,y,z) ((x) * 10000 + (y) * 100 + (z)) | 3 | #define GCC_VER(x,y,z) ((x) * 10000 + (y) * 100 + (z)) |
| 6 | #define GCC_VERSION GCC_VER(__GNUC__, __GNUC_MINOR__, __GNUC_PATCHLEVEL__) | 4 | #define GCC_VERSION GCC_VER(__GNUC__, __GNUC_MINOR__, __GNUC_PATCHLEVEL__) |
| @@ -362,4 +360,3 @@ void swap(unique_lock<Mutex>& x, unique_lock<Mutex>& y) | |||
| 362 | } | 360 | } |
| 363 | 361 | ||
| 364 | #endif | 362 | #endif |
| 365 | #endif | ||
diff --git a/src/common/std_thread.h b/src/common/std_thread.h index 9ed0072c3..ce1336ee7 100644 --- a/src/common/std_thread.h +++ b/src/common/std_thread.h | |||
| @@ -1,6 +1,4 @@ | |||
| 1 | 1 | #pragma once | |
| 2 | #ifndef STD_THREAD_H_ | ||
| 3 | #define STD_THREAD_H_ | ||
| 4 | 2 | ||
| 5 | #define GCC_VER(x,y,z) ((x) * 10000 + (y) * 100 + (z)) | 3 | #define GCC_VER(x,y,z) ((x) * 10000 + (y) * 100 + (z)) |
| 6 | #define GCC_VERSION GCC_VER(__GNUC__, __GNUC_MINOR__, __GNUC_PATCHLEVEL__) | 4 | #define GCC_VERSION GCC_VER(__GNUC__, __GNUC_MINOR__, __GNUC_PATCHLEVEL__) |
| @@ -314,4 +312,3 @@ inline thread::id get_id() | |||
| 314 | #undef THREAD_HANDLE | 312 | #undef THREAD_HANDLE |
| 315 | 313 | ||
| 316 | #endif | 314 | #endif |
| 317 | #endif | ||
diff --git a/src/common/string_util.h b/src/common/string_util.h index b3c99a807..ba4cd363e 100644 --- a/src/common/string_util.h +++ b/src/common/string_util.h | |||
| @@ -2,15 +2,13 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _STRINGUTIL_H_ | 5 | #pragma once |
| 6 | #define _STRINGUTIL_H_ | ||
| 7 | 6 | ||
| 8 | #include <stdarg.h> | 7 | #include <cstdarg> |
| 9 | 8 | #include <iomanip> | |
| 10 | #include <vector> | ||
| 11 | #include <string> | 9 | #include <string> |
| 12 | #include <sstream> | 10 | #include <sstream> |
| 13 | #include <iomanip> | 11 | #include <vector> |
| 14 | 12 | ||
| 15 | #include "common/common.h" | 13 | #include "common/common.h" |
| 16 | 14 | ||
| @@ -113,5 +111,3 @@ inline std::string UTF8ToTStr(const std::string& str) | |||
| 113 | #endif | 111 | #endif |
| 114 | 112 | ||
| 115 | #endif | 113 | #endif |
| 116 | |||
| 117 | #endif // _STRINGUTIL_H_ | ||
diff --git a/src/common/thread.h b/src/common/thread.h index d72ac7b47..ff2c1d8be 100644 --- a/src/common/thread.h +++ b/src/common/thread.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _THREAD_H_ | 5 | #pragma once |
| 6 | #define _THREAD_H_ | ||
| 7 | 6 | ||
| 8 | #include "common/std_condition_variable.h" | 7 | #include "common/std_condition_variable.h" |
| 9 | #include "common/std_mutex.h" | 8 | #include "common/std_mutex.h" |
| @@ -152,5 +151,3 @@ inline void YieldCPU() | |||
| 152 | void SetCurrentThreadName(const char *name); | 151 | void SetCurrentThreadName(const char *name); |
| 153 | 152 | ||
| 154 | } // namespace Common | 153 | } // namespace Common |
| 155 | |||
| 156 | #endif // _THREAD_H_ | ||
diff --git a/src/common/thunk.h b/src/common/thunk.h index 2c2f23cd0..90c8be888 100644 --- a/src/common/thunk.h +++ b/src/common/thunk.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _THUNK_H_ | 5 | #pragma once |
| 6 | #define _THUNK_H_ | ||
| 7 | 6 | ||
| 8 | #include <map> | 7 | #include <map> |
| 9 | 8 | ||
| @@ -41,5 +40,3 @@ private: | |||
| 41 | void Shutdown(); | 40 | void Shutdown(); |
| 42 | void Reset(); | 41 | void Reset(); |
| 43 | }; | 42 | }; |
| 44 | |||
| 45 | #endif // _THUNK_H_ | ||
diff --git a/src/common/timer.h b/src/common/timer.h index cfa5cf609..86418e7a7 100644 --- a/src/common/timer.h +++ b/src/common/timer.h | |||
| @@ -2,8 +2,7 @@ | |||
| 2 | // Licensed under GPLv2 | 2 | // Licensed under GPLv2 |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #ifndef _TIMER_H_ | 5 | #pragma once |
| 6 | #define _TIMER_H_ | ||
| 7 | 6 | ||
| 8 | #include "common/common.h" | 7 | #include "common/common.h" |
| 9 | #include <string> | 8 | #include <string> |
| @@ -42,5 +41,3 @@ private: | |||
| 42 | }; | 41 | }; |
| 43 | 42 | ||
| 44 | } // Namespace Common | 43 | } // Namespace Common |
| 45 | |||
| 46 | #endif // _TIMER_H_ | ||