[cfe-commits] [PATCH] PR14471: Debug info for static data members (Clang part)

Eric Christopher echristo at gmail.com
Fri Jan 4 21:33:43 PST 2013


On Fri, Jan 4, 2013 at 1:45 PM, Robinson, Paul <Paul.Robinson at am.sony.com>wrote:

>
>
>>     > b) Instead of inlining all the code for CollectRecordStaticVars
>> how about outlining it into a couple of static functions?
>>
>>  Hmm, yeah the body of that loop is basically "if static-member do this;
>> else if field do that;" so factoring out those bits seems reasonable.  (The
>> lambda part, which I didn't touch, probably also could be factored out for
>> similar reasons, but that might exceed the scope of what I'm doing with
>> this patch.  Let me know.)
>>
>>
>
>  > Yes please, thanks.
>
> It turns out to be infeasible to make these static functions, because they
> use private data and methods from class CGDebugInfo.  Do you want me to do
> the outlining as new private methods, or just leave everything inline
> within CollectRecordFields?  I will say that the refactoring does make
> things look cleaner.
>
>
New private methods will be fine, thanks. :)

-eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130104/7ace2651/attachment.html>


More information about the cfe-commits mailing list