mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-10 22:13:39 +00:00
all: drop support for Go 1.16 and Go 1.17
This commit is contained in:
committed by
Ron Evans
parent
f094e895c5
commit
4695da83b7
@@ -235,7 +235,6 @@ func pathsToOverride(needsSyscallPackage bool) map[string]bool {
|
||||
"internal/bytealg/": false,
|
||||
"internal/reflectlite/": false,
|
||||
"internal/task/": false,
|
||||
"internal/itoa/": false, // TODO: Remove when we drop support for go 1.16
|
||||
"machine/": false,
|
||||
"net/": true,
|
||||
"os/": true,
|
||||
|
||||
+1
-5
@@ -27,8 +27,6 @@ import (
|
||||
"github.com/tinygo-org/tinygo/goenv"
|
||||
)
|
||||
|
||||
var addInstances func(*types.Info)
|
||||
|
||||
// Program holds all packages and some metadata about the program as a whole.
|
||||
type Program struct {
|
||||
config *compileopts.Config
|
||||
@@ -158,6 +156,7 @@ func Load(config *compileopts.Config, inputPkg string, clangHeaders string, type
|
||||
EmbedGlobals: make(map[string][]*EmbedFile),
|
||||
info: types.Info{
|
||||
Types: make(map[ast.Expr]types.TypeAndValue),
|
||||
Instances: make(map[*ast.Ident]types.Instance),
|
||||
Defs: make(map[*ast.Ident]types.Object),
|
||||
Uses: make(map[*ast.Ident]types.Object),
|
||||
Implicits: make(map[ast.Node]types.Object),
|
||||
@@ -165,9 +164,6 @@ func Load(config *compileopts.Config, inputPkg string, clangHeaders string, type
|
||||
Selections: make(map[*ast.SelectorExpr]*types.Selection),
|
||||
},
|
||||
}
|
||||
if addInstances != nil {
|
||||
addInstances(&pkg.info)
|
||||
}
|
||||
err := decoder.Decode(&pkg.PackageJSON)
|
||||
if err != nil {
|
||||
if err == io.EOF {
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
//go:build go1.18
|
||||
// +build go1.18
|
||||
|
||||
package loader
|
||||
|
||||
// Workaround for Go 1.17 support. Should be removed once we drop Go 1.17
|
||||
// support.
|
||||
|
||||
import (
|
||||
"go/ast"
|
||||
"go/types"
|
||||
)
|
||||
|
||||
func init() {
|
||||
addInstances = func(info *types.Info) {
|
||||
info.Instances = make(map[*ast.Ident]types.Instance)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user