Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3396230
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T04:22:59+00:00 2026-05-18T04:22:59+00:00

working on a mac os project (meaning not iPhone) requiring 10.6 and is 64bit,

  • 0

working on a mac os project (meaning not iPhone) requiring 10.6 and is 64bit, allows me to use properties to generate both accessor methods and instance variables in the header file. but, during debug, i’m not seeing how to look at the object’s properties values after they have been populated. is there some build setting that needs to be turned on?

if i am declaring an object’s instance variables (between {} in the header), then i can see those values (when they are used) during debug either in the debug window itself, or by using the cursor-hover over the highlighted line trick in the editor during a break, or by doing cli in gdb like ‘p *object’ for instance.

old way:

@class Suit;
@interface Card : NSObject 
{
    NSNumber *playOrder;
    Suit *suit;
    NSNumber *displayNumber;
    NSNumber *orderIndex;
}
@property(nonatomic, retain) Suit *suit;
@property(nonatomic, retain) NSNumber *displayNumber;
@property(nonatomic, retain) NSNumber *orderIndex;

new way:

@class Suit;
@interface Card : NSObject 

@property(nonatomic, retain) Suit *suit;
@property(nonatomic, retain) NSNumber *displayNumber;
@property(nonatomic, retain) NSNumber *orderIndex;
@property(nonatomic, retain) NSNumber *playOrder;

in this new-fangled 10.6 required 64bit idea (which seems simpler to me) none of these debug methods display the object’s values. i figure that i must have something turned off, because this newer idea, doesn’t seem better.

gdb results for old way:

(gdb) po newCard
New Card : 0 of Suit : Hearts (NSCalibratedRGBColorSpace 1 0 0 1). with orderIndex of: 1
(gdb) p *newCard
$1 = {
  <NSObject> = {
    isa = 0x100002188
  }, 
  members of Card: 
  playOrder = 0x0, 
  suit = 0x200053a20, 
  displayNumber = 0x20001bac0, 
  orderIndex = 0x200012de0
}
(gdb)

gdb results for new way:

(gdb) po newCard
New Card : 0 of Suit : Hearts (NSCalibratedRGBColorSpace 1 0 0 1). with orderIndex of: 1
(gdb) p *newCard
$3 = {
  <NSObject> = {
    isa = 0x100002188
  }, <No data fields>}
(gdb) 

so looking at the docs for objective-c 2.0:

http://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/ObjectiveC/Articles/ocProperties.html#//apple_ref/doc/uid/TP30001163-CH17-SW3

describes what i am referring to (synthesizing instance variables in ‘modern’ runtime), but what isn’t said anywhere, is that if you do this, the values will not be available during debugging.

i’ve found an SO page with pertinent information, but not focused on this effect:
Using instance variables with Modern Runtime

what did i miss?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T04:22:59+00:00Added an answer on May 18, 2026 at 4:22 am

    In GDB, you can use property getters to access dynamic ivars:

    (gdb) po [newCard displayNumber]
    0
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm attempting to get google-toolbox-for-mac working with my existing XCode 3.2 iPad project, but
I am currently working on a web browser project from Apple's Mac Dev site
I am currently working on a web browser project from Apple's Mac Dev site
I'm working on mac OS x 10.4 . I have a subversion repository stored
I'm working with JInternalFrame's under Mac OS X Java 5 and when maximizing a
I'm working on a Cocoa Mac app where I need to display a window/view
I'm working through Cocoa Programming for Mac OS X (3rd ed) and in chapter
I'm learning objective-c, working through Aaron Hillegass' book Cocoa Programming for Mac OS X
Working on a project at the moment and we have to implement soft deletion
Working on a project that parses a log of events, and then updates a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.