diff options
| author | Harold Brenes <harold@hbrenes.com> | 2025-05-01 11:49:57 -0400 |
|---|---|---|
| committer | Harold Brenes <harold@hbrenes.com> | 2025-05-01 12:00:49 -0400 |
| commit | ec0fb1945eda03e79ea5dd498b54ba9915e84588 (patch) | |
| tree | e6ad117ecd18660d089c2526c139c23069496b27 /src/common | |
| parent | 65253fea01ba3648314947a489de6f57934b70ee (diff) | |
Allow parapoly fake methods to be resolved
Diffstat (limited to 'src/common')
| -rw-r--r-- | src/common/ast.odin | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/common/ast.odin b/src/common/ast.odin index 1957f3a..025fab0 100644 --- a/src/common/ast.odin +++ b/src/common/ast.odin @@ -184,6 +184,13 @@ unwrap_pointer_ident :: proc(expr: ^ast.Expr) -> (ast.Ident, int, bool) { } } + // Check for parapoly self + if expr != nil { + if call, ok := expr.derived.(^ast.Call_Expr); ok { + expr = call.expr + } + } + if expr != nil { if ident, ok := expr.derived.(^ast.Ident); ok { return ident^, n, ok |