[Lldb-commits] [PATCH] D131719: [lldb/crashlog] Adapt raw text crashlog exception to json format

Med Ismail Bennani via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Aug 11 15:22:45 PDT 2022


mib added inline comments.


================
Comment at: lldb/examples/python/crashlog.py:628
                                  )
+    exception_type_regex = re.compile(r'^Exception Type:\s+(EXC_.*) \s*\((.*)\)')
+    exception_codes_regex = re.compile(r'^Exception Codes:\s+(0x[0-9a-fA-F]+),\s*(0x[0-9a-fA-F]+)')
----------------
kastiglione wrote:
> consider using `EXC_[A-Z_]+` or `EXC_.*?` to not over match.
> 
> ` \s*` (a space followed by `\s*`) could be replaced with `\s+`
Yeah, that's better! Also, I suspect the second group to be optional, so I need to change this regex anyway


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D131719/new/

https://reviews.llvm.org/D131719



More information about the lldb-commits mailing list