aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/api/Asset.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/crepe/api/Asset.cpp')
-rw-r--r--src/crepe/api/Asset.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/crepe/api/Asset.cpp b/src/crepe/api/Asset.cpp
index 1887814..5271cf7 100644
--- a/src/crepe/api/Asset.cpp
+++ b/src/crepe/api/Asset.cpp
@@ -48,6 +48,10 @@ string Asset::whereami() const noexcept {
return path;
}
+bool Asset::operator==(const Asset & other) const noexcept {
+ return this->src == other.src;
+}
+
size_t std::hash<const Asset>::operator()(const Asset & asset) const noexcept {
return std::hash<string>{}(asset.get_path());
};