aboutsummaryrefslogtreecommitdiff
path: root/vendor/sigs.k8s.io/yaml/yaml_go110.go
blob: ab3e06a222a6dfff779e619e4ec196398ae600a0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// This file contains changes that are only compatible with go 1.10 and onwards.

// +build go1.10

package yaml

import "encoding/json"

// DisallowUnknownFields configures the JSON decoder to error out if unknown
// fields come along, instead of dropping them by default.
func DisallowUnknownFields(d *json.Decoder) *json.Decoder {
	d.DisallowUnknownFields()
	return d
}