simplify code


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30661 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/tools/llvm2cpp/CppWriter.cpp b/tools/llvm2cpp/CppWriter.cpp
index 66ed5b2..85c1ec7 100644
--- a/tools/llvm2cpp/CppWriter.cpp
+++ b/tools/llvm2cpp/CppWriter.cpp
@@ -677,8 +677,7 @@
   }
   if (const ConstantBool *CB = dyn_cast<ConstantBool>(CV)) {
     Out << "ConstantBool* " << constName << " = ConstantBool::get(" 
-        << (CB == ConstantBool::True ? "true" : "false")
-        << ");";
+        << (CB->getValue() ? "true" : "false") << ");";
   } else if (const ConstantSInt *CI = dyn_cast<ConstantSInt>(CV)) {
     Out << "ConstantSInt* " << constName << " = ConstantSInt::get(" 
         << typeName << ", " << CI->getValue() << ");";