[fpc-devel] Does FPC optimize unused parameters ?
Florian Klaempfl
florian at freepascal.org
Sun Aug 26 21:17:59 CEST 2012
Am 24.08.2012 13:48, schrieb Jonas Maebe:
>
> Martin wrote on Fri, 24 Aug 2012:
>
>> On 24/08/2012 12:04, Jonas Maebe wrote:
>>>
>>> Martin wrote on Fri, 24 Aug 2012:
>>
>> The above takes the first of the overloaded.
>> All bodies are empty.
>>
>> procedure DebugLn(const s: string = ''); inline; overload;
>
> That looks like a very serious bug introduced in the handling of
> parameters to inlined routines. Florian changed several things there
> over the last couple of months, maybe he has an idea.
Yes, r21445 is guilty. para.left should be checked with
might_have_sideeffects if refs=0 if it really could be removed.
More information about the fpc-devel
mailing list