Composing a string during run time
Ziggit
Composing a string during run time
I tried composing a string during comptime. The string is dependent on a type given. Currently i m trying somthing like this: const size: usize = str: { comptime { var length: usize = calculateLength(); break :str length; } }; comptime var string: [size]u8 = undefined; const actual_length = len: { comptime { @memset(string[0..], 0); ...
0 comments
No comments yet.