forked from 0ad/0ad
Fix errors and warnings with optimised builds
This was SVN commit r7304.
This commit is contained in:
parent
50b79962ad
commit
e1b2a7f3ad
@ -78,7 +78,7 @@ public:
|
||||
|
||||
// Find the extents of the animation:
|
||||
|
||||
float timeStart, timeEnd;
|
||||
float timeStart = 0, timeEnd = 0;
|
||||
GetAnimationRange(converter.GetDocument(), skeleton, controllerInstance, timeStart, timeEnd);
|
||||
|
||||
// Count frames; don't include the last keyframe
|
||||
|
@ -334,7 +334,7 @@ PSRETURN GUI<T>::GetSettingPointer(const IGUIObject *pObject, const CStr& Settin
|
||||
template <typename T>
|
||||
PSRETURN GUI<T>::GetSetting(const IGUIObject *pObject, const CStr& Setting, T &Value)
|
||||
{
|
||||
T* v;
|
||||
T* v = NULL;
|
||||
PSRETURN ret = GetSettingPointer(pObject, Setting, v);
|
||||
if (ret == PSRETURN_OK)
|
||||
Value = *v;
|
||||
|
@ -466,6 +466,7 @@ template<typename T> jsval ScriptInterface::ToJSVal(JSContext* cx, const T& v)
|
||||
// Explicit instantiation of functions that would otherwise be unused in this file
|
||||
// but are required for linking with other files
|
||||
template bool ScriptInterface::FromJSVal<wxString>(JSContext*, jsval, wxString&);
|
||||
template bool ScriptInterface::FromJSVal<bool>(JSContext*, jsval, bool&);
|
||||
template bool ScriptInterface::FromJSVal<float>(JSContext*, jsval, float&);
|
||||
template bool ScriptInterface::FromJSVal<jsval>(JSContext*, jsval, jsval&);
|
||||
template jsval ScriptInterface::ToJSVal<wxString>(JSContext*, wxString const&);
|
||||
|
@ -17,12 +17,24 @@
|
||||
|
||||
// Precompiled headers:
|
||||
|
||||
#ifndef _WIN32
|
||||
// GCC 4.4+ CONFIG=Release triggers linker errors on wxKeyEvent::Clone() in treeevt.h
|
||||
// with hidden visibility, so switch to default visibility when first including the
|
||||
// relevant wx headers
|
||||
// (TODO: might need to do something extra for the non-USING_PCH case)
|
||||
#pragma GCC visibility push(default)
|
||||
#endif
|
||||
|
||||
#ifdef USING_PCH
|
||||
# define WX_PRECOMP
|
||||
# include "common/main.h"
|
||||
# include "wx/wxprec.h"
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#pragma GCC visibility pop
|
||||
#endif
|
||||
|
||||
/*
|
||||
// DISABLED: because normally this DLL gets unloaded before the leak reports, which means the
|
||||
// __FILE__ strings are no longer in valid memory, which breaks everything.
|
||||
|
Loading…
Reference in New Issue
Block a user