Re: variable types unravel / RTTI
- From: Marco van de Voort <marcov@xxxxxxxx>
- Date: Wed, 25 May 2005 10:10:37 +0000 (UTC)
["Followup-To:" header set to comp.lang.pascal.delphi.misc.]
On 2005-05-25, michalp <michalp@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
> there is the declaration (suppose in unit that we havn't access to):
>
> type
> t1 = integer;
> t2 = record
> a: t1;
> b: array[1..2] of integer;
> end;
> var
> x: t2;
>
> Suppose that we know that x exist and we don't know what type x is.
> Is there any possibility to ask Delphi compiler to tell us someting more
> about x (what type x is, no matter run-time/compilation-time) ?
No. Except that you can get the size. Note also that the compiler doesn't
have an interactive mode where you can ask him questions during compiletime.
> So, is there any chance to get all this informations step by step,
> precisely, each level?
No.
> Bonus question: if there isn't possibility to do this, maybe there is
> any tool to show all types and variables (and functions etc) from
> DCU/TPU/LIB and other binary files?
Can it be done in theory?
DCU: yes if the type is exported
TPU: yes if the type is exported
PPU: yes if the type is exported
Others: are probably prelinked and don't contain this info anymore.
Is there a tool:
DCU: is version dependant, stuff that can read it exists.
TPU: is version dependant, stuff that can read it exists.
PPU: is version dependant, however each version comes with a unit (ppu)
and program (ppudump) that can dump the contents.
.
- Follow-Ups:
- Re: variable types unravel / RTTI
- From: michalp
- Re: variable types unravel / RTTI
- Prev by Date: Re: distance between lats and lons
- Next by Date: Re: distance between lats and lons
- Previous by thread: Farsi text in drawing and text editor
- Next by thread: Re: variable types unravel / RTTI
- Index(es):
Relevant Pages
|
|