mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
Formatting option "%h" now supports pointers.
This commit is contained in:
@@ -495,6 +495,11 @@ fn usz? Formatter.vprintf(&self, String format, any[] anys)
|
||||
out = ((char*)current.ptr)[:current.type.sizeof];
|
||||
break;
|
||||
}
|
||||
if (current.type.kindof == POINTER)
|
||||
{
|
||||
out = ((*(char**)current.ptr))[:current.type.inner.sizeof];
|
||||
break;
|
||||
}
|
||||
total_len += self.out_substr("<INVALID>")!;
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user