From 3b99f598caf8fc1057ab2998c9d36785f371b695 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20=C5=9Aliwak?= Date: Fri, 25 Aug 2023 14:49:40 +0200 Subject: [PATCH] fixup! Traverse object tree --- libyul/Object.cpp | 6 +++++- libyul/Object.h | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/libyul/Object.cpp b/libyul/Object.cpp index 7833ba759..e357e1561 100644 --- a/libyul/Object.cpp +++ b/libyul/Object.cpp @@ -145,7 +145,11 @@ set Object::qualifiedDataNames() const return qualifiedNames; } -void Object::traverseObjectTree(Object const* _object, YulString _qualifiedName, std::function _visitor) +void Object::traverseObjectTree( + Object const* _object, + YulString _qualifiedName, + std::function const& _visitor +) { yulAssert(!_qualifiedName.empty(), ""); diff --git a/libyul/Object.h b/libyul/Object.h index d37d6c70b..131b2b5d5 100644 --- a/libyul/Object.h +++ b/libyul/Object.h @@ -122,7 +122,7 @@ public: static void traverseObjectTree( Object const* _object, YulString _qualifiedName, - std::function _visitor + std::function const& _visitor ); /// sub id for object if it is subobject of another object, max value if it is not subobject