mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-08 11:48:04 +02:00
* don't allow starting new virtual trees in TP-style objects + test
* fixed bug in whlpview.pas where such an new tree was unintentially started git-svn-id: trunk@8422 -
This commit is contained in:
parent
eefd81094e
commit
288a538df5
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -7443,6 +7443,7 @@ tests/webtbf/tw9039b.pp svneol=native#text/plain
|
||||
tests/webtbf/tw9039c.pp svneol=native#text/plain
|
||||
tests/webtbf/tw9039d.pp svneol=native#text/plain
|
||||
tests/webtbf/tw9225.pp svneol=native#text/plain
|
||||
tests/webtbf/tw9306c.pp svneol=native#text/plain
|
||||
tests/webtbf/tw9499.pp svneol=native#text/plain
|
||||
tests/webtbf/tw9499a.pp svneol=native#text/plain
|
||||
tests/webtbf/tw9522.pp svneol=native#text/plain
|
||||
|
@ -429,7 +429,7 @@ parser_e_overloaded_have_same_parameters=03028_E_overloaded functions have the s
|
||||
% You're declaring overloaded functions, but with the same parameter list.
|
||||
% Overloaded function must have at least 1 different parameter in their
|
||||
% declaration.
|
||||
parser_e_header_dont_match_forward=03029_E_function header doesn't match the forward declaration "$1"
|
||||
parser_e_header_dont_match_forward=03029_E_function header doesn't match the previous declaration "$1"
|
||||
% You declared a function with same parameters but
|
||||
% different result type or function modifiers.
|
||||
parser_e_header_different_var_names=03030_E_function header "$1" doesn't match forward : var name changes $2 => $3
|
||||
@ -2656,7 +2656,7 @@ S*2Tlinux_Linux
|
||||
**2*_a : Show everything x : Executable info (Win32 only)
|
||||
**2*_b : Write file names messages with full path
|
||||
**2*_v : Write fpcdebug.txt with p : Write tree.log with parse tree
|
||||
**2*_ Lots of debugging info
|
||||
**2*_ lots of debugging info
|
||||
3*1W<x>_Target-specific options (targets)
|
||||
A*1W<x>_Target-specific options (targets)
|
||||
P*1W<x>_Target-specific options (targets)
|
||||
|
@ -731,7 +731,7 @@ const
|
||||
option_info=11024;
|
||||
option_help_pages=11025;
|
||||
|
||||
MsgTxtSize = 45147;
|
||||
MsgTxtSize = 45148;
|
||||
|
||||
MsgIdxMax : array[1..20] of longint=(
|
||||
24,86,237,83,63,49,107,22,135,60,
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -371,7 +371,11 @@ implementation
|
||||
if (pd._class=procdefcoll^.data._class) then
|
||||
MessagePos(pd.fileinfo,parser_e_overloaded_have_same_parameters)
|
||||
else if (_class=pd._class) and not(po_reintroduce in pd.procoptions) then
|
||||
MessagePos1(pd.fileinfo,parser_w_should_use_override,pd.fullprocname(false));
|
||||
if not is_object(_class) then
|
||||
MessagePos1(pd.fileinfo,parser_w_should_use_override,pd.fullprocname(false))
|
||||
else
|
||||
{ objects don't allow starting a new virtual tree }
|
||||
MessagePos1(pd.fileinfo,parser_e_header_dont_match_forward,procdefcoll^.data.fullprocname(false));
|
||||
end;
|
||||
end;
|
||||
end
|
||||
|
@ -102,7 +102,7 @@ type
|
||||
PLinePosCollection = ^TLinePosCollection;
|
||||
TLinePosCollection = object(TNoDisposeCollection)
|
||||
function At(Index: sw_Integer): sw_integer;
|
||||
procedure Insert (Item: ptrint);virtual;
|
||||
procedure Insert (Item: pointer);virtual;
|
||||
end;
|
||||
|
||||
PHelpTopic = ^THelpTopic;
|
||||
@ -402,9 +402,9 @@ begin
|
||||
at := longint (inherited at(Index));
|
||||
end;
|
||||
|
||||
procedure TLinePosCollection.Insert (Item: ptrint);
|
||||
procedure TLinePosCollection.Insert (Item: pointer);
|
||||
begin
|
||||
Inherited Insert(pointer(Item));
|
||||
Inherited Insert(Item);
|
||||
end;
|
||||
|
||||
constructor THelpTopic.Init(ATopic: PTopic);
|
||||
@ -482,7 +482,7 @@ begin
|
||||
Bounds.Move(Delta,0);
|
||||
if Line='' then Line:=' ';
|
||||
Lines^.Insert(NewStr(Line));
|
||||
LinesPos^.Insert(LinePos);
|
||||
LinesPos^.Insert(pointer(LinePos));
|
||||
ClearLine;
|
||||
LineStart:=NextLineStart;
|
||||
CurPos.X:=Margin+LineStart; Line:=CharStr(#255,LineStart); Inc(CurPos.Y);
|
||||
|
21
tests/webtbf/tw9306c.pp
Normal file
21
tests/webtbf/tw9306c.pp
Normal file
@ -0,0 +1,21 @@
|
||||
{ %fail }
|
||||
|
||||
type
|
||||
tobj = object
|
||||
function f: integer; virtual;
|
||||
end;
|
||||
|
||||
tobj2 = object(tobj)
|
||||
function f: string; virtual;
|
||||
end;
|
||||
|
||||
function tobj.f: integer;
|
||||
begin
|
||||
end;
|
||||
|
||||
function tobj2.f:string;
|
||||
begin
|
||||
end;
|
||||
|
||||
begin
|
||||
end.
|
Loading…
Reference in New Issue
Block a user