<html><body><div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Nov 29, 2025 at 8:40:33 PM, Thomas Kurz via fpc-pascal <<a href="mailto:fpc-pascal@lists.freepascal.org">fpc-pascal@lists.freepascal.org</a>> wrote:<br></div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex" type="cite">
<div>Can't you use a type helper to access the fields only locally in other classes? Unfortunately this works only for `protected` and not for `private` fields, but if it's your own class, maybe you'd like to give it a try.<br><br>Btw: I would be great if type helpers could be given access to `private` fields, too!<br><br></div>
</blockquote>
</div>
<br>
<div dir="ltr">Pretty sure no because the fields are private which is scoped to a single file so if you declare the type helper in another unit you can't access the field. That would be annoying to make helpers for all the types too.<br></div><div dir="ltr"><br></div><div dir="ltr">I just tried actually and a property which read a public field from a class in another unit failed too. That seems like a bug to me. </div></body></html>