mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-11 04:48:03 +02:00
Codetools: Support Codecompletion inside "with begin end" block. May fix other cases, too. Issue #0023782, patch from jefferywa.
git-svn-id: trunk@62470 -
This commit is contained in:
parent
56b70571c9
commit
29d750ae6a
@ -7490,6 +7490,7 @@ function TFindDeclarationTool.FindAncestorOfClassInheritance(
|
||||
var
|
||||
InheritanceNode: TCodeTreeNode;
|
||||
ClassNode: TCodeTreeNode;
|
||||
SpecializeNode : TCodeTreeNode;
|
||||
AncestorContext: TFindContext;
|
||||
AncestorStartPos: LongInt;
|
||||
ExprType: TExpressionType;
|
||||
@ -7569,9 +7570,14 @@ begin
|
||||
if (AncestorContext.Node.Desc in [ctnTypeDefinition,ctnGenericType]) then
|
||||
begin
|
||||
Params:=TFindDeclarationParams.Create;
|
||||
if IdentifierNode.Desc=ctnSpecialize then begin
|
||||
SpecializeNode:=IdentifierNode;
|
||||
Params.SetGenericParamValues(Self, SpecializeNode);
|
||||
end;
|
||||
try
|
||||
Params.Flags:=fdfDefaultForExpressions+[fdfFindChildren];
|
||||
AncestorContext:=AncestorContext.Tool.FindBaseTypeOfNode(Params,AncestorContext.Node);
|
||||
ResultParams.GenParams:=Params.GenParams;
|
||||
finally
|
||||
Params.Free;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user