]> git.xonotic.org Git - xonotic/netradiant.git/commitdiff
Remove -Wno-extra
authorTimePath <andrew.hardaker1995@gmail.com>
Sun, 6 Aug 2017 08:13:06 +0000 (18:13 +1000)
committerTimePath <andrew.hardaker1995@gmail.com>
Sun, 6 Aug 2017 08:13:06 +0000 (18:13 +1000)
CMakeLists.txt
include/renderable.h
libs/memory/allocator.h
libs/render.h
libs/str.h
libs/stringio.h
plugins/md3model/md5.cpp
radiant/camwindow.cpp
radiant/eclass_doom3.cpp
radiant/xywindow.cpp

index bbad9b9e67a70a0d52519baf86b899624a210350..f68f7c30da62bf5a20d9b9cb161dad750d7b0b6c 100644 (file)
@@ -87,10 +87,10 @@ addflags("-Wall")
 addflags("-Wextra")
 addflags("-pedantic")
 
-addflags("-Wno-extra")
 addflags("-Wno-switch")
 addflags("-Wno-pedantic")
 addflags("-Wno-parentheses")
+addflags("-Wno-sign-compare")
 addflags("-Wno-write-strings")
 addflags("-Wno-unused-function")
 addflags("-Wno-unused-variable")
index 8b972170ed7c723c786956a966e6f72cc21dffea..0c0e770bd35347719aac73338019edbbb1e88ca2 100644 (file)
@@ -48,7 +48,7 @@ enum EStyle
 virtual void PushState() = 0;
 virtual void PopState() = 0;
 virtual void SetState( Shader* state, EStyle mode ) = 0;
-virtual const EStyle getStyle() const = 0;
+virtual EStyle getStyle() const = 0;
 virtual void Highlight( EHighlightMode mode, bool bEnable = true ) = 0;
 virtual void setLights( const LightList& lights ){
 }
index bef7d7cb4c2a3eb02c0c30d3c9ab776cabb21d3d..845ce1400e716464b7022679d7abc421083e10ef 100644 (file)
@@ -118,11 +118,11 @@ struct rebind
        typedef NamedAllocator<Other> other;
 };
 
-explicit NamedAllocator( const char* name ) : m_name( name ){
+explicit NamedAllocator( const char* name ) : DefaultAllocator<Type>(), m_name( name ){
 }
-NamedAllocator( const NamedAllocator<Type>& other ) : m_name( other.m_name ){
+NamedAllocator( const NamedAllocator<Type>& other ) : DefaultAllocator<Type>(), m_name( other.m_name ){
 }
-template<typename Other> NamedAllocator( const NamedAllocator<Other>& other ) : m_name( other.m_name ){
+template<typename Other> NamedAllocator( const NamedAllocator<Other>& other ) : DefaultAllocator<Type>(), m_name( other.m_name ){
 }
 ~NamedAllocator(){
 }
index b53612bf11621d78f6fe28f8d14c1eba244ccdf9..d568edb386216a826a823d6d6799cf24ce45ec83 100644 (file)
@@ -171,7 +171,7 @@ RenderIndex m_prev0;
 RenderIndex m_prev1;
 RenderIndex m_prev2;
 
-const RenderIndex find_or_insert( const Vertex& vertex ){
+RenderIndex find_or_insert( const Vertex& vertex ){
        RenderIndex index = 0;
 
        while ( 1 )
index fcc328b1fd6eeacba0a96f8a5adb9f6ba56870ca..47be309dd2318e6e75f150e1d81ee369a5dcb573 100644 (file)
@@ -427,7 +427,7 @@ bool operator >( char* pStr ) const { return ( m_bIgnoreCase ) ? stricmp( m_pStr
 bool operator >( const char* pStr ) const { return ( m_bIgnoreCase ) ? stricmp( m_pStr, pStr ) > 0 : strcmp( m_pStr, pStr ) > 0; }
 char& operator []( std::size_t nIndex ) { return m_pStr[nIndex]; }
 const char& operator []( std::size_t nIndex ) const { return m_pStr[nIndex]; }
-const char GetAt( std::size_t nIndex ) { return m_pStr[nIndex]; }
+char GetAt( std::size_t nIndex ) { return m_pStr[nIndex]; }
 };
 
 
index ff1a3a67a1300f58ff4b7cefdd7dc01c26b069e2..ac680259d73338fd89bf408f07329ada6c55dbcd 100644 (file)
@@ -219,7 +219,7 @@ inline bool string_parse_size( const char* string, std::size_t& i ){
 }
 
 
-#define RETURN_FALSE_IF_FAIL( expression ) if ( !expression ) {return false; }else
+#define RETURN_FALSE_IF_FAIL(expression) do { if (!(expression)) return false; } while (0)
 
 inline void Tokeniser_unexpectedError( Tokeniser& tokeniser, const char* token, const char* expected ){
        globalErrorStream() << Unsigned( tokeniser.getLine() ) << ":" << Unsigned( tokeniser.getColumn() ) << ": parse error at '" << ( token != 0 ? token : "#EOF" ) << "': expected '" << expected << "'\n";
index 69719051c588e568cbafad6b86edebc8dc41eed1..e1c5de56d23f0ea0e4ec149a6c62115d9a0992b8 100644 (file)
@@ -29,7 +29,7 @@
 
 #include "model.h"
 
-#define MD5_RETURN_FALSE_IF_FAIL( expression ) if ( !( expression ) ) { globalErrorStream() << "md5 parse failed: " # expression "\n"; return false; } else
+#define MD5_RETURN_FALSE_IF_FAIL(expression) do { if (!(expression)) { globalErrorStream() << "md5 parse failed: " #expression "\n"; return false; } } while (0)
 
 bool MD5_parseToken( Tokeniser& tokeniser, const char* string ){
        const char* token = tokeniser.getToken();
index 0a8c80fd149940330604c622bcbd4ce0f0036c4e..e1f09679943503c9c8713911cb84602e4ac573b1 100644 (file)
@@ -1357,7 +1357,7 @@ void SetState( Shader* state, EStyle style ){
                m_state_stack.back().m_state = state;
        }
 }
-const EStyle getStyle() const {
+EStyle getStyle() const {
        return eFullMaterials;
 }
 void PushState(){
index f9598e4b9d094707ff541de9b505474350be745c..2fde638181ef36f32b459dcb2b5402721167630e 100644 (file)
@@ -84,7 +84,7 @@ inline void printParseError( const char* message ){
        globalErrorStream() << message;
 }
 
-#define PARSE_RETURN_FALSE_IF_FAIL( expression ) if ( !( expression ) ) { printParseError( FILE_LINE "\nparse failed: " # expression "\n" ); return false; } else
+#define PARSE_RETURN_FALSE_IF_FAIL(expression) do { if (!( expression)) { printParseError(FILE_LINE "\nparse failed: " #expression "\n"); return false; } } while (0)
 
 bool EntityClassDoom3_parseToken( Tokeniser& tokeniser ){
        const char* token = tokeniser.getToken();
index b265c25e0d3e11b86c6ad6ae14defabbd6c97476..93a78739749b9e0b73da88c8e320506f5f94bfa5 100644 (file)
@@ -2066,7 +2066,7 @@ void SetState( Shader* state, EStyle style ){
                m_state_stack.back().m_state = state;
        }
 }
-const EStyle getStyle() const {
+EStyle getStyle() const {
        return eWireframeOnly;
 }
 void PushState(){