Skip to content

Commit 9bb9df2

Browse files
xidaTadeasKriz
authored andcommitted
Fix: An address was returned when the string was empty
1 parent f14e948 commit 9bb9df2

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

LLDBPlugin/touchlab_kotlin_lldb/types/KonanStringSyntheticProvider.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,7 @@ def get_child_at_index(self, _):
2626

2727
def to_string(self):
2828
s = kotlin_object_to_string(self._process, self._valobj.unsigned)
29-
return '"{}"'.format(s) if s else self._valobj.GetValue()
29+
if s is None:
30+
return self._valobj.GetValue()
31+
else:
32+
return '"{}"'.format(s)

0 commit comments

Comments
 (0)