Skip to content

Commit 32df726

Browse files
authored
Merge pull request #7 from PapeCoding/fix/include_guards
Fixing include guards and transitioning to using pragma once
2 parents 1694e93 + ff1f271 commit 32df726

File tree

90 files changed

+97
-253
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+97
-253
lines changed

Src/Common/Allocators/PooledAlloc.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@
22
//
33
// Copyright (c) 2005 David Ward
44

5-
#ifndef __PooledAlloc_h__
6-
#define __PooledAlloc_h__
5+
#pragma once
76

87
// CPooledAlloc allocates objects T in fixed-size blocks (specified in the constructor)
98
// Alloc returns an uninitialized T*
@@ -54,4 +53,3 @@ template<typename T> void CPooledAlloc<T>::Free(T *pFree) {
5453
m_vpFree.push_back(pFree);
5554
}
5655

57-
#endif // __include__

Src/Common/Allocators/SimplePooledAlloc.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@
22
//
33
// Copyright (c) 2005 David Ward
44

5-
#ifndef __SimplePooledAlloc_h__
6-
#define __SimplePooledAlloc_h__
5+
#pragma once
76

87
// CSimplePooledAlloc allocates objects T in fixed-size blocks (specified)
98
// Alloc returns a default-constructed T*
@@ -67,4 +66,3 @@ template < typename T > T * CSimplePooledAlloc < T >::Alloc() {
6766
return m_vPool.back()->Alloc();
6867
}
6968

70-
#endif // __include__

Src/Common/AppSettingsData.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
#pragma once
2+
13
#include "AppSettingsHeader.h"
24
#include "../DasherCore/Parameters.h"
35

Src/Common/AppSettingsHeader.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#ifndef __appsettingsheader_h__
2-
#define __appsettingsheader_h__
1+
#pragma once
32

43
#include "../DasherCore/Parameters.h"
54
#ifdef HAVE_CONFIG_H
@@ -31,4 +30,3 @@ enum {
3130
APP_STYLE_COMPOSE,
3231
APP_STYLE_DIRECT,
3332
APP_STYLE_FULLSCREEN };
34-
#endif

Src/Common/Globber.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@
66
// Copyright 2011 Cambridge University. All rights reserved.
77
//
88

9-
#ifndef __GLOBBER_H__
10-
#define __GLOBBER_H__
9+
#pragma once
1110

1211
#include "../DasherCore/AbstractXMLParser.h"
1312

@@ -19,4 +18,3 @@ void globScan(AbstractParser *parser,
1918
const char **sysPaths,
2019
int(*error_callback)(const char *,int));
2120

22-
#endif

Src/Common/I18n.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,7 @@
1818
// along with Dasher; if not, write to the Free Software
1919
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
2020

21-
#ifndef __i18n_h__
22-
#define __i18n_h__
21+
#pragma once
2322

2423
#if defined(_WIN32) || defined(__APPLE__)
2524

@@ -42,4 +41,3 @@
4241

4342
#endif
4443

45-
#endif

Src/Common/MSVC_Unannoy.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#ifndef __MSVC_Unannoy_h__
2-
#define __MSVC_Unannoy_h__
1+
#pragma once
32

43
// Sorry about this frequently included header non-VC++ users.
54
// It shouldn't do any harm.
@@ -15,4 +14,3 @@
1514
#pragma warning(disable:4996) // warning C4996: 'fopen' was declared deprecated
1615
#endif
1716

18-
#endif /* #ifndef __MSVC_Unannoy_h__ */

Src/Common/ModuleSettings.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#ifndef __ModuleSettings_h__
2-
#define __ModuleSettings_h__
1+
#pragma once
32

43
enum setting_t {
54
T_BOOL,
@@ -20,4 +19,3 @@ struct _SModuleSettings {
2019
const char *szDescription;
2120
};
2221

23-
#endif

Src/Common/NoClones.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
#ifndef __NoClones_h__
2-
#define __NoClones_h__
1+
#pragma once
32

43
/* Explanation of NoClones {{{
54
@@ -36,4 +35,3 @@ class NoClones {
3635
NoClones & operator=(const NoClones &);
3736
};
3837

39-
#endif /* #ifndef __NoClones_h__ */

Src/Common/OpenGLScreen.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@
55
// Created by Alan Lawrence on 20/03/2009.
66
// Copyright 2009 Cavendish Laboratory. All rights reserved.
77
//
8+
9+
#pragma once
10+
811
#if TARGET_OS_IPHONE
912
#import <OpenGLES/ES1/gl.h>
1013
#else

0 commit comments

Comments
 (0)