fix #838
This commit is contained in:
parent
bacf51ef63
commit
769e30f3cb
|
|
@ -1387,7 +1387,13 @@ namespace CodeCompletion
|
|||
|
||||
public override void visit(inherited_ident _inherited_ident)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
var tmp_scope = entry_scope;
|
||||
if (entry_scope.topScope is TypeScope)
|
||||
{
|
||||
entry_scope = (entry_scope.topScope as TypeScope).baseScope;
|
||||
}
|
||||
new ident(_inherited_ident.name).visit(this);
|
||||
entry_scope = tmp_scope;
|
||||
}
|
||||
|
||||
public override void visit(format_expr _format_expr)
|
||||
|
|
|
|||
|
|
@ -2575,6 +2575,7 @@ namespace PascalABCCompiler.Parsers
|
|||
}
|
||||
else if (s == "inherited")
|
||||
{
|
||||
bound = i + 1;
|
||||
keyword = KeywordKind.Inherited;
|
||||
}
|
||||
else if (s == "raise")
|
||||
|
|
|
|||
20
TestSuite/intellisense_tests/inherited1.pas
Normal file
20
TestSuite/intellisense_tests/inherited1.pas
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
type
|
||||
t1=class
|
||||
procedure p1; virtual;
|
||||
begin
|
||||
end;
|
||||
end;
|
||||
t2=class(t1)
|
||||
procedure p1; override;
|
||||
begin
|
||||
inherited p1{@procedure t1.p1(); virtual;@}();
|
||||
end;
|
||||
end;
|
||||
t3=class(t2)
|
||||
procedure p1; override;
|
||||
begin
|
||||
inherited p1{@procedure t2.p1(); override;@};
|
||||
end;
|
||||
end;
|
||||
|
||||
begin end.
|
||||
Loading…
Reference in a new issue