I have the following piece of code in xcode and would like to inspect the contents of "link" which is a local object "ReaderDocumentLink *link" declared in the for loop and I set breakpoint at the line "result = [self annotationLinkTarget:link.dictionary];" as show below:
-(id)singleTap:(UITapGestureRecognizer *)recognizer
{
id result = nil; // Tap result object
if (recognizer.state == UIGestureRecognizerStateRecognized)
{
if (_links.count > 0) // Process the single tap
{
CGPoint point = [recognizer locationInView:self];
for (ReaderDocumentLink *link in _links) // Enumerate links
{
if (CGRectContainsPoint(link.rect, point) == true) // Found it
{
result = [self annotationLinkTarget:link.dictionary];
break;
}
}
}
}
return result;
}
I tried "po link" and it doesn't work. (it reports error as below:
error: 'link' has unknown type; cast it to its declared type to use it
error: 1 errors parsing expression
So what shall I do to print out the details in the "link" object? including the contents of link.dictionary as well. Thanks.