Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
RE: Parsing type strings of Objective C
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Parsing type strings of Objective C



Hi Andrew,

In my process, I will be maintaining a symbol table of the types that I
discover as well - do you have a specific link to the section of the GCC
docs that you mention?

Take care

John Clayton

-----Original Message-----
From: objc-language-bounces+john.clayton=email@hidden
[mailto:objc-language-bounces+john.clayton=email@hidden] On
Behalf Of Andrew Pinski
Sent: Mittwoch, 25. Januar 2006 15:33
To: John Clayton
Cc: email@hidden
Subject: Re: Parsing type strings of Objective C

>
> Hi All
>
> I have some really basically string parsing to write an equivalent of
> @decode(), which produces simply a human readable textual description
> of the types that have been passed into the parser.
>
> Now I am replacing that 'spike' parser with a more fully functional LL

> parser based on the spirit module contained within the boost
> libraries.
>
> My issue is, there are actually more types to parse than are described

> in the ObjC.pdf (or other source of info about type encodings).  E.g.
> sometimes I find 'r' or 'V' in a type expression, and I'm not sure
> what these stand for in terms of types.
>
> Can anyone point me to a reference that goes into more detail about
> the encoded types than the standard Apple docs?  If there's nothing
> out there - I've assumed that I will have to dig into the code for
> class-dump / c++filt or gcc (gulp!).  :-)

There is some docs in the GCC documention.  I just added information on
how to decode "complex" types there.  Also  the GNU objc runtime has a
decoder for getting the sizeof and alignof for the struct if that is all
you need.  I can add a function which gives back a nice string if you
want.

Thanks,
Andrew Pinski
GNU objc runtime maintainer
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Objc-language mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
com

This email sent to email@hidden

Visit our website at http://www.ubs.com

This message contains confidential information and is intended only
for the individual named.  If you are not the named addressee you
should not disseminate, distribute or copy this e-mail.  Please
notify the sender immediately by e-mail if you have received this
e-mail by mistake and delete this e-mail from your system.

E-mail transmission cannot be guaranteed to be secure or error-free
as information could be intercepted, corrupted, lost, destroyed,
arrive late or incomplete, or contain viruses.  The sender therefore
does not accept liability for any errors or omissions in the contents
of this message which arise as a result of e-mail transmission.  If
verification is required please request a hard-copy version.  This
message is provided for informational purposes and should not be
construed as a solicitation or offer to buy or sell any securities or
related financial instruments.

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Objc-language mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.