summaryrefslogtreecommitdiff
path: root/src/units.hh
AgeCommit message (Collapse)Author
2025-05-11Fix compiler warning on space in string-literal suffix defJohannes Altmanninger
GCC complains: src/string.hh:376:39: warning: space between quotes and suffix is deprecated in C++23 [-Wdeprecated-literal-operator] 376 | inline constexpr StringView operator"" _sv(const char* str, size_t) | ^~
2024-12-04Use default comparison impl for LineAndColumn and StronglyTypedNumberMaxime Coste
This is a bit simpler and should leave more leeway to the optimizer to detect it can compare the whole struct.
2024-08-16include headers cleanupAdrià Arrufat
2023-01-21Revert "Remove compare include that seems to break clang"Maxime Coste
Looks clang breaks differently when this is not included This reverts commit 7030b3c47c7f8c246c1f830631accd226f7a0bbc.
2023-01-21Remove compare include that seems to break clangMaxime Coste
2022-12-15Support adding ByteCount to void/char pointers without castingMaxime Coste
2021-11-21Try to fix more CI failures related to C++20Maxime Coste
2021-11-21Fix clang C++20 compilation issuesMaxime Coste
2021-11-21Convert comparisons to spaceship operatorMaxime Coste
2017-10-20Constexprify various hash functionsMaxime Coste
2017-01-29Make StringView and unit types trivial typesMaxime Coste
2016-10-01Support codepoints of variable widthMaxime Coste
Add a ColumnCount type and use it in place of CharCount whenever more appropriate, take column size of codepoints into account for vertical movements and docstring wrapping. Fixes #811
2016-04-27Add checked, explicit conversion from strongly typed number for size_tMaxime Coste
2015-12-27Fix uses of non-keyword logical operators (replace &&, || and ! with and, or ↵Maxime Coste
and not)
2015-05-13Use friend functions rather than methods for StronglyTypedNumber binary opsMaxime Coste
2015-04-17Fix StronglyTypedNumbers::absMaxime Coste
2015-04-13Add a 'abs' friend function to StronglyTypedNumberMaxime Coste
2015-03-11coords/units hashing refactoringMaxime Coste
2014-12-16Rework hashing, use a more extensible framework similar to n3876 proposalMaxime Coste
std::hash specialization is a pain to work with, stop using that, and just specialize a 'size_t hash_value(const T&)' free function.
2014-05-17set Coords/Counts methods as always_inlineMaxime Coste
They are well tested, and we never want to step into them when debugging
2013-11-14indent cleanup, correct erroneous 3 spaces indentMaxime Coste
2013-11-11Fix StronglyTypedInteger::operator%=Maxime Coste
2013-11-06Add modulo operators to StronglyTypedNumberMaxime Coste
2013-07-26StronglyTypedNumber: take parameters by valueMaxime Coste
2013-03-27use only one constructor with a default parameter for unitsMaxime Coste
2013-03-26add default zero construction to unitsMaxime Coste
2013-01-14rename StronglyTypedInteger to more accurate StronglyTypedNumberMaxime Coste
2013-01-04various code style fixesMaxime Coste
2012-10-11Add a ByteCount unitMaxime Coste
2012-10-02fix postfix StronglyTypedInteger::operator{++,--}Maxime Coste
2012-10-02do not use our broken safe bool, c++11 explicit bool conversion is betterMaxime Coste
2012-09-04use more constexprMaxime Coste
2012-08-23use a strongly typed int CharCount for character countsMaxime Coste
2012-08-22use a strongly typed int LineCount for line countsMaxime Coste