Xcode (lldb) Summary Format for struct URL

Viewed 131

I have a custom data structure with objects containing a URL property.

img1

However I'd like to be able to see the URL's path directly, without needing to print the description of each one.

I tried modifying the Summary Format by right-clicking on an element and selecting "Edit Summary Format...". But I was not able to find a working syntax to show something more useful.

I also tried using in the lldb console, with the command: type summary add --summary-string "${var.path}" Foundation.URL. But I kept getting an error message about the summary-string parsing gone wrong.

What should I do?

By the way, I'm using Xcode 12.0 and Swift 5.3.

0 Answers
Related