From 4359978ef22a22ddd5a19adf18cbc80cb44244fb Mon Sep 17 00:00:00 2001 From: Taras Madan Date: Thu, 23 Feb 2023 14:28:18 +0100 Subject: all: ioutil is deprecated in go1.19 (#3718) --- pkg/compiler/const_file.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkg/compiler/const_file.go') diff --git a/pkg/compiler/const_file.go b/pkg/compiler/const_file.go index 78f3b03f9..0df0bb0ca 100644 --- a/pkg/compiler/const_file.go +++ b/pkg/compiler/const_file.go @@ -7,7 +7,7 @@ import ( "bufio" "bytes" "fmt" - "io/ioutil" + "os" "path/filepath" "regexp" "sort" @@ -168,7 +168,7 @@ func DeserializeConstFile(glob string, eh ast.ErrorHandler) *ConstFile { cf := NewConstFile() oldFormat := regexp.MustCompile(`_([a-z0-9]+)\.const$`) for _, f := range files { - data, err := ioutil.ReadFile(f) + data, err := os.ReadFile(f) if err != nil { eh(ast.Pos{}, fmt.Sprintf("failed to read const file: %v", err)) return nil -- cgit mrf-deployment