replace testdata/scripts/*.txt with testdata/script/*.txtar

Following the best practices from upstream.
In particular, the "txt" extension is somewhat ambiguous.

This may cause some conflicts due to the git diff noise,
but hopefully we won't ever do this again.
This commit is contained in:
Daniel Martí
2022-09-06 13:59:19 +01:00
parent 9d46fe917a
commit 99c12e396a
28 changed files with 2 additions and 2 deletions
+55
View File
@@ -0,0 +1,55 @@
env GOGARBLE=*
garble build
! binsubstr main$exe ${WORK} 'garble_main.go' 'GenericFunc' 'GenericVector' 'PredeclaredSignedInteger' 'StringableSignedInteger' 'CombineEmbeds' 'GenericParam'
-- go.mod --
module test/main
go 1.18
-- garble_main.go --
package main
func main() {
GenericFunc[int, int](1, 2)
var _ GenericVector[int]
g1 := GenericGraph[string]{Content: "Foo"}
g1.Edges = make([]GenericGraph[string], 1)
g2 := GenericGraph[*[]byte]{Content: new([]byte)}
g2.Edges = make([]GenericGraph[*[]byte], 1)
}
func GenericFunc[GenericParamA, B any](x GenericParamA, y B) {}
type GenericVector[GenericParamT any] []GenericParamT
type GenericGraph[T any] struct {
Content T
Edges []GenericGraph[T]
}
type PredeclaredSignedInteger interface {
int | int8 | int16 | int32 | int64
}
type StringableSignedInteger interface {
~int | ~int8 | ~int16 | ~int32 | ~int64
String() string
}
type CombineEmbeds interface {
string | int
interface { EmbeddedMethod() }
RegularMethod()
}
type Slice[T any] []T
func sliceOfPointer() Slice[*any] {
return []*any{}
}