{"modulePath":"github.com/Open-MBEE/OpenSysML","version":"v0.13.0","isLatest":true,"isStandardLibrary":false,"goos":"linux","goarch":"amd64","docs":"# package hostcap\n\nPackage hostcap reports what the host a build runs on can do beyond the language itself, so a capability that is not there is named rather than failing obscurely.\n\n## Variables\n\n```go\nvar ErrSpawnUnsupported = errors.New(\"a WebAssembly build cannot start external processes\")\n```\nErrSpawnUnsupported is the cause every external-process operation reports on a host that can start no process: every Go WebAssembly target (GOOS=js and GOOS=wasip1, both GOARCH=wasm). Callers reach it through errors.Is, wrapped into whichever typed error their layer answers with.\n\n## Functions\n\n```go\nfunc CheckSpawn(string) error\n```\nCheckSpawn returns nil: every native host starts processes, so nothing is refused here and every caller goes on to look the tool up and run it as it always has.\n\n## Types\n\n```go\ntype UnsupportedError struct {\n\t// Subject is what was to run: a solver, an engine's executable, a compiler.\n\tSubject string\n}\n```\nUnsupportedError names what cannot run on this host.\n\n```go\nfunc (e *UnsupportedError) Error() string\n```\nError names the subject and the cause it cannot run for.\n\n```go\nfunc (e *UnsupportedError) Unwrap() error\n```\nUnwrap returns ErrSpawnUnsupported.\n\n","path":"github.com/Open-MBEE/OpenSysML/internal/exec/hostcap","name":"hostcap","synopsis":"Package hostcap reports what the host a build runs on can do beyond the language itself, so a capability that is not there is named rather than failing obscurely.","isRedistributable":true}
