[Lldb-commits] [lldb] r252378 - lldb/ADT: Remove implicit ilist iterator conversions, NFC

Duncan P. N. Exon Smith via lldb-commits lldb-commits at lists.llvm.org
Fri Nov 6 16:54:14 PST 2015


Author: dexonsmith
Date: Fri Nov  6 18:54:13 2015
New Revision: 252378

URL: http://llvm.org/viewvc/llvm-project?rev=252378&view=rev
Log:
lldb/ADT: Remove implicit ilist iterator conversions, NFC

Remove implicit ilist iterator conversions before reapplying r252372
(which will disallow them).

Modified:
    lldb/trunk/source/Expression/IRInterpreter.cpp
    lldb/trunk/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp

Modified: lldb/trunk/source/Expression/IRInterpreter.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Expression/IRInterpreter.cpp?rev=252378&r1=252377&r2=252378&view=diff
==============================================================================
--- lldb/trunk/source/Expression/IRInterpreter.cpp (original)
+++ lldb/trunk/source/Expression/IRInterpreter.cpp Fri Nov  6 18:54:13 2015
@@ -498,7 +498,7 @@ IRInterpreter::CanInterpret (llvm::Modul
             default:
                 {
                     if (log)
-                        log->Printf("Unsupported instruction: %s", PrintValue(ii).c_str());
+                        log->Printf("Unsupported instruction: %s", PrintValue(&*ii).c_str());
                     error.SetErrorToGenericError();
                     error.SetErrorString(unsupported_opcode_error);
                     return false;
@@ -522,7 +522,7 @@ IRInterpreter::CanInterpret (llvm::Modul
                     if (!CanIgnoreCall(call_inst) && !support_function_calls)
                     {
                         if (log)
-                            log->Printf("Unsupported instruction: %s", PrintValue(ii).c_str());
+                            log->Printf("Unsupported instruction: %s", PrintValue(&*ii).c_str());
                         error.SetErrorToGenericError();
                         error.SetErrorString(unsupported_opcode_error);
                         return false;
@@ -547,7 +547,7 @@ IRInterpreter::CanInterpret (llvm::Modul
                     default:
                     {
                         if (log)
-                            log->Printf("Unsupported ICmp predicate: %s", PrintValue(ii).c_str());
+                            log->Printf("Unsupported ICmp predicate: %s", PrintValue(&*ii).c_str());
 
                         error.SetErrorToGenericError();
                         error.SetErrorString(unsupported_opcode_error);
@@ -663,16 +663,16 @@ IRInterpreter::Interpret (llvm::Module &
 
         lldb::addr_t ptr = args[arg_index];
 
-        frame.MakeArgument(ai, ptr);
+        frame.MakeArgument(&*ai, ptr);
     }
 
     uint32_t num_insts = 0;
 
-    frame.Jump(function.begin());
+    frame.Jump(&function.front());
 
     while (frame.m_ii != frame.m_ie && (++num_insts < 4096))
     {
-        const Instruction *inst = frame.m_ii;
+        const Instruction *inst = &*frame.m_ii;
 
         if (log)
             log->Printf("Interpreting %s", PrintValue(inst).c_str());

Modified: lldb/trunk/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp?rev=252378&r1=252377&r2=252378&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp (original)
+++ lldb/trunk/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp Fri Nov  6 18:54:13 2015
@@ -338,7 +338,7 @@ IRForTarget::ResolveFunctionPointers(llv
          fi != llvm_module.end();
          ++fi)
     {
-        Function *fun = fi;
+        Function *fun = &*fi;
 
         bool is_decl = fun->isDeclaration();
 
@@ -1955,7 +1955,7 @@ IRForTarget::ReplaceStaticLiterals (llvm
             if (operand_constant_fp/* && operand_constant_fp->getType()->isX86_FP80Ty()*/)
             {
                 static_constants.push_back(operand_val);
-                static_users.push_back(ii);
+                static_users.push_back(&*ii);
             }
         }
     }
@@ -2280,7 +2280,7 @@ IRForTarget::ReplaceVariables (Function
         return false;
     }
 
-    Argument *argument = iter;
+    Argument *argument = &*iter;
 
     if (argument->getName().equals("this"))
     {
@@ -2294,7 +2294,7 @@ IRForTarget::ReplaceVariables (Function
             return false;
         }
 
-        argument = iter;
+        argument = &*iter;
     }
     else if (argument->getName().equals("self"))
     {
@@ -2326,7 +2326,7 @@ IRForTarget::ReplaceVariables (Function
             return false;
         }
 
-        argument = iter;
+        argument = &*iter;
     }
 
     if (!argument->getName().equals("$__lldb_arg"))
@@ -2624,7 +2624,7 @@ IRForTarget::runOnModule (Module &llvm_m
          fi != fe;
          ++fi)
     {
-        llvm::Function *function = fi;
+        llvm::Function *function = &*fi;
 
         if (function->begin() == function->end())
             continue;
@@ -2699,7 +2699,7 @@ IRForTarget::runOnModule (Module &llvm_m
          fi != fe;
          ++fi)
     {
-        llvm::Function *function = fi;
+        llvm::Function *function = &*fi;
 
         for (llvm::Function::iterator bbi = function->begin(), bbe = function->end();
              bbi != bbe;
@@ -2721,7 +2721,7 @@ IRForTarget::runOnModule (Module &llvm_m
          fi != fe;
          ++fi)
     {
-        llvm::Function *function = fi;
+        llvm::Function *function = &*fi;
 
         for (llvm::Function::iterator bbi = function->begin(), bbe = function->end();
              bbi != bbe;




More information about the lldb-commits mailing list