Skip to content

Commit

Permalink
Merge pull request google#79 from more-please/master
Browse files Browse the repository at this point in the history
Fix C++11 warning - left shift of signed value is undefined
  • Loading branch information
Stewart Miles authored Jan 10, 2018
2 parents 17989af + 258dd34 commit 7f20402
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion liquidfun/Box2D/Box2D/Common/b2Settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ typedef unsigned long long uint64;
// We expand the API so that other languages (e.g. Java) can call into
// our C++ more easily. Only set if when the flag is not externally defined.
#if !defined(LIQUIDFUN_EXTERNAL_LANGUAGE_API)
#if SWIG || LIQUIDFUN_UNIT_TESTS
#if defined(SWIG) || defined(LIQUIDFUN_UNIT_TESTS)
#define LIQUIDFUN_EXTERNAL_LANGUAGE_API 1
#else
#define LIQUIDFUN_EXTERNAL_LANGUAGE_API 0
Expand Down
2 changes: 1 addition & 1 deletion liquidfun/Box2D/Box2D/Particle/b2ParticleSystem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ static const uint32 yMask = ((1u << yTruncBits) - 1u) << yShift;
static const uint32 xMask = ~yMask;
static const uint32 relativeTagRight = 1u << xShift;
static const uint32 relativeTagBottomLeft = (uint32)((1 << yShift) +
(-1 << xShift));
((~uint32(0)) << xShift));

static const uint32 relativeTagBottomRight = (1u << yShift) + (1u << xShift);

Expand Down
2 changes: 1 addition & 1 deletion liquidfun/Box2D/Box2D/Particle/b2ParticleSystem.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include <Box2D/Particle/b2Particle.h>
#include <Box2D/Dynamics/b2TimeStep.h>

#if LIQUIDFUN_UNIT_TESTS
#ifdef LIQUIDFUN_UNIT_TESTS
#include <gtest/gtest.h>
#endif // LIQUIDFUN_UNIT_TESTS

Expand Down

0 comments on commit 7f20402

Please sign in to comment.