this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

encoding/protobuf/jsonpb: remove unused code

When refactoring cue/load, I noticed that some pieces of code
were unused, which makes it less obvious what kinds of things
can be done. I used `staticcheck` to point out many other
places in the code that are unused.

This is one of those places. I feel it's better to remove this code
even if it might be used in the future (it's always there to be found
in the git history).

Signed-off-by: Roger Peppe <rogpeppe@gmail.com>
Change-Id: Ie025fe5557ecac15459c034c3d0876818554d166
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/549294
Unity-Result: CUEcueckoo <cueckoo+gerrithub@cuelang.org>
TryBot-Result: CUEcueckoo <cueckoo+gerrithub@cuelang.org>
Reviewed-by: Daniel Martí <mvdan@mvdan.cc>

authored by

Roger Peppe and committed by
Daniel Martí
b2476bd0 b41f26f7

-10
-10
encoding/protobuf/jsonpb/encoder.go
··· 80 80 errs errors.Error 81 81 } 82 82 83 - func (e *encoder) addErr(err errors.Error) { 84 - e.errs = errors.Append(e.errs, err) 85 - } 86 - 87 - func (e *encoder) addErrf(p token.Pos, schema cue.Value, format string, args ...interface{}) { 88 - format = "%s: " + format 89 - args = append([]interface{}{schema.Path()}, args...) 90 - e.addErr(errors.Newf(p, format, args...)) 91 - } 92 - 93 83 func (e *encoder) rewriteDecls(schema cue.Value, decls []ast.Decl) { 94 84 for _, f := range decls { 95 85 field, ok := f.(*ast.Field)