================
@@ -1068,6 +1068,29 @@ static void 
LoadLibCxxFormatters(lldb::TypeCategoryImplSP cpp_category_sp) {
                     eTypeOptionCascade,
                 true);
 
+  AddCXXSummary(
+      cpp_category_sp,
+      lldb_private::formatters::LibcxxChronoLocalSecondsSummaryProvider,
+      "libc++ std::chrono::local_seconds summary provider",
+      "^std::__[[:alnum:]]+::chrono::time_point<"
+      "std::__[[:alnum:]]+::chrono::local_t, "
+      "std::__[[:alnum:]]+::chrono::duration<long long, "
----------------
mordante wrote:

It is, seconds is defined as 

using seconds      = duration<[signed integer type of at least 35 
bits](http://eel.is/c++draft/time.syn#def:signed_integer_type_of_at_least_35_bits)>;

In libc++ this is hard coded to `long long` on all platforms
https://github.com/llvm/llvm-project/blob/main/libcxx/include/__chrono/duration.h#L287

There is some value in it to future proof it, if we ever get a platform where 
long is 64 bit and long long 128 bit.

I'll also update `LibcxxChronoSysSecondsSummaryProvider` above.

https://github.com/llvm/llvm-project/pull/88178
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to