Skip to content

Commit

Permalink
deps: Update dependencies including CC.
Browse files Browse the repository at this point in the history
  • Loading branch information
dennwc committed Jul 5, 2024
1 parent 2ec0e1e commit d626074
Show file tree
Hide file tree
Showing 14 changed files with 76 additions and 112 deletions.
14 changes: 9 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ on:
jobs:
test:
name: Test
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: '1.18.x'
go-version: '1.22.x'
- name: actions/checkout
uses: actions/checkout@v2
- name: actions/cache
Expand All @@ -29,12 +29,12 @@ jobs:
test-tcc:
name: TCC Tests
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: '1.18.x'
go-version: '1.22.x'
- name: actions/checkout
uses: actions/checkout@v2
- name: actions/cache
Expand All @@ -56,8 +56,12 @@ jobs:
# test-gcc:
# name: GCC Tests
# runs-on: ubuntu-20.04
# runs-on: ubuntu-22.04
# steps:
# - name: Install Go
# uses: actions/setup-go@v2
# with:
# go-version: '1.22.x'
# - name: actions/checkout
# uses: actions/checkout@v2
# - name: actions/cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: '1.18.x'
go-version: '1.22.x'
- name: Checkout
uses: actions/checkout@v2
with:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Although it was successfully tested on multiple projects, it might _change the b

**Transpiled projects:**

