]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
Improve documentation of util::read_file/write_file
authorJoel Rosdahl <joel@rosdahl.net>
Sat, 24 Aug 2019 20:34:23 +0000 (22:34 +0200)
committerJoel Rosdahl <joel@rosdahl.net>
Thu, 5 Sep 2019 20:04:43 +0000 (22:04 +0200)
src/util.hpp

index 4753d2a1428b02a96bb5c03ec0b507f21ff80e40..c3d58417a7abef2b7ecf71e9f2c393e4536fb976 100644 (file)
@@ -31,6 +31,8 @@ std::string base_name(const std::string& path);
 std::string dir_name(const std::string& path);
 
 // Read file data as a string.
+//
+// Throws Error on error.
 std::string read_file(const std::string& path);
 
 // Return true if prefix is a prefix of string.
@@ -44,6 +46,8 @@ strip_whitespace(const std::string& string);
 [[gnu::warn_unused_result]] std::string to_lowercase(const std::string& string);
 
 // Write file data from a string.
+//
+// Throws Error on error.
 void write_file(const std::string& path,
                 const std::string& data,
                 bool binary = false);