File tree 1 file changed +6
-7
lines changed
library/std/src/sys/unix/process
1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -172,13 +172,12 @@ impl Command {
172
172
crate :: sys_common:: process:: wait_with_output ( proc, pipes)
173
173
}
174
174
175
- // WatchOS and TVOS can theoretically spawn processes using `posix_spawn*`
176
- // (although it just fails with a runtime error AFAICT, so we don't yet
177
- // support it in `std`), but forbid use of `fork`/`exec*`. It's unclear the
178
- // extent to which these is restricted, but the headers say
179
- // `__WATCHOS_PROHIBITED __TVOS_PROHIBITED`, so we go out of our way to
180
- // avoid containing any calls to them at all, to avoid linking against their
181
- // symbols on those targets.
175
+ // WatchOS and TVOS headers mark the `fork`/`exec*` functions with
176
+ // `__WATCHOS_PROHIBITED __TVOS_PROHIBITED`, and indicate that the
177
+ // `posix_spawn*` functions should be used instead. It isn't entirely clear
178
+ // what `PROHIBITED` means here (e.g. if calls to these functions are
179
+ // allowed to exist in dead code), but it sounds bad, so we go out of our
180
+ // way to avoid that all-together.
182
181
#[ cfg( any( target_os = "tvos" , target_os = "watchos" ) ) ]
183
182
const ERR_APPLE_TV_WATCH_NO_FORK_EXEC : Error = io:: const_io_error!(
184
183
ErrorKind :: Unsupported ,
You can’t perform that action at this time.
0 commit comments