[PATCH] D84054: [lld][ELF] Add LOG2CEIL builtin ldscript function
George Rimar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Jul 25 01:24:00 PDT 2020
grimar added a comment.
In D84054#2172897 <https://reviews.llvm.org/D84054#2172897>, @irichter wrote:
> In D84054#2170591 <https://reviews.llvm.org/D84054#2170591>, @MaskRay wrote:
>
> > Use `llvm::Log2_64_Ceil` (llvm/Support/mathExtras.h)
>
>
> Is it preferred coding style to include the namespace in a function call, when the file already has the relevant using namespace statement? Specifically, should I be using an unqualified `return Log2_64_Ceil(...);`, or a qualified `return llvm::Log2_64_Ceil(...);` call?
Usually we use `llvm::` prefix for stl helpers/analogs. E.g `llvm::sort`. For regular funtions `llvm::` prefix is normally omitted.
A general rule - if you doubt - look around in the code base. `llvm::Log2_64_Ceil` is used in a single place, all others are using just `Log2_64_Ceil`. I think the latter is a preferable form for it.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D84054/new/
https://reviews.llvm.org/D84054
More information about the llvm-commits
mailing list