• 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
lldb 'print object' (po) prints pointer value if not object?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

lldb 'print object' (po) prints pointer value if not object?


  • Subject: lldb 'print object' (po) prints pointer value if not object?
  • From: Jerry Krinock <email@hidden>
  • Date: Tue, 22 Apr 2014 20:48:13 -0700

(lldb) p/x $rdi
(unsigned long) $0 = 0x0000000000000053
(lldb) po [$rdi className]
error: Execution was interrupted, reason: EXC_BAD_ACCESS (code=1, address=0x20).
The process has been returned to the state before expression evaluation.
(lldb) po [$rdi description]
error: Execution was interrupted, reason: EXC_BAD_ACCESS (code=1, address=0x20).
The process has been returned to the state before expression evaluation.

# Clearly, the value in rdi is 0x53, and this is not the pointer to a valid Objective-C object.  But lo,

(lldb) po $rdi
83

According to http://lldb.llvm.org/status.html, ‘po’ is for "printing the description of an object”.  So the result I expect is EXC_BAD_ACCESS.

Do we agree that this is a bug?  I would much rather it give me EXC_BAD_ACCESS, because “83” looks like NSNumber whose value is 83, or the string “83”.

Jerry Krinock
 _______________________________________________
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: lldb 'print object' (po) prints pointer value if not object?
      • From: Quincey Morris <email@hidden>
    • Re: lldb 'print object' (po) prints pointer value if not object?
      • From: Quincey Morris <email@hidden>
  • Prev by Date: Re: Quartz Composer deprecated in Xcode 5.1.1??
  • Next by Date: Re: lldb 'print object' (po) prints pointer value if not object?
  • Previous by thread: [MEET] Toronto CocoaHeads / tacow - May 13
  • Next by thread: Re: lldb 'print object' (po) prints pointer value if not object?
  • Index(es):
    • Date
    • Thread