Fix issue 21000 - allow use of std{in,out,err} with -preview=noshared…
…access
Thanks for your pull request and interest in making D better, @atilaneves! We are looking forward to reviewing it, and you should be hearing from a maintainer soon. Please verify that your PR follows this checklist:
- My PR is fully covered with tests (you can see the coverage diff by visiting the details link of the codecov check)
- My PR is as minimal as possible (smaller, focused PRs are easier to review than big ones)
- I have provided a detailed rationale explaining my changes
- New or modified functions have Ddoc comments (with
Params:andReturns:)
Please see CONTRIBUTING.md for more information.
If you have addressed all reviews or aren't sure how to proceed, don't hesitate to ping us with a simple comment.
Bugzilla references
| Auto-close | Bugzilla | Severity | Description |
|---|---|---|---|
| ✓ | 21000 | enhancement | -preview=nosharedaccess precludes use of stdin,stdout,stderr |
Testing this PR locally
If you don't have a local development environment setup, you can use Digger to test this PR:
dub run digger -- build "master + phobos#8562"
I don't know how to prove this works other than to say I tried it manually. I can't add the preview flag since this particular issue was covering up many more.
There are some stand-alone tests in the test directory, maybe that would be a good place?
ping @atilaneves
There are 2 ways we can go about this:
(1) add a test in the tests directory and compile it with -preview=nosharedaccess; this seems like an unpopular path since there are only 3 tests in that directory.
(2) continue fixing this up and put this test in a unittest once we are able to compile phobos with -preview=nosharedaccess`; I am inclined to go down this route as long as you are pursuing it @atilaneves .
Let me know what you prefer.
For now I'd prefer to put it in the test directory, but I don't see anything in the Makefile that runs those except for explicitly running the betterC tests.
TBH I think that this is overkill given that this is necessary and I'd be in favour of merging as-is.