refactor: replace manual string concatenation with wrenStringFormat across VM core
Replace ad-hoc string construction using wrenNewString, wrenStringConcat, and sprintf with the new wrenStringFormat helper. This centralizes string formatting logic, reduces code duplication, and eliminates manual length calculations in wren_compiler.c, wren_core.c, wren_value.c, and wren_vm.c. Also introduces CONST_STRING macro for compile-time string literals and changes wrenNewUninitializedString return type from Value to ObjString* for consistency.
This commit is contained in:
@@ -83,9 +83,3 @@ print(" TODOs " + str(num_test_todos))
|
||||
print(" expectations " + str(num_expects))
|
||||
print(" non-empty lines " + str(num_test))
|
||||
print(" empty lines " + str(num_test_empty))
|
||||
print("\n")
|
||||
print("benchmark:")
|
||||
print(" files " + str(num_benchmark_files))
|
||||
print(" TODOs " + str(num_benchmark_todos))
|
||||
print(" non-empty lines " + str(num_benchmark))
|
||||
print(" empty lines " + str(num_benchmark_empty))
|
||||
|
||||
Reference in New Issue
Block a user