PATCH: Add range-for iteration adapter for Function::arg_begin/end

Eli Bendersky eliben at google.com
Wed Mar 26 10:36:38 PDT 2014


Hello,

This patch is in similar vein to what done earlier to
Module::globals/aliases etc. I would really like to iterate over function
arguments like this in new code:

  for (Argument Arg : F.args()) {
    ...
  }

The question is: would it be OK to change existing code from explicit
iteration with the .args_begin/args_end idiom to this new idiom?

PTAL,
Eli
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140326/d19f1dd9/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: function-arg-iterator-range.1.patch
Type: text/x-patch
Size: 1222 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140326/d19f1dd9/attachment.bin>


More information about the llvm-commits mailing list