@@ -979,6 +979,57 @@ static void LoadLibCxxFormatters(lldb::TypeCategoryImplSP cpp_category_sp) {
979
979
" std::unordered_map iterator synthetic children" ,
980
980
" ^std::__[[:alnum:]]+::__hash_map_(const_)?iterator<.+>$" ,
981
981
stl_synth_flags, true );
982
+ // Chrono duration typedefs
983
+ cpp_category_sp->AddTypeSummary (
984
+ " ^std::__[[:alnum:]]+::chrono::nanoseconds" , eFormatterMatchRegex,
985
+ TypeSummaryImplSP (new StringSummaryFormat (
986
+ eTypeOptionHideChildren | eTypeOptionHideValue, " ${var.__rep_} ns" )));
987
+ cpp_category_sp->AddTypeSummary (
988
+ " ^std::__[[:alnum:]]+::chrono::microseconds" , eFormatterMatchRegex,
989
+ TypeSummaryImplSP (new StringSummaryFormat (
990
+ eTypeOptionHideChildren | eTypeOptionHideValue, " ${var.__rep_} µs" )));
991
+ cpp_category_sp->AddTypeSummary (
992
+ " ^std::__[[:alnum:]]+::chrono::milliseconds" , eFormatterMatchRegex,
993
+ TypeSummaryImplSP (new StringSummaryFormat (
994
+ eTypeOptionHideChildren | eTypeOptionHideValue, " ${var.__rep_} ms" )));
995
+ cpp_category_sp->AddTypeSummary (
996
+ " ^std::__[[:alnum:]]+::chrono::seconds" , eFormatterMatchRegex,
997
+ TypeSummaryImplSP (new StringSummaryFormat (
998
+ eTypeOptionHideChildren | eTypeOptionHideValue, " ${var.__rep_} s" )));
999
+ cpp_category_sp->AddTypeSummary (
1000
+ " ^std::__[[:alnum:]]+::chrono::minutes" , eFormatterMatchRegex,
1001
+ TypeSummaryImplSP (new StringSummaryFormat (eTypeOptionHideChildren |
1002
+ eTypeOptionHideValue,
1003
+ " ${var.__rep_} min" )));
1004
+ cpp_category_sp->AddTypeSummary (
1005
+ " ^std::__[[:alnum:]]+::chrono::hours" , eFormatterMatchRegex,
1006
+ TypeSummaryImplSP (new StringSummaryFormat (
1007
+ eTypeOptionHideChildren | eTypeOptionHideValue, " ${var.__rep_} h" )));
1008
+
1009
+ cpp_category_sp->AddTypeSummary (
1010
+ " ^std::__[[:alnum:]]+::chrono::days" , eFormatterMatchRegex,
1011
+ TypeSummaryImplSP (new StringSummaryFormat (eTypeOptionHideChildren |
1012
+ eTypeOptionHideValue,
1013
+ " ${var.__rep_} days" )));
1014
+ cpp_category_sp->AddTypeSummary (
1015
+ " ^std::__[[:alnum:]]+::chrono::weeks" , eFormatterMatchRegex,
1016
+ TypeSummaryImplSP (new StringSummaryFormat (eTypeOptionHideChildren |
1017
+ eTypeOptionHideValue,
1018
+ " ${var.__rep_} weeks" )));
1019
+ cpp_category_sp->AddTypeSummary (
1020
+ " ^std::__[[:alnum:]]+::chrono::months" , eFormatterMatchRegex,
1021
+ TypeSummaryImplSP (new StringSummaryFormat (eTypeOptionHideChildren |
1022
+ eTypeOptionHideValue,
1023
+ " ${var.__rep_} months" )));
1024
+ cpp_category_sp->AddTypeSummary (
1025
+ " ^std::__[[:alnum:]]+::chrono::years" , eFormatterMatchRegex,
1026
+ TypeSummaryImplSP (new StringSummaryFormat (eTypeOptionHideChildren |
1027
+ eTypeOptionHideValue,
1028
+ " ${var.__rep_} years" )));
1029
+ cpp_category_sp->AddTypeSummary (
1030
+ " ^std::__[[:alnum:]]+::chrono::seconds" , eFormatterMatchRegex,
1031
+ TypeSummaryImplSP (new StringSummaryFormat (
1032
+ eTypeOptionHideChildren | eTypeOptionHideValue, " ${var.__rep_} s" )));
982
1033
}
983
1034
984
1035
static void LoadLibStdcppFormatters (lldb::TypeCategoryImplSP cpp_category_sp) {
0 commit comments