Description
new(builtinLibs.String()) and new(proxy.String()) are invalid Go. The built-in new() requires a type argument (e.g., new(string)), not a value expression. builtinLibs.String() evaluates to a string value at runtime, so new(...) cannot accept it. This is either a compilation error preventing the package from building, or—if shadowed by some local declaration—it would allocate a zero-valued string instead of the intended value. The project imports go.bug.st/f which provides f.ToPtr() for exactly this purpose.
Severity: critical
File: commands/service_settings.go
Expected Behavior
The code should handle this case properly to avoid unexpected errors or degraded quality.
Description
new(builtinLibs.String())andnew(proxy.String())are invalid Go. The built-innew()requires a type argument (e.g.,new(string)), not a value expression.builtinLibs.String()evaluates to astringvalue at runtime, sonew(...)cannot accept it. This is either a compilation error preventing the package from building, or—if shadowed by some local declaration—it would allocate a zero-valued string instead of the intended value. The project importsgo.bug.st/fwhich providesf.ToPtr()for exactly this purpose.Severity:
criticalFile:
commands/service_settings.goExpected Behavior
The code should handle this case properly to avoid unexpected errors or degraded quality.