It was only being used in a couple places (outside of tests). So
existing trivial usages of Errorf were replaced with errors.New and the
OpError.Error method was rewritten to use string concatenation, which
ends up being faster and using fewer allocations. Though in practice
the performance of error message serialization is not going to impact an
application in a stable production environment.
It was only being used in a couple places (outside of tests). So existing trivial usages of Errorf were replaced with errors.New and the OpError.Error method was rewritten to use string concatenation, which ends up being faster and using fewer allocations. Though in practice the performance of error message serialization is not going to impact an application in a stable production environment.