Skip to content

Commit

Permalink
Merge pull request assimp#387 from Kvalme/master
Browse files Browse the repository at this point in the history
Fix gcc warnings. (initialization order)
  • Loading branch information
acgessler committed Sep 16, 2014
2 parents f2d2622 + ab6b5a7 commit f7f906e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 9 deletions.
11 changes: 6 additions & 5 deletions code/FBXBinaryTokenizer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,15 @@ namespace FBX {

// ------------------------------------------------------------------------------------------------
Token::Token(const char* sbegin, const char* send, TokenType type, unsigned int offset)
: sbegin(sbegin)
:
#ifdef DEBUG
contents(sbegin, static_cast<size_t>(send-sbegin)),
#endif
sbegin(sbegin)
, send(send)
, type(type)
, line(offset)
, column(BINARY_MARKER)
#ifdef DEBUG
, contents(sbegin, static_cast<size_t>(send-sbegin))
#endif
{
ai_assert(sbegin);
ai_assert(send);
Expand Down Expand Up @@ -395,4 +396,4 @@ void TokenizeBinary(TokenList& output_tokens, const char* input, unsigned int le
} // !FBX
} // !Assimp

#endif
#endif
9 changes: 5 additions & 4 deletions code/FBXTokenizer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,15 @@ namespace FBX {

// ------------------------------------------------------------------------------------------------
Token::Token(const char* sbegin, const char* send, TokenType type, unsigned int line, unsigned int column)
: sbegin(sbegin)
:
#ifdef DEBUG
contents(sbegin, static_cast<size_t>(send-sbegin)),
#endif
sbegin(sbegin)
, send(send)
, type(type)
, line(line)
, column(column)
#ifdef DEBUG
, contents(sbegin, static_cast<size_t>(send-sbegin))
#endif
{
ai_assert(sbegin);
ai_assert(send);
Expand Down

0 comments on commit f7f906e

Please sign in to comment.