aprantl added a comment.

Could we test this by removing the key from an existing testcase?



================
Comment at: lldb/examples/python/crashlog.py:473
+        if 'procPath' in json_data:
+            self.crashlog.process_path = json_data['procPath']
 
----------------
Is it now undefined if it doesn't exist? Does that cause an exception when we 
try to access it?
Is there anything special about procPath, or should all the JSON keys be 
optional like this?
i.e., is there a `json_data.readOrDefault(key, default_value)` method?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D131033

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to