[fpc-pascal] How to avoid Copy
Hairy Pixels
genericptr at gmail.com
Mon Jan 1 15:14:00 CET 2024
> On Jan 1, 2024, at 3:50 PM, Michael Van Canneyt <michael at freepascal.org> wrote:
>
> You can't optimize that. As said, a generic is convenient but slow.
I don't know about that. Like was mentioned the enumerator needs to return a pointer, preferable without ^ so it feels like a record and only use that in the for-in scope. You can kind of do that yourself but it's cumbersome to maintain and missing from the RTL (maybe for this reason).
Regards,
Ryan Joseph
More information about the fpc-pascal
mailing list