[rust] Remove constexpr from functions that call non-constexpr functions
The CHECK macros will call non-constexpr functions on failure. While this is legal C++14 as long as the function doesn't actually get called, GCC 5.4 will choke on it.
This commit is contained in:
parent
783da8c589
commit
aaee1d2723
|
@ -443,7 +443,7 @@ inline uptr RoundUpToPowerOfTwo(uptr size) {
|
|||
return 1ULL << (up + 1);
|
||||
}
|
||||
|
||||
inline constexpr uptr RoundUpTo(uptr size, uptr boundary) {
|
||||
inline uptr RoundUpTo(uptr size, uptr boundary) {
|
||||
RAW_CHECK(IsPowerOfTwo(boundary));
|
||||
return (size + boundary - 1) & ~(boundary - 1);
|
||||
}
|
||||
|
|
|
@ -61,7 +61,7 @@ class StackStore {
|
|||
return frame_idx % kBlockSizeFrames;
|
||||
}
|
||||
|
||||
static constexpr uptr IdToOffset(Id id) {
|
||||
static uptr IdToOffset(Id id) {
|
||||
CHECK_NE(id, 0);
|
||||
return id - 1; // Avoid zero as id.
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue