Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(15)

Unified Diff: src/PNaClTranslator.cpp

Issue 1516753008: Subzero: Use "auto" per (unwritten) auto coding style. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: More <cast> instances without the llvm:: prefix Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/IceTargetLoweringX86BaseImpl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/PNaClTranslator.cpp
diff --git a/src/PNaClTranslator.cpp b/src/PNaClTranslator.cpp
index 0f40df5d77fcdc26e7366405109699e22e3cd4ec..bdb524c4394d90f9bcaef5697fa1b4cdba3c7f9e 100644
--- a/src/PNaClTranslator.cpp
+++ b/src/PNaClTranslator.cpp
@@ -984,7 +984,7 @@ void TypesParser::ProcessRecord() {
Error("Function type can't define varargs");
ExtendedType *Ty = Context->getTypeByIDForDefining(NextTypeId++);
Ty->setAsFunctionType();
- FuncSigExtendedType *FuncTy = cast<FuncSigExtendedType>(Ty);
+ auto *FuncTy = cast<FuncSigExtendedType>(Ty);
FuncTy->setReturnType(Context->getSimpleTypeByID(Values[1]));
for (size_t i = 2, e = Values.size(); i != e; ++i) {
// Check that type void not used as argument type. Note: PNaCl
@@ -1530,7 +1530,7 @@ private:
if (LocalIndex < LocalOperands.size()) {
Ice::Operand *Op = LocalOperands[LocalIndex];
if (Op != nullptr) {
- if (Ice::Variable *Var = dyn_cast<Ice::Variable>(Op)) {
+ if (auto *Var = dyn_cast<Ice::Variable>(Op)) {
if (Var->getType() == Ty) {
++NextLocalInstIndex;
return Var;
@@ -3070,7 +3070,7 @@ void FunctionValuesymtabParser::setValueName(NaClBcIndexSize_t Index,
if (isIRGenerationDisabled())
return;
Ice::Operand *Op = getFunctionParser()->getOperand(Index);
- if (Ice::Variable *V = dyn_cast<Ice::Variable>(Op)) {
+ if (auto *V = dyn_cast<Ice::Variable>(Op)) {
if (Ice::BuildDefs::dump()) {
std::string Nm(Name.data(), Name.size());
V->setName(getFunctionParser()->getFunc(), Nm);
@@ -3266,7 +3266,7 @@ void ModuleParser::ProcessRecord() {
return;
}
bool IsProto = Values[2] == 1;
- Ice::FunctionDeclaration *Func = Ice::FunctionDeclaration::create(
+ auto *Func = Ice::FunctionDeclaration::create(
Context->getTranslator().getContext(), Signature, CallingConv, Linkage,
IsProto);
Context->setNextFunctionID(Func);
« no previous file with comments | « src/IceTargetLoweringX86BaseImpl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698