auto adjust code

This commit is contained in:
Christopher Homberger
2026-02-22 20:58:46 +01:00
parent 949a40c7a5
commit d187ac2fc1
86 changed files with 617 additions and 617 deletions

View File

@@ -10,7 +10,7 @@ import (
// It behaves like the C# implementation in the repository
// it supports escaped braces and numeric argument indices.
// Format specifiers (e.g. :D) are recognised but currently ignored.
func Format(formatStr string, args ...interface{}) (string, error) {
func Format(formatStr string, args ...any) (string, error) {
var sb strings.Builder
i := 0
for i < len(formatStr) {
@@ -47,7 +47,7 @@ func Format(formatStr string, args ...interface{}) (string, error) {
}
// append argument (format specifier is ignored here)
arg := args[idx]
sb.WriteString(fmt.Sprintf("%v", arg))
fmt.Fprintf(&sb, "%v", arg)
if spec != "" {
// placeholder for future specifier handling
_ = spec