mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-27 12:10:09 +02:00
* don't crash in {$x-} mode if a call cannot be resolved due to an error
in the expression (mantis #17455) git-svn-id: trunk@16061 -
This commit is contained in:
parent
03b06dc7a1
commit
bd0567563c
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -9940,6 +9940,7 @@ tests/webtbf/tw1633.pp svneol=native#text/plain
|
||||
tests/webtbf/tw1642.pp svneol=native#text/plain
|
||||
tests/webtbf/tw1655.pp svneol=native#text/plain
|
||||
tests/webtbf/tw1681.pp svneol=native#text/plain
|
||||
tests/webtbf/tw17455.pp svneol=native#text/plain
|
||||
tests/webtbf/tw1754.pp svneol=native#text/plain
|
||||
tests/webtbf/tw1754b.pp svneol=native#text/plain
|
||||
tests/webtbf/tw1782.pp svneol=native#text/plain
|
||||
|
@ -1207,6 +1207,8 @@ implementation
|
||||
{ in $x- state, the function result must not be ignored }
|
||||
if not(cs_extsyntax in current_settings.moduleswitches) and
|
||||
not(is_void(p.resultdef)) and
|
||||
{ can be nil in case there was an error in the expression }
|
||||
assigned(tcallnode(p).procdefinition) and
|
||||
not((tcallnode(p).procdefinition.proctypeoption=potype_constructor) and
|
||||
assigned(tprocdef(tcallnode(p).procdefinition)._class) and
|
||||
is_object(tprocdef(tcallnode(p).procdefinition)._class)) then
|
||||
|
12
tests/webtbf/tw17455.pp
Normal file
12
tests/webtbf/tw17455.pp
Normal file
@ -0,0 +1,12 @@
|
||||
{ %fail }
|
||||
|
||||
{$mode macpas}
|
||||
{$extendedsyntax off}
|
||||
|
||||
program crash;
|
||||
var
|
||||
thePStr: string[ 255];
|
||||
begin
|
||||
System.Move
|
||||
( thePStr, MenuPtr^, Length( thePStr) + 1)
|
||||
end.
|
Loading…
Reference in New Issue
Block a user