Closed kimikage closed 5 years ago
In MSVC, the header file util.h defines a function __builtin_clz(). Since it is not a inline function, a multiple definition error LNK2005 can occur. https://github.com/lemire/FastPFor/blob/d873fe18edf487ff7e4e737883e6f63a54a0a578/headers/util.h#L117-L126
util.h
__builtin_clz()
LNK2005
A possible solution is adding the inline to the function:
inline
inline uint32_t __builtin_clz(uint32_t x) {
Would you issue a PR? This way you get credit for your contribution.
In MSVC, the header file
util.h
defines a function__builtin_clz()
. Since it is not a inline function, a multiple definition errorLNK2005
can occur. https://github.com/lemire/FastPFor/blob/d873fe18edf487ff7e4e737883e6f63a54a0a578/headers/util.h#L117-L126A possible solution is adding the
inline
to the function: