The definition of write_int function differs from its declaration in bits struct:
static void write_int(uint64_t* word, uint64_t x, const uint8_t offset=0, const uint8_t len=64);
...
inline void bits::write_int(uint64_t* word, uint64_t x, uint8_t offset, const uint8_t len)
{
...
}
Since offset is modified inside write_int, it cannot be const. This results the following error when compiling with nvcc(11.4)/gcc(10.5):
so-76943386.cpp(29): error: expression must be a modifiable lvalue
detected during instantiation of "void bits_impl<T>::write_int(uint64_t *, uint64_t, uint8_t, uint8_t) [with T=void]"
(63): here
1 error detected in the compilation of "so-76943386.cpp".
The definition of
write_intfunction differs from its declaration inbitsstruct:Since
offsetis modified insidewrite_int, it cannot beconst. This results the following error when compiling with nvcc(11.4)/gcc(10.5):