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

Unified Diff: components/sync/model/model_error.h

Issue 2623723002: [Sync] Remove ModelError::IsSet() in favor of base::Optional. (Closed)
Patch Set: Rebase. Created 3 years, 11 months 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
Index: components/sync/model/model_error.h
diff --git a/components/sync/model/model_error.h b/components/sync/model/model_error.h
index ebd0dae57076d0b5e2c5fb5b5fd90204edd6e3d9..6c3536e4ca41add916bdd09dfe75f216f17a750d 100644
--- a/components/sync/model/model_error.h
+++ b/components/sync/model/model_error.h
@@ -15,18 +15,12 @@ namespace syncer {
// A minimal error object for use by USS model type code.
class ModelError {
public:
- // Creates an un-set error object (indicating an operation was successful).
- ModelError();
-
// Creates a set error object with the given location and message.
ModelError(const tracked_objects::Location& location,
const std::string& message);
~ModelError();
- // Whether this object represents an actual error.
- bool IsSet() const;
-
// The location of the error this object represents. Can only be called if the
// error is set.
const tracked_objects::Location& location() const;
@@ -36,7 +30,6 @@ class ModelError {
const std::string& message() const;
private:
- bool is_set_;
tracked_objects::Location location_;
std::string message_;
};

Powered by Google App Engine
This is Rietveld 408576698