Merge pull request #208 from danw/microfactory_race

Disable parallel compilation when using race detector
This commit is contained in:
Dan Willemsen 2018-04-30 15:54:15 -07:00 committed by GitHub
commit 1e428e0c05
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -400,7 +400,7 @@ func (p *GoPackage) Compile(config *Config, outDir string) error {
"-o", p.output, "-o", p.output,
"-p", p.Name, "-p", p.Name,
"-complete", "-pack", "-nolocalimports") "-complete", "-pack", "-nolocalimports")
if !isGo18 { if !isGo18 && !config.Race {
cmd.Args = append(cmd.Args, "-c", fmt.Sprintf("%d", runtime.NumCPU())) cmd.Args = append(cmd.Args, "-c", fmt.Sprintf("%d", runtime.NumCPU()))
} }
if config.Race { if config.Race {