[M3devel] Pretty-printing REFANYs?

Darko darko at darko.org
Sun Sep 28 07:22:33 CEST 2008


You can use RTTipe to read the fields and values within a type. If you  
also want the type and field names you can interpret the .M3WEB file.  
I have a couple of modules that do something like that but they are  
not what you would call finished. What level of detail are you after?


On 28/09/2008, at 6:45 AM, Mika Nystrom wrote:

> Hello Modula-3 people,
>
> I am working on a writing an interpreter that I'd like to embed in
> various Modula-3 programs.  It so happens that this interpreter
> might from time to time be manipulating arbitrary M3 REFs, and just
> from the point of view of providing information to a human user,
> it might be nice to be able to pretty-print these.  Does anyone
> have any code that accomplishes this, at least partly?  I'm thinking
> that since m3gdb can do it, the information must all be in the
> binary---somehow.  (Even enumeration names, right?)  And since the
> pickler can pickle things... hmm.
>
> I would greatly appreciate any guidance that's out there...
>
>    Best regards,
>       Mika Nystrom




More information about the M3devel mailing list