[PATCH] D19111: [ELF] - Remove OutputSectionFactory::lookup method

George Rimar via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 14 07:09:10 PDT 2016


grimar added a comment.

In http://reviews.llvm.org/D19111#401074, @rafael wrote:

> How about just defining it inline?
>
> One of the annoyances of the Map interface is the just using [] adds
>  an entry. Having the Map be private means we only have to look at a
>  few places to know that we don't accidentally create entries when we
>  don't want to: the two visible methods are named create and lookup.
>
> Cheers,
> Rafael


Ok. Motivation to keep it private under guard of method call was clear,
I just assumed we will not use [] to have that effect :)


http://reviews.llvm.org/D19111





More information about the llvm-commits mailing list