瀏覽代碼

Fix OP::GetTypeName = used in if instead of == causing assert.

Tex Riddell 7 年之前
父節點
當前提交
005c534977
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      lib/HLSL/DxilOperations.cpp

+ 1 - 1
lib/HLSL/DxilOperations.cpp

@@ -360,7 +360,7 @@ const char * OP::GetTypeName(Type *Ty, std::string &str) {
   unsigned TypeSlot = OP::GetTypeSlot(Ty);
   if (TypeSlot < kUserDefineTypeSlot) {
     return GetOverloadTypeName(TypeSlot);
-  } else if (TypeSlot = kObjectTypeSlot) {
+  } else if (TypeSlot == kObjectTypeSlot) {
     StructType *ST = cast<StructType>(Ty);
     return ST->getStructName().data();
   } else {