From 402fcc5edf16378feae57c2e7a0b0dc8f5bd11e4 Mon Sep 17 00:00:00 2001 From: Glenn Watson Date: Tue, 9 Dec 2014 13:12:39 +1000 Subject: [PATCH] Fix compile on android build, which uses strongly typed enums. With strongly typed enums that are of different size, neither static_cast nor reinterpret_cast by themselves are enough, so static_cast to an int and then to the desired type. --- src/azure-c.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/azure-c.cpp b/src/azure-c.cpp index 8e8207d..f69e062 100644 --- a/src/azure-c.cpp +++ b/src/azure-c.cpp @@ -291,7 +291,7 @@ AzDrawTargetGetSize(AzDrawTargetRef aDrawTarget) { extern "C" AzSurfaceFormat AzDrawTargetGetFormat(AzDrawTargetRef aDrawTarget) { gfx::DrawTarget *gfxDrawTarget = static_cast(aDrawTarget); - return static_cast(gfxDrawTarget->GetFormat()); + return static_cast(static_cast(gfxDrawTarget->GetFormat())); } extern "C" void