Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(485)

Unified Diff: base/file_path.h

Issue 11494: Generate a warning if the return value of FilePath::Append is ignored. (Closed)
Patch Set: Created 12 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/compiler_specific.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/file_path.h
diff --git a/base/file_path.h b/base/file_path.h
index 6bb426f7e1566e8f642926ecd7e578e637d689c8..1ebb299b76e9f08b06d22eef1a72829c067c7f6a 100644
--- a/base/file_path.h
+++ b/base/file_path.h
@@ -67,6 +67,7 @@
#include <string>
+#include "base/compiler_specific.h"
#include "base/basictypes.h"
// Windows-style drive letter support and pathname separator characters can be
@@ -141,7 +142,7 @@ class FilePath {
// If this object's path is kCurrentDirectory, a new FilePath corresponding
// only to |component| is returned. |component| must be a relative path;
// it is an error to pass an absolute path.
- FilePath Append(const StringType& component) const;
+ FilePath Append(const StringType& component) const WARN_UNUSED_RESULT;
// Returns true if this FilePath contains an absolute path. On Windows, an
// absolute path begins with either a drive letter specification followed by
« no previous file with comments | « base/compiler_specific.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698