aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr/flake/flakeref.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/libexpr/flake/flakeref.hh')
-rw-r--r--src/libexpr/flake/flakeref.hh6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/libexpr/flake/flakeref.hh b/src/libexpr/flake/flakeref.hh
index 52bb82ddb..082dd8c26 100644
--- a/src/libexpr/flake/flakeref.hh
+++ b/src/libexpr/flake/flakeref.hh
@@ -176,6 +176,12 @@ struct FlakeRef
bool isImmutable() const;
FlakeRef baseRef() const;
+
+ bool isDirty() const
+ {
+ return std::get_if<FlakeRef::IsPath>(&data)
+ && rev == Hash(rev->type);
+ }
};
std::ostream & operator << (std::ostream & str, const FlakeRef & flakeRef);