Simplify the ComputeLinearIndex logic and fix a few bugs.
[oota-llvm.git] / lib / Support / ManagedStatic.cpp
index 85daaf8ba525f0949d4ec9e966ceb65bfc4c13d0..c365e013c6fccbbae1d32c017be546c7276cefeb 100644 (file)
@@ -2,8 +2,8 @@
 //
 //                     The LLVM Compiler Infrastructure
 //
-// This file was developed by Chris Lattner and is distributed under
-// the University of Illinois Open Source License. See LICENSE.TXT for details.
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
 //
 //===----------------------------------------------------------------------===//
 //
@@ -30,7 +30,7 @@ void ManagedStaticBase::RegisterManagedStatic(void *ObjPtr,
 }
 
 void ManagedStaticBase::destroy() const {
-  assert(Ptr && DeleterFn && "ManagedStatic not initialized correctly!");
+  assert(DeleterFn && "ManagedStatic not initialized correctly!");
   assert(StaticList == this &&
          "Not destroyed in reverse order of construction?");
   // Unlink from list.
@@ -46,7 +46,7 @@ void ManagedStaticBase::destroy() const {
 }
 
 /// llvm_shutdown - Deallocate and destroy all ManagedStatic variables.
-void llvm_shutdown() {
+void llvm::llvm_shutdown() {
   while (StaticList)
     StaticList->destroy();
 }