From ac2006898f5ca65581308f952c02969659c7096b Mon Sep 17 00:00:00 2001 From: sergei Date: Thu, 11 Jul 2013 08:21:45 +0000 Subject: [PATCH] * Mark procedures with shortstring value parameters as non-leaf, because such parameters generate a call (to fpc_shortstr_assign). git-svn-id: trunk@25082 - --- compiler/psub.pas | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/compiler/psub.pas b/compiler/psub.pas index 312e15d5f7..c6f819eb1a 100644 --- a/compiler/psub.pas +++ b/compiler/psub.pas @@ -1817,8 +1817,10 @@ implementation if tsym(p).typ<>paravarsym then exit; with tparavarsym(p) do - if is_managed_type(vardef) and - (varspez in [vs_value,vs_out]) then + if (is_managed_type(vardef) and + (varspez in [vs_value,vs_out])) or + (is_shortstring(vardef) and + (varspez=vs_value)) then include(current_procinfo.flags,pi_do_call); end;