- [Potrace](./examples/potrace) (image vectorization library)
- [Potrace](https://github.com/gotranspile/gotrace) (image vectorization library)
- [G722](https://github.com/gotranspile/g722) (audio codec)
- [PortableGL](https://github.com/TotallyGamerJet/pgl) (OpenGL 3.x implementation)
- [Physac](https://github.com/koteyur/physac-go) (2D physics engine)
Expand Down
7 changes: 3 additions & 4 deletions cmd/cxgo/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import (
"errors"
"fmt"
"go/format"
"io/ioutil"
"log"
"os"
"os/exec"
Expand Down Expand Up @@ -162,7 +161,7 @@ func mergeBool(val *bool, def bool) bool {
func run(cmd *cobra.Command, args []string) error {
defer cxgo.CallFinals()
conf, _ := cmd.Flags().GetString("config")
data, err := ioutil.ReadFile(conf)
data, err := os.ReadFile(conf)
if err != nil {
return err
}
Expand Down Expand Up @@ -251,7 +250,7 @@ func run(cmd *cobra.Command, args []string) error {
if fdata, err := format.Source(data); err == nil {
data = fdata
}
return ioutil.WriteFile(filepath.Join(c.Out, f.Name), data, 0644)
return os.WriteFile(filepath.Join(c.Out, f.Name), data, 0644)
}
idents := make(map[string]cxgo.IdentConfig)
for _, v := range c.Idents {
Expand Down Expand Up @@ -368,7 +367,7 @@ require (
%s %s
)
`, c.Package, libs.RuntimePackage, libs.RuntimePackageVers)
if err := ioutil.WriteFile(filepath.Join(c.Out, "go.mod"), buf.Bytes(), 0644); err != nil {
if err := os.WriteFile(filepath.Join(c.Out, "go.mod"), buf.Bytes(), 0644); err != nil {
return err
}
}
Expand Down
7 changes: 3 additions & 4 deletions compile_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package cxgo
import (
"bytes"
"fmt"
"io/ioutil"
"os"
"os/exec"
"path/filepath"
Expand Down Expand Up @@ -62,7 +61,7 @@ func goTranspileAndExec(t testing.TB, cxgo, dir string, cfile string) progOut {
})
require.NoError(t, err)
goProjectMod(t, dir)
gosrc, err := ioutil.ReadFile(gofile)
gosrc, err := os.ReadFile(gofile)
require.NoError(t, err)
t.Logf("// === Go source ===\n%s", string(gosrc))
return goCompileAndExec(t, dir)
Expand Down Expand Up @@ -112,11 +111,11 @@ require (
)
replace github.com/gotranspile/cxgo v0.0.0-local => %s`, cxgo)

err = ioutil.WriteFile(filepath.Join(out, "go.mod"), []byte(gomod), 0644)
err = os.WriteFile(filepath.Join(out, "go.mod"), []byte(gomod), 0644)
require.NoError(t, err)

// allows running go mod tidy without having other source files and still keep require above
err = ioutil.WriteFile(filepath.Join(out, "dummy.go"), []byte(`
err = os.WriteFile(filepath.Join(out, "dummy.go"), []byte(`
package main
import _ "github.com/gotranspile/cxgo/runtime/libc"
Expand Down
6 changes: 2 additions & 4 deletions examples/potrace/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,6 @@ package gotrace
import (
"io"
"io/ioutil"
"net/http"
"os"
"testing"
Expand All @@ -553,7 +552,7 @@ func TestPotrace(t *testing.T) {
t.Fatal(resp.Status)
}
tfile, err := ioutil.TempFile("", "potrace_")
tfile, err := os.CreateTemp("", "potrace_")
if err != nil {
t.Fatal(err)
}
Expand Down Expand Up @@ -742,7 +741,6 @@ package gotrace
import (
"io"
"io/ioutil"
"net/http"
"os"
"testing"
Expand All @@ -762,7 +760,7 @@ func TestPotrace(t *testing.T) {
t.Fatal(resp.Status)
}
tfile, err := ioutil.TempFile("", "potrace_")
tfile, err := os.CreateTemp("", "potrace_")
if err != nil {
t.Fatal(err)
}
Expand Down
5 changes: 2 additions & 3 deletions flow_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cxgo

import (
"fmt"
"io/ioutil"
"os"
"os/exec"
"path/filepath"
Expand Down Expand Up @@ -1215,9 +1214,9 @@ goto L_1
func writeDotFile(name string, data []byte) {
name = strings.ReplaceAll(name, " ", "_")
fname := name + ".dot"
_ = ioutil.WriteFile(fname, data, 0644)
_ = os.WriteFile(fname, data, 0644)
sdata, _ := exec.Command("dot", "-Tsvg", fname).Output()
_ = ioutil.WriteFile(name+".svg", sdata, 0644)
_ = os.WriteFile(name+".svg", sdata, 0644)
_ = os.Remove(fname)
}

Expand Down
5 changes: 3 additions & 2 deletions gcc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cxgo

import (
"bytes"
"io/ioutil"
"os"
"path/filepath"
"runtime/debug"
Expand Down Expand Up @@ -56,6 +55,8 @@ func TestGCCExecute(t *testing.T) {

ignoreTests := map[string]string{
"limits-caselabels": "OOM",
"limits-declparen": "stack exceeded",
"limits-exprparen": "stack exceeded",
}

blacklist := map[string]struct{}{}
Expand Down Expand Up @@ -104,7 +105,7 @@ func TestGCCExecute(t *testing.T) {
oname := filepath.Base(path) + ".go"
env := libs.NewEnv(types.Config32())
_, lib := isLib[tname]
if data, err := ioutil.ReadFile(path); err == nil && !bytes.Contains(data, []byte("main")) {
if data, err := os.ReadFile(path); err == nil && !bytes.Contains(data, []byte("main")) {
t.Log("testing as a library (no main found)")
lib = true
}
Expand Down
27 changes: 13 additions & 14 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,23 @@ module github.com/gotranspile/cxgo
go 1.19

require (
github.com/bmatcuk/doublestar v1.3.0
github.com/bmatcuk/doublestar v1.3.4
github.com/chewxy/math32 v1.10.1
github.com/emicklei/dot v0.16.0
github.com/spf13/cobra v0.0.5
github.com/stretchr/testify v1.4.0
gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2
modernc.org/cc/v3 v3.36.1
modernc.org/token v1.0.0
github.com/emicklei/dot v1.6.2
github.com/spf13/cobra v1.8.1
github.com/stretchr/testify v1.9.0
gopkg.in/yaml.v3 v3.0.1
modernc.org/cc/v3 v3.41.0
modernc.org/token v1.1.0
)

require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/inconshreveable/mousetrap v1.0.0 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0 // indirect
github.com/spf13/pflag v1.0.3 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
lukechampine.com/uint128 v1.2.0 // indirect
modernc.org/mathutil v1.4.1 // indirect
modernc.org/strutil v1.1.1 // indirect
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec // indirect
github.com/spf13/pflag v1.0.5 // indirect
lukechampine.com/uint128 v1.3.0 // indirect
modernc.org/mathutil v1.6.0 // indirect
modernc.org/strutil v1.2.0 // indirect
)
91 changes: 30 additions & 61 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,69 +1,38 @@
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
github.com/bmatcuk/doublestar v1.3.0 h1:1jLE2y0VpSrOn/QR9G4f2RmrCtkM3AuATcWradjHUvM=
github.com/bmatcuk/doublestar v1.3.0/go.mod h1:wiQtGV+rzVYxB7WIlirSN++5HPtPlXEo9MEoZQC/PmE=
github.com/bmatcuk/doublestar v1.3.4 h1:gPypJ5xD31uhX6Tf54sDPUOBXTqKH4c9aPY66CyQrS0=
github.com/bmatcuk/doublestar v1.3.4/go.mod h1:wiQtGV+rzVYxB7WIlirSN++5HPtPlXEo9MEoZQC/PmE=
github.com/chewxy/math32 v1.10.1 h1:LFpeY0SLJXeaiej/eIp2L40VYfscTvKh/FSEZ68uMkU=
github.com/chewxy/math32 v1.10.1/go.mod h1:dOB2rcuFrCn6UHrze36WSLVPKtzPMRAQvBvUwkSsLqs=
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/cpuguy83/go-md2man/v2 v2.0.4/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo=
github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
github.com/emicklei/dot v0.16.0 h1:7PseyizTgeQ/aSF1eo4LcEfWlQSlzamFZpzY/nMB9EY=
github.com/emicklei/dot v0.16.0/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s=
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
github.com/google/go-cmp v0.5.3 h1:x95R7cp+rSeeqAMI2knLtQ0DKlaBhv2NrtrOvafPHRo=
github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM=
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY=
github.com/emicklei/dot v1.6.2 h1:08GN+DD79cy/tzN6uLCT84+2Wk9u+wvqP+Hkx/dIR8A=
github.com/emicklei/dot v1.6.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s=
github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38=
github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8=
github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0 h1:OdAsTTz6OkFY5QxjkYwrChwuRruF69c169dPK26NUlk=
github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo=
github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cobra v0.0.5 h1:f0B+LkLX6DtmRH1isoNA9VTtNUK9K8xYd28JNNfOv/s=
github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU=
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
github.com/spf13/pflag v1.0.3 h1:zPAT6CGy6wXeQ7NtTnaTerfKOsV6V6F8agHXFiazDkg=
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
github.com/stretchr/testify v1.4.0 h1:2E4SXV/wtOkTonXsotYi4li6zVWxYlZuYNCXe9XRJyk=
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0=
github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec h1:W09IVJc94icq4NjY3clb7Lk8O1qJ8BdBEF8z0ibU0rE=
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo=
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/spf13/cobra v1.8.1 h1:e5/vxKd/rZsfSJMUX1agtjeTDf+qv1/JdBF8gg5k9ZM=
github.com/spf13/cobra v1.8.1/go.mod h1:wHxEcudfqmLYa8iTfL+OuZPbBZkmvliBWKIezN3kD9Y=
github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg=
github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=
gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2 h1:XZx7nhd5GMaZpmDaEHFVafUZC7ya0fuo7cSJ3UCKYmM=
gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
lukechampine.com/uint128 v1.1.1/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk=
lukechampine.com/uint128 v1.2.0 h1:mBi/5l91vocEN8otkC5bDLhi2KdCticRiwbdB0O+rjI=
lukechampine.com/uint128 v1.2.0/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk=
modernc.org/cc/v3 v3.36.1 h1:CICrjwr/1M4+6OQ4HJZ/AHxjcwe67r5vPUF518MkO8A=
modernc.org/cc/v3 v3.36.1/go.mod h1:NFUHyPn4ekoC/JHeZFfZurN6ixxawE1BnVonP/oahEI=
modernc.org/mathutil v1.2.2/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E=
modernc.org/mathutil v1.4.1 h1:ij3fYGe8zBF4Vu+g0oT7mB06r8sqGWKuJu1yXeR4by8=
modernc.org/mathutil v1.4.1/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E=
modernc.org/strutil v1.1.1 h1:xv+J1BXY3Opl2ALrBwyfEikFAj8pmqcpnfmuwUwcozs=
modernc.org/strutil v1.1.1/go.mod h1:DE+MQQ/hjKBZS2zNInV5hhcipt5rLPWkmpbGeW5mmdw=
modernc.org/token v1.0.0 h1:a0jaWiNMDhDUtqOj09wvjWWAqd3q7WpBulmL9H2egsk=
modernc.org/token v1.0.0/go.mod h1:UGzOrNV1mAFSEB63lOFHIpNRUVMvYTc6yu1SMY/XTDM=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
lukechampine.com/uint128 v1.3.0 h1:cDdUVfRwDUDovz610ABgFD17nXD4/uDgVHl2sC3+sbo=
lukechampine.com/uint128 v1.3.0/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk=
modernc.org/cc/v3 v3.41.0 h1:QoR1Sn3YWlmA1T4vLaKZfawdVtSiGx8H+cEojbC7v1Q=
modernc.org/cc/v3 v3.41.0/go.mod h1:Ni4zjJYJ04CDOhG7dn640WGfwBzfE0ecX8TyMB0Fv0Y=
modernc.org/mathutil v1.6.0 h1:fRe9+AmYlaej+64JsEEhoWuAYBkOtQiMEU7n/XgfYi4=
modernc.org/mathutil v1.6.0/go.mod h1:Ui5Q9q1TR2gFm0AQRqQUaBWFLAhQpCwNcuhBOSedWPo=
modernc.org/strutil v1.2.0 h1:agBi9dp1I+eOnxXeiZawM8F4LawKv4NzGWSaLfyeNZA=
modernc.org/strutil v1.2.0/go.mod h1:/mdcBmfOibveCTBxUl5B5l6W+TTH1FXPLHZE6bTosX0=
modernc.org/token v1.1.0 h1:Xl7Ap9dKaEs5kLoOQeQmPWevfnk/DM5qcLcYlA8ys6Y=
modernc.org/token v1.1.0/go.mod h1:UGzOrNV1mAFSEB63lOFHIpNRUVMvYTc6yu1SMY/XTDM=
7 changes: 3 additions & 4 deletions tcc_test.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cxgo

import (
"io/ioutil"
"os"
"path/filepath"
"runtime/debug"
Expand Down Expand Up @@ -72,7 +71,7 @@ func TestTCCExecute(t *testing.T) {
"55_lshift_type": {},
"60_errors_and_warnings": {},
"73_arm64": {},
"75_array_in_struct_init": {}, // CC type checker failure
"75_array_in_struct_init": {}, // FIXME: cxgo handles struct field init incorrectly?
"77_push_pop_macro": {}, // FIXME: cannot detect if a macro was redefined
"78_vla_label": {},
"79_vla_continue": {},
Expand All @@ -81,7 +80,7 @@ func TestTCCExecute(t *testing.T) {
"89_nocode_wanted": {},
"90_struct-init": {},
"92_enum_bitfield": {},
"93_integer_promotion": {}, // TODO: some issues with char promotion
"93_integer_promotion": {}, // FIXME: one issue with char promotion
"94_generic": {},
"95_bitfields": {},
"95_bitfields_ms": {},
Expand Down Expand Up @@ -163,7 +162,7 @@ func TestTCCExecute(t *testing.T) {
if s, ok := overrideExpect[tname]; ok {
exp = []byte(s)
} else {
exp, err = ioutil.ReadFile(epath)
exp, err = os.ReadFile(epath)
require.NoError(t, err)
}
if string(exp) != string(got) && skip {
Expand Down
Loading

0 comments on commit d626074

Please sign in to comment.