mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-10 04:57:26 +01:00
examples/shaderprecomp/metallib: stop using errgroup
This commit is contained in:
parent
10d9660125
commit
a391da6c77
@ -68,6 +68,7 @@ func run() error {
|
||||
srcs = append(srcs, defaultSrc)
|
||||
|
||||
for _, src := range srcs {
|
||||
// Avoid using errgroup.Group.
|
||||
// Compiling sources in parallel causes a mixed error message on the console.
|
||||
if err := compile(src, tmpdir); err != nil {
|
||||
return err
|
||||
|
@ -24,8 +24,6 @@ import (
|
||||
"os/exec"
|
||||
"path/filepath"
|
||||
|
||||
"golang.org/x/sync/errgroup"
|
||||
|
||||
"github.com/hajimehoshi/ebiten/v2/shaderprecomp"
|
||||
)
|
||||
|
||||
@ -54,15 +52,12 @@ func run() error {
|
||||
}
|
||||
srcs = append(srcs, defaultSrc)
|
||||
|
||||
var wg errgroup.Group
|
||||
for _, src := range srcs {
|
||||
source := src
|
||||
wg.Go(func() error {
|
||||
return compile(source, tmpdir)
|
||||
})
|
||||
}
|
||||
if err := wg.Wait(); err != nil {
|
||||
return err
|
||||
// Avoid using errgroup.Group.
|
||||
// Compiling sources in parallel causes a mixed error message on the console.
|
||||
if err := compile(src, tmpdir); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user