github.com/searKing/golang/go@v1.2.117/encoding/internal/tag/nopTagFunc.go (about) 1 // Copyright 2020 The searKing Author. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 package tag 6 7 import "reflect" 8 9 type nopTagFunc struct { 10 } 11 12 func (_ *nopTagFunc) handle(e *tagState, v reflect.Value, opts tagOpts) (isUserDefined bool) { 13 // nop 14 return false 15 } 16 17 func newNopConverter(t reflect.Type) tagFunc { 18 tagFn := &nopTagFunc{} 19 return tagFn.handle 20 }