Browse Source

Remove unnecessary const qualifier on return type (#221)

This solves compiler warnings given by -Wignored-qualifiers.
Lei Zhang 8 years ago
parent
commit
c9f8438d90

+ 1 - 1
include/dxc/HLSL/DxilOperations.h

@@ -74,7 +74,7 @@ public:
   static OpCode GetDxilOpFuncCallInst(const llvm::Instruction *I);
   static const char *GetOpCodeName(OpCode OpCode);
   static const char *GetAtomicOpName(DXIL::AtomicBinOpCode OpCode);
-  static const OpCodeClass GetOpCodeClass(OpCode OpCode);
+  static OpCodeClass GetOpCodeClass(OpCode OpCode);
   static const char *GetOpCodeClassName(OpCode OpCode);
   static bool IsOverloadLegal(OpCode OpCode, llvm::Type *pType);
   static bool CheckOpCodeTable();

+ 1 - 1
include/dxc/HLSL/DxilTypeSystem.h

@@ -122,7 +122,7 @@ enum class DxilParamInputQual {
 class DxilParameterAnnotation : public DxilFieldAnnotation {
 public:
   DxilParameterAnnotation();
-  const DxilParamInputQual GetParamInputQual() const;
+  DxilParamInputQual GetParamInputQual() const;
   void SetParamInputQual(DxilParamInputQual qual);
   const std::vector<unsigned> &GetSemanticIndexVec() const;
   void SetSemanticIndexVec(const std::vector<unsigned> &Vec);

+ 1 - 1
lib/HLSL/DxilOperations.cpp

@@ -299,7 +299,7 @@ const char *OP::GetAtomicOpName(DXIL::AtomicBinOpCode OpCode) {
   return AtomicBinOpCodeName[static_cast<unsigned>(OpCode)];
 }
 
-const OP::OpCodeClass OP::GetOpCodeClass(OpCode OpCode) {
+OP::OpCodeClass OP::GetOpCodeClass(OpCode OpCode) {
   DXASSERT(0 <= (unsigned)OpCode && OpCode < OpCode::NumOpCodes, "otherwise caller passed OOB index");
   return m_OpCodeProps[(unsigned)OpCode].OpCodeClass;
 }

+ 1 - 1
lib/HLSL/DxilTypeSystem.cpp

@@ -99,7 +99,7 @@ DxilParameterAnnotation::DxilParameterAnnotation()
 : m_inputQual(DxilParamInputQual::In), DxilFieldAnnotation() {
 }
 
-const DxilParamInputQual DxilParameterAnnotation::GetParamInputQual() const {
+DxilParamInputQual DxilParameterAnnotation::GetParamInputQual() const {
   return m_inputQual;
 }
 void DxilParameterAnnotation::SetParamInputQual(DxilParamInputQual qual) {