• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Displaying Custom Data Types in Debugger
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Displaying Custom Data Types in Debugger


  • Subject: Re: Displaying Custom Data Types in Debugger
  • From: Michael Rice <email@hidden>
  • Date: Sat, 16 Jul 2005 13:52:56 -0500


On Jul 16, 2005, at 10:49 AM, Chris Espinosa wrote:


On Jul 16, 2005, at 2:31 AM, Michael Rice wrote:


Is there a way to make the Xcode C++ debugger display data from custom data types? For example, I have a structure that contains a void* field that is bascially a Pascal-type string (4-byte length followed by a NULL-terminated string). I'd like to be able to customize Xcode with a "template" of some sort such that it can display the field as a string instead of a plain pointer.


Try "Viewing Variables Using Custom Data Formatters" in the Xcode User Guide:


http://developer.apple.com/documentation/DeveloperTools/Conceptual/ XcodeUserGuide21/Contents/Resources/en.lproj/06_04_db_view_info/ chapter_42_section_4.html



Chris -

Thank you. I have one more question about this feature. I have an unicode string (an array of 16-bit unsigned shorts) that I would like to display as a char*. I know that each character is ASCII (the unsigned short value is <= 255). Is there a simple way to do this? The Xcode documentation states:

"In addition to supplying custom format strings to display variables in the debugger, you can also write your own code that constructs descriptions for variables displayed in the debugger. These functions can be packaged as a bundle that is loaded into the process being debugged. These functions can then be invoked from format strings."

Is this what I need to do? If so, is there an example of how to do this?

Thanks.
Michael
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Displaying Custom Data Types in Debugger
      • From: Chris Espinosa <email@hidden>
References: 
 >Displaying Custom Data Types in Debugger (From: Michael Rice <email@hidden>)
 >Re: Displaying Custom Data Types in Debugger (From: Chris Espinosa <email@hidden>)

  • Prev by Date: Re: Universal Binary that runs on 10.3.x and up on PPC and 10.4.1 and up on Intel
  • Next by Date: Re: XCode 2.1 Unstable
  • Previous by thread: Re: Displaying Custom Data Types in Debugger
  • Next by thread: Re: Displaying Custom Data Types in Debugger
  • Index(es):
    • Date
    • Thread