From 128e4a2adca6721254e8ffd290b670cc58b7a898 Mon Sep 17 00:00:00 2001 From: Felix Morgner Date: Fri, 1 May 2026 21:00:39 +0200 Subject: debug: add support for smart pointer pretty printing --- scripts/gdb/kstd/__init__.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'scripts/gdb/kstd/__init__.py') diff --git a/scripts/gdb/kstd/__init__.py b/scripts/gdb/kstd/__init__.py index 7dc1596..fc5e8fb 100644 --- a/scripts/gdb/kstd/__init__.py +++ b/scripts/gdb/kstd/__init__.py @@ -3,6 +3,7 @@ import gdb.printing from .vector import KstdVectorPrinter from .string import KstdStringPrinter from .std_types import StdBytePrinter +from .smart_pointers import KstdUniquePtrPrinter, KstdSharedPtrPrinter def build_pretty_printers(): @@ -10,6 +11,8 @@ def build_pretty_printers(): pp.add_printer("vector", "^kstd::vector<.*>$", KstdVectorPrinter) pp.add_printer("string", "^kstd::string$", KstdStringPrinter) pp.add_printer("std_byte", "^std::byte$", StdBytePrinter) + pp.add_printer("unique_ptr", "^kstd::unique_ptr<.*>$", KstdUniquePtrPrinter) + pp.add_printer("shared_ptr", "^kstd::shared_ptr<.*>$", KstdSharedPtrPrinter) return pp -- cgit v1.2.3