Merge pull request #2373 from majorteach/master

chore: remove repetitive words
frabert/fix-offsets-from-thing-contract
alpharush 8 months ago committed by GitHub
commit 13d7d9f66a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 2
      slither/core/declarations/contract.py
  2. 2
      slither/vyper_parsing/declarations/function.py

@ -894,7 +894,7 @@ class Contract(SourceMapping): # pylint: disable=too-many-public-methods
def get_function_from_canonical_name(self, canonical_name: str) -> Optional["Function"]:
"""
Return a function from a a canonical name (contract.signature())
Return a function from a canonical name (contract.signature())
Args:
canonical_name (str): canonical name of the function (without return statement)
Returns:

@ -554,7 +554,7 @@ class FunctionVyper: # pylint: disable=too-many-instance-attributes
def _parse_returns(self, returns: Union[Name, TupleVyper, Subscript]):
self._function.returns_src().set_offset(returns.src, self._function.compilation_unit)
# Only the type of the arg is given, not a name. We create an an `Arg` with an empty name
# Only the type of the arg is given, not a name. We create an `Arg` with an empty name
# so that the function has the correct return type in its signature but doesn't clash with
# other identifiers during name resolution (`find_variable`).
if isinstance(returns, (Name, Subscript)):

Loading…
Cancel
Save