Delphi-PRAXiS
Seite 2 von 2     12   

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Object-Pascal / Delphi-Language (https://www.delphipraxis.net/32-object-pascal-delphi-language/)
-   -   Delphi Lokale Kopie von System.Variants.pas einbinden und nutzen, geht das? (https://www.delphipraxis.net/214139-lokale-kopie-von-system-variants-pas-einbinden-und-nutzen-geht-das.html)

Uwe Raabe 24. Nov 2023 12:41

AW: Lokale Kopie von System.Variants.pas einbinden und nutzen, geht das?
 
In deinem originalen Post ging es aber nicht um System.Variants, sondern um System.VarUtils.

Bei System.Variants bekomme ich auch den gleichen Fehler.

Kas Ob. 24. Nov 2023 12:48

AW: Lokale Kopie von System.Variants.pas einbinden und nutzen, geht das?
 
Zitat:

Zitat von Rollo62 (Beitrag 1530042)
Immer mit dem Fehler
"[dcc32 Fatal Error] System.Variants.pas(1271): E2158 System.Variants unit out of date or corrupted: missing '@VarCast'"

VarCast is declared as _VarCast, so in theory to make it work you need to strip all the functions in System.Variants.pas from these and adjust the whole unit to call them stripped code, though there might be something hidden to surprise you, which need to adjust system.pas itself, that most likely impossible with Delphi compiler.

If rebuilding the whole RTL (after making changes) is possible then that is the right way, in my opinion.
In case you succeeded in rebuilding the RTL, then i suggest to add global hooks with minimum interaction with the current code and declarations, these hooks and callback can be used for logging, and the RTL might still be compatible with default RTL, just food for thought.

Rollo62 24. Nov 2023 17:25

AW: Lokale Kopie von System.Variants.pas einbinden und nutzen, geht das?
 
Zitat:

Zitat von Uwe Raabe (Beitrag 1530043)
In deinem originalen Post ging es aber nicht um System.Variants, sondern um System.VarUtils.

Ja sorry, ich hatte beide probiert um die fehlende Referenzen reinzubekommen, hilft aber nichts.


Zitat:

Zitat von Kas Ob. (Beitrag 1530044)
Zitat:

Zitat von Rollo62 (Beitrag 1530042)
Immer mit dem Fehler
"[dcc32 Fatal Error] System.Variants.pas(1271): E2158 System.Variants unit out of date or corrupted: missing '@VarCast'"

VarCast is declared as _VarCast, so in theory to make it work you need to strip all the functions in System.Variants.pas from these and adjust the whole unit to call them stripped code, though there might be something hidden to surprise you, which need to adjust system.pas itself, that most likely impossible with Delphi compiler.

If rebuilding the whole RTL (after making changes) is possible then that is the right way, in my opinion.
In case you succeeded in rebuilding the RTL, then i suggest to add global hooks with minimum interaction with the current code and declarations, these hooks and callback can be used for logging, and the RTL might still be compatible with default RTL, just food for thought.

Yes, I had seen the C-like notations, but that made me stop there.
To make such huge RTL change is not worth it, especially because I found the root cause meanwhile also without logging into this.

Thanks anyway, for the help here.

Kas Ob. 24. Nov 2023 18:25

AW: Lokale Kopie von System.Variants.pas einbinden und nutzen, geht das?
 
Zitat:

Zitat von Rollo62 (Beitrag 1530064)
Yes, I had seen the C-like notations, but that made me stop there.
To make such huge RTL change is not worth it, especially because I found the root cause meanwhile also without logging into this.

Thanks anyway, for the help here.

I was referring to recompiling the shipped DCU's hence the RTL, from https://stackoverflow.com/questions/...sible-then-how
Code:
This is a very old question/answer, but I can confirm that this is still a working solution in Delphi 10.3. Thanks – 
Johann Burgess
 Mar 30, 2021 at 3:39


Alle Zeitangaben in WEZ +1. Es ist jetzt 06:28 Uhr.
Seite 2 von 2     12   

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz