diff --git a/src/script_opt/ProfileFunc.h b/src/script_opt/ProfileFunc.h index a11660b639..bb2110f864 100644 --- a/src/script_opt/ProfileFunc.h +++ b/src/script_opt/ProfileFunc.h @@ -18,13 +18,20 @@ public: ProfileFunc(bool _compute_hash = false) { compute_hash = _compute_hash; } - std::unordered_set& Globals() { return globals; } - std::unordered_set& Locals() { return locals; } - std::unordered_set& Inits() { return inits; } - std::unordered_set& ScriptCalls() { return script_calls; } - std::unordered_set& BiFCalls() { return BiF_calls; } - std::unordered_set& WhenCalls() { return when_calls; } - std::unordered_set& Events() { return events; } + const std::unordered_set& Globals() const + { return globals; } + const std::unordered_set& Locals() const + { return locals; } + const std::unordered_set& Inits() const + { return inits; } + const std::unordered_set& ScriptCalls() const + { return script_calls; } + const std::unordered_set& BiFCalls() const + { return BiF_calls; } + const std::unordered_set& WhenCalls() const + { return when_calls; } + const std::unordered_set& Events() const + { return events; } bool DoesIndirectCalls() { return does_indirect_calls; } std::size_t HashVal() { return hash_val; }