Skip to content

Commit

Permalink
refactor attr access since type is refined
Browse files Browse the repository at this point in the history
  • Loading branch information
cyberthirst committed Jul 28, 2024
1 parent 0799020 commit f006571
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vyper/semantics/types/function.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ def from_vyi(cls, funcdef: vy_ast.FunctionDef) -> "ContractFunctionT":
body = funcdef.body

Check warning on line 347 in vyper/semantics/types/function.py

View check run for this annotation

Codecov / codecov/patch

vyper/semantics/types/function.py#L347

Added line #L347 was not covered by tests

if len(body) != 1 or not (
isinstance(body[0], vy_ast.Expr) and isinstance(body[0].get("value"), vy_ast.Ellipsis)
isinstance(body[0], vy_ast.Expr) and isinstance(body[0].value, vy_ast.Ellipsis)
):
raise FunctionDeclarationException(
"function body in an interface can only be `...`!", funcdef
Expand Down

0 comments on commit f006571

Please sign in to comment.