Skip to content

Commit 6f587cf

Browse files
committed
[lldb-dap] Use optional
1 parent c4d909a commit 6f587cf

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lldb/tools/lldb-dap/Protocol/ProtocolTypes.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -585,8 +585,10 @@ llvm::json::Value toJSON(const SteppingGranularity &SG) {
585585
bool fromJSON(const json::Value &Params, StepInTarget &SIT, json::Path P) {
586586
json::ObjectMapper O(Params, P);
587587
return O && O.map("id", SIT.id) && O.map("label", SIT.label) &&
588-
O.map("line", SIT.line) && O.map("column", SIT.column) &&
589-
O.map("endLine", SIT.endLine) && O.map("endColumn", SIT.endColumn);
588+
O.mapOptional("line", SIT.line) &&
589+
O.mapOptional("column", SIT.column) &&
590+
O.mapOptional("endLine", SIT.endLine) &&
591+
O.mapOptional("endColumn", SIT.endColumn);
590592
}
591593

592594
llvm::json::Value toJSON(const StepInTarget &SIT) {

0 commit comments

Comments
 (0)