From 3f1db7af7799da2172b9b8e93b839131602ec91c Mon Sep 17 00:00:00 2001 From: Simone Date: Fri, 23 Jun 2023 09:21:03 +0200 Subject: [PATCH] Look for library functions in the current scope --- slither/solc_parsing/declarations/using_for_top_level.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/slither/solc_parsing/declarations/using_for_top_level.py b/slither/solc_parsing/declarations/using_for_top_level.py index 3b7bb280c..fe72e5780 100644 --- a/slither/solc_parsing/declarations/using_for_top_level.py +++ b/slither/solc_parsing/declarations/using_for_top_level.py @@ -111,7 +111,7 @@ class UsingForTopLevelSolc(CallerContextExpression): # pylint: disable=too-few- def _analyze_operator( self, operator: str, function_name: str, type_name: TypeAliasTopLevel ) -> None: - for tl_function in self.compilation_unit.functions_top_level: + for tl_function in self._using_for.file_scope.functions: # The library function is bound to the first parameter's type if ( tl_function.name == function_name