summaryrefslogtreecommitdiff
path: root/src/Hash.cpp
Commit message (Collapse)AuthorAgeFilesLines
* refactor: Use util::{read_fd,read_file,write_file} functionsJoel Rosdahl2022-08-151-6/+6
|
* ci: Bump Clang-Tidy job to Clang-Tidy 12Joel Rosdahl2022-06-081-1/+1
|
* chore: Replace nonstd::string_view with std::string_viewJoel Rosdahl2022-05-231-12/+10
|
* Remove system.hpp, including what’s needed insteadJoel Rosdahl2021-07-071-0/+10
| | | | This is the next step after a57f70eda32e99221de56f5499079b4f00dc2bc5.
* Don’t capture “this” implicitlyJoel Rosdahl2021-01-031-2/+2
| | | | | This avoids an “implicit capture of 'this' via '[=]' is deprecated” warning when building for C++20 and does no harm for earlier versions.
* Detect errors in fmt::format format strings at compile timeJoel Rosdahl2020-10-231-1/+2
| | | | See also 4413d842e23c6fa52ec411951a4ab442f42227de.
* Detect errors in log strings at compile timeJoel Rosdahl2020-10-231-2/+1
| | | | | | | | | | | | | | | | | | | fmtlib can detect format string errors at compile time if (1) applying FMT_STRING to the format string literal and (2) compiling for C++14 or higher. Requirement 1 is implemented by introducing a LOG macro which applies FMT_STRING to the first argument and calls Logging::log (if logging is enabled). Also added are a companion LOG_RAW macro (since C++11 requires at least one argument for the “...” part in variadic macros) and a BULK_LOG macro which calls Logging::bulk_log (if logging is enabled). Requirement 2 is implemented by setting CMAKE_CXX_STANDARD to 14 for one CI build with a known C++14-capable compiler. We can’t set it to 14 by default since we still want the code to be buildable with C++11 compilers. This will catch errors such as the one fixed by PR #691.
* Rename Util::format_hex to format_base16Joel Rosdahl2020-09-231-1/+2
|
* Use “using nonstd::*” consistentlyJoel Rosdahl2020-09-051-1/+1
|
* Add and use Util::read_fd helper functionJoel Rosdahl2020-08-061-13/+2
|
* Pretty-print binary data in .ccache-input-text filesJoel Rosdahl2020-08-061-3/+11
| | | | This happens when the i-node cache is enabled.
* Convert cc_log calls to Logging::logJoel Rosdahl2020-08-031-1/+2
|
* C++-ify logging routinesJoel Rosdahl2020-08-031-1/+1
| | | | | | | | | | | | | | | - Simplified and C++-ified logging code. - Added Logging::log and Logging::bulk_log functions corresponding to the old cc_log and cc_bulklog functions. The new functions pass their arguments to fmt::format. - Replacements: * init_log → Logging::init * cc_log → Logging::log * cc_bulklog → Logging::bulk_log * cc_log_argv → Logging::log plus Util::format_argv_for_logging * cc_dump_debug_log_buffer -> Logging::dump_log - A legacy cc_log implementation is still available so that logging can be converted gradually to the new functionality.
* C++-ify struct hashJoel Rosdahl2020-07-091-0/+141