* more descriptive error message in case of a missing variant unit added

* variant unit uses now the math unit for ** implementation

git-svn-id: trunk@158 -
This commit is contained in:
florian 2005-05-30 20:47:34 +00:00
parent 4f30642b4a
commit 9da46ff50a
3 changed files with 31 additions and 9 deletions

1
.gitattributes vendored
View File

@ -6123,6 +6123,7 @@ tests/webtbs/tw3973.pp svneol=native#text/plain
tests/webtbs/tw3977.pp svneol=native#text/plain
tests/webtbs/tw3977.txt svneol=native#text/plain
tests/webtbs/tw4010.pp svneol=native#text/plain
tests/webtbs/tw4013.pp svneol=native#text/plain
tests/webtbs/ub1873.pp svneol=native#text/plain
tests/webtbs/ub1883.pp svneol=native#text/plain
tests/webtbs/uw0555.pp svneol=native#text/plain

View File

@ -16,27 +16,35 @@
var
variantmanager : tvariantmanager;
procedure invalidvariantop;
begin
HandleErrorFrame(221,get_frame);
end;
procedure invalidvariantopnovariants;
procedure printmissingvariantunit;
begin
writeln(stderr);
writeln(stderr,'Program needs probably the variants unit.');
writeln(stderr,'Include the variants unit in your uses statements');
writeln(stderr,'as one of the first units.');
writeln(stderr);
end;
procedure invalidvariantop;
begin
printmissingvariantunit;
HandleErrorFrame(221,get_frame);
end;
procedure invalidvariantopnovariants;
begin
printmissingvariantunit;
HandleErrorFrame(221,get_frame);
end;
procedure vardisperror;
begin
HandleErrorFrame(222,get_frame);
printmissingvariantunit;
HandleErrorFrame(222,get_frame);
end;

13
tests/webtbs/tw4013.pp Normal file
View File

@ -0,0 +1,13 @@
{ Source provided for Free Pascal Bug Report 4013 }
{ Submitted by "Miguel Garcia-Blanco" on 2005-05-25 }
{ e-mail: mgbonline@hotmail.com }
PROGRAM Test;
uses
variants;
BEGIN
writeln( 2.0**5.0 );
END.