Fix line/file info for methods added by using declarations

This commit is contained in:
William S Fulton 2022-02-26 20:07:58 +00:00
commit 961424a986
3 changed files with 13 additions and 0 deletions

View file

@ -1074,6 +1074,8 @@ class TypePass:private Dispatcher {
}
}
Node *nn = copyNode(c);
Setfile(nn, Getfile(n));
Setline(nn, Getline(n));
Delattr(nn, "access"); // access might be different from the method in the base class
Setattr(nn, "access", Getattr(n, "access"));
if (!Getattr(nn, "sym:name"))