mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 07:47:35 +00:00
AK: Fix typos
This commit is contained in:
parent
97d27c312a
commit
5e21759f3d
1 changed files with 4 additions and 4 deletions
|
@ -318,7 +318,7 @@ public:
|
||||||
return sizeof(R);
|
return sizeof(R);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Arithmetics
|
// Arithmetic
|
||||||
|
|
||||||
// implies size of less than u64, so passing references isn't useful
|
// implies size of less than u64, so passing references isn't useful
|
||||||
template<Unsigned U>
|
template<Unsigned U>
|
||||||
|
@ -676,18 +676,18 @@ public:
|
||||||
|
|
||||||
constexpr size_t log2()
|
constexpr size_t log2()
|
||||||
{
|
{
|
||||||
// FIXME: propper rounding
|
// FIXME: proper rounding
|
||||||
return sizeof(R) - clz();
|
return sizeof(R) - clz();
|
||||||
}
|
}
|
||||||
constexpr size_t logn(u64 base)
|
constexpr size_t logn(u64 base)
|
||||||
{
|
{
|
||||||
// FIXME: propper rounding
|
// FIXME: proper rounding
|
||||||
return log2() / (sizeof(u64) - __builtin_clzll(base));
|
return log2() / (sizeof(u64) - __builtin_clzll(base));
|
||||||
}
|
}
|
||||||
template<Unsigned U>
|
template<Unsigned U>
|
||||||
requires(sizeof(U) > sizeof(u64)) constexpr size_t logn(U base)
|
requires(sizeof(U) > sizeof(u64)) constexpr size_t logn(U base)
|
||||||
{
|
{
|
||||||
// FIXME: propper rounding
|
// FIXME: proper rounding
|
||||||
return log2() / base.log2();
|
return log2() / base.log2();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue