Subzero: Change llvm::OwningPtr to C++11's std::unique_ptr.
While I'm at it, normalize the #include order:
1. C++ library headers
2. LLVM headers
3. Subzero headers
A blank line between each group. Each group sorted alphabetically, case-insensitive.
BUG= https://code.google.com/p/nativeclient/issues/detail?id=3930
R=jfb@chromium.org, jvoung@chromium.org
Review URL: https://codereview.chromium.org/622443002
diff --git a/src/IceTranslator.cpp b/src/IceTranslator.cpp
index 91dcfd4..9cc97a0 100644
--- a/src/IceTranslator.cpp
+++ b/src/IceTranslator.cpp
@@ -12,16 +12,18 @@
//
//===----------------------------------------------------------------------===//
+#include <iostream>
+#include <memory>
+
+#include "llvm/IR/Constant.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/Module.h"
+
#include "IceCfg.h"
#include "IceClFlags.h"
#include "IceDefs.h"
#include "IceTargetLowering.h"
#include "IceTranslator.h"
-#include "llvm/IR/Module.h"
-#include "llvm/IR/Constant.h"
-#include "llvm/IR/Constants.h"
-
-#include <iostream>
using namespace Ice;
@@ -96,7 +98,7 @@
}
void Translator::convertGlobals(llvm::Module *Mod) {
- llvm::OwningPtr<TargetGlobalInitLowering> GlobalLowering(
+ std::unique_ptr<TargetGlobalInitLowering> GlobalLowering(
TargetGlobalInitLowering::createLowering(Ctx->getTargetArch(), Ctx));
for (llvm::Module::const_global_iterator I = Mod->global_begin(),
E = Mod->global_end();