Hi Jonas,
That is reasonable. Perhaps the hint should mention that?
But why is this still not inlined::
type TStrBuilder = object
procedure append(const p: pchar; const l: SizeInt); inline;
procedure append(const s: RawByteString);
end;
implementation
procedure TStrBuilder.append(const p: pchar; const l: SizeInt); inline;
begin
end;
procedure TStrBuilder.append(const s: RawByteString);
begin
append(pchar(pointer(s)), length(s)); //inlinetest.pas(24,3) Note:
Call to subroutine "procedure TStrBuilder.append(const p:PChar;const
l:Int64);" marked as inline is not inlined
end;
Best,
Benito
Am 01.01.19 um 22:41 schrieb Jonas Maebe:
On 01/01/19 22:38, Benito van der Zander wrote:
and why is it not inlining the count and append call of this string
builder? It is not using any implementation only function
Routines can only be inlined if they are called after their
implementation has been parsed. FPC compiles everything in a single pass.
Jonas
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal