Expand a lambda that is used only once.
Details
Details
Diff Detail
Diff Detail
- Repository
- rLLD LLVM Linker
Event Timeline
Comment Actions
I was considering doing that myself, and managed to persuade myself it was more readable with the lamda since it makes the loop itself self-documenting and really easy to read. But I can see that single use lambda are probably not a good pattern and that a commit is probably just as good. BTW, do you now if there is any runtime different between these two (given a decent compiler)?
Comment Actions
I didn't actually try to see the assembly output for this file, but decent compilers are smart enough to figure out that the lambda can be inlined, so I don't think this change doesn't improve performance.