Cleanup these asserts to follow common LLVM style and coding
authorChandler Carruth <chandlerc@gmail.com>
Tue, 10 Jan 2012 18:18:52 +0000 (18:18 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Tue, 10 Jan 2012 18:18:52 +0000 (18:18 +0000)
conventions. Also, clarify the grouping of one of the asserts to silence
-Wparentheses.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@147863 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/DIBuilder.cpp

index 00ba602bbd67b8d3d67022d64ce582740f570571..5e94d899b9e160773c99201a9208fc90106c896c 100644 (file)
@@ -76,11 +76,11 @@ void DIBuilder::createCompileUnit(unsigned Lang, StringRef Filename,
                                   StringRef Directory, StringRef Producer,
                                   bool isOptimized, StringRef Flags,
                                   unsigned RunTimeVer) {
-  assert ((Lang <= dwarf::DW_LANG_Python && Lang >= dwarf::DW_LANG_C89
-         || Lang <= dwarf::DW_LANG_hi_user && Lang >= dwarf::DW_LANG_lo_user)
-         && "Invalid Language tag");
-  assert (!Filename.empty() 
-         && "Unable to create compile unit without filename");
+  assert(((Lang <= dwarf::DW_LANG_Python && Lang >= dwarf::DW_LANG_C89) ||
+          (Lang <= dwarf::DW_LANG_hi_user && Lang >= dwarf::DW_LANG_lo_user)) &&
+         "Invalid Language tag");
+  assert(!Filename.empty() &&
+         "Unable to create compile unit without filename");
   Value *TElts[] = { GetTagConstant(VMContext, DW_TAG_base_type) };
   TempEnumTypes = MDNode::getTemporary(VMContext, TElts);
   Value *THElts[] = { TempEnumTypes };