From: David Greene Date: Mon, 14 Jan 2013 21:04:42 +0000 (+0000) Subject: Fix Another Cast X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=ef44c353599e0e2fd5b2ec2ae5d9bc0e2a355cad;p=oota-llvm.git Fix Another Cast Properly cast code to eliminate cast-away-const errors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172468 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/Hexagon/HexagonISelLowering.cpp b/lib/Target/Hexagon/HexagonISelLowering.cpp index 16cec5cfe5d..4c27d356bd0 100644 --- a/lib/Target/Hexagon/HexagonISelLowering.cpp +++ b/lib/Target/Hexagon/HexagonISelLowering.cpp @@ -1017,7 +1017,8 @@ SDValue HexagonTargetLowering::LowerGLOBALADDRESS(SDValue Op, Result = DAG.getTargetGlobalAddress(GV, dl, getPointerTy(), Offset); HexagonTargetObjectFile &TLOF = - (HexagonTargetObjectFile&)getObjFileLowering(); + static_cast( + const_cast(getObjFileLowering())); if (TLOF.IsGlobalInSmallSection(GV, getTargetMachine())) { return DAG.getNode(HexagonISD::CONST32_GP, dl, getPointerTy(), Result); }