codetools: fixed finddeclaration in generic methods searching ancestor class

git-svn-id: trunk@13014 -
This commit is contained in:
mattias 2007-11-24 22:56:09 +00:00
parent 4a5fbf3a39
commit d62038c83e
2 changed files with 2 additions and 1 deletions

View File

@ -4228,7 +4228,7 @@ begin
// no ancestor class specified
// check class name
if (ClassIdentNode=nil)
or (not (ClassIdentNode.Desc in [ctnTypeDefinition,ctnGenericType])) then
or (not (ClassIdentNode.Desc in [ctnTypeDefinition,ctnGenericName])) then
begin
MoveCursorToNodeStart(ClassNode);
RaiseException('class without name');

View File

@ -571,6 +571,7 @@ begin
CommentEnd:=FindCommentEnd(Src,p,NestedComment);
Tool.CleanPosToCaret(p,CodeXYPosition);
CommentStr:=copy(Src,p,CommentEnd-p);
//DebugLn(['TfrmTodo.LoadFile CommentStr="',CommentStr,'"']);
if Src[p]='/' then
aTodoItem := GetToDoItem(CodeXYPosition.Code.Filename, '//', '', CommentStr, CodeXYPosition.Y)
else if Src[p]='{' then