Fix some clang warnings with constructor initialise order

This commit is contained in:
baldurk
2015-03-29 11:31:51 +01:00
parent 355729aaad
commit 2d9ca94316
3 changed files with 7 additions and 5 deletions
+1 -1
View File
@@ -123,7 +123,7 @@ struct str : public rdctype::array<char>
str &operator =(const char *const in);
str() : rdctype::array<char>() {}
str(const str &o) { elems = 0; count = 0; *this = o; }
str(const str &o) : rdctype::array<char>() { *this = o; }
str &operator =(const str &o)
{
// do nothing if we're self-assigning
+3 -2
View File
@@ -119,8 +119,9 @@ struct D3D11PipelineState
struct Sampler
{
Sampler()
: Samp(), MaxAniso(0), MaxLOD(0.0f), MinLOD(0.0f), MipLODBias(0.0f)
, UseBorder(false), UseComparison(false)
: Samp()
, UseBorder(false), UseComparison(false)
, MaxAniso(0), MaxLOD(0.0f), MinLOD(0.0f), MipLODBias(0.0f)
{ BorderColor[0] = BorderColor[1] = BorderColor[2] = BorderColor[3] = 0.0f; }
ResourceId Samp;
rdctype::str AddressU, AddressV, AddressW;
+3 -2
View File
@@ -127,8 +127,9 @@ struct GLPipelineState
struct Sampler
{
Sampler()
: Samp(), MaxAniso(0.0f), MaxLOD(0.0f), MinLOD(0.0f), MipLODBias(0.0f)
: Samp()
, UseBorder(false), UseComparison(false), SeamlessCube(false)
, MaxAniso(0.0f), MaxLOD(0.0f), MinLOD(0.0f), MipLODBias(0.0f)
{ BorderColor[0] = BorderColor[1] = BorderColor[2] = BorderColor[3] = 0.0f; }
ResourceId Samp;
rdctype::str AddressS, AddressT, AddressR;
@@ -333,4 +334,4 @@ struct GLPipelineState
bool32 LineSmoothEnabled;
bool32 PolySmoothEnabled;
} m_Hints;
};
};