Skip to content

Commit

Permalink
Merge pull request #291 from xushiwei/q
Browse files Browse the repository at this point in the history
go1.18
  • Loading branch information
xushiwei authored Oct 20, 2023
2 parents dc69970 + f88b88f commit 7a7af25
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 158 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
Test:
strategy:
matrix:
go-version: [1.16.x, 1.18.x, 1.21.x]
go-version: [1.18.x, 1.21.x]
os: [ubuntu-latest, windows-latest, macos-11]
runs-on: ${{ matrix.os }}
steps:
Expand Down
2 changes: 1 addition & 1 deletion codebuild.go
Original file line number Diff line number Diff line change
Expand Up @@ -1149,7 +1149,7 @@ func (p *CodeBuilder) Index(nidx int, twoValue bool, src ...ast.Node) *CodeBuild
log.Println("Index", nidx, twoValue)
}
args := p.stk.GetArgs(nidx + 1)
if enableTypeParams {
if enableTypeParams && nidx > 0 {
if _, ok := args[1].Type.(*TypeType); ok {
return p.inferType(nidx, args, src...)
}
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/goplus/gox

go 1.16
go 1.18

require golang.org/x/tools v0.14.0

Expand Down
3 changes: 0 additions & 3 deletions types_go118.go → typeparams.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
//go:build go1.18
// +build go1.18

/*
Copyright 2022 The GoPlus Authors (goplus.org)
Licensed under the Apache License, Version 2.0 (the "License");
Expand Down
152 changes: 0 additions & 152 deletions types_go117.go

This file was deleted.

0 comments on commit 7a7af25

Please sign in to comment.