www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - idiomatic output given -preview=nosharedaccess ,

reply Bruce Carneal <bcarneal gmail.com> writes:
Given -preview=nosharedaccess on the command line, "hello world" 
fails to compile (you are referred to core.atomic ...).

What is the idiomatic way to get writeln style output from a 
nosharedaccess program?

Is separate compilation the way to go?
Jun 30 2020
parent reply Steven Schveighoffer <schveiguy gmail.com> writes:
On 6/30/20 3:56 PM, Bruce Carneal wrote:
 Given -preview=nosharedaccess on the command line, "hello world" fails 
 to compile (you are referred to core.atomic ...).
 
 What is the idiomatic way to get writeln style output from a 
 nosharedaccess program?
 
 Is separate compilation the way to go?
 
writeln uses the shared stdout. The answer is -- update Phobos so it works with -nosharedaccess :) -Steve
Jun 30 2020
parent reply Stanislav Blinov <stanislav.blinov gmail.com> writes:
On Tuesday, 30 June 2020 at 20:04:33 UTC, Steven Schveighoffer 
wrote:

 The answer is -- update Phobos so it works with -nosharedaccess 
 :)
Yeah... and dip1000. And dip1008. And dip<yournumberhere>... :)
Jun 30 2020
parent reply Bruce Carneal <bcarneal gmail.com> writes:
On Tuesday, 30 June 2020 at 20:12:59 UTC, Stanislav Blinov wrote:
 On Tuesday, 30 June 2020 at 20:04:33 UTC, Steven Schveighoffer 
 wrote:

 The answer is -- update Phobos so it works with 
 -nosharedaccess :)
Yeah... and dip1000. And dip1008. And dip<yournumberhere>... :)
Didn't want to be snippity but, yeah, with "hello world" breaking I thought it was time to fix the standard library. Thanks for the polite confirmation(s).
Jun 30 2020
parent Bruce Carneal <bcarneal gmail.com> writes:
On Tuesday, 30 June 2020 at 20:43:00 UTC, Bruce Carneal wrote:
 On Tuesday, 30 June 2020 at 20:12:59 UTC, Stanislav Blinov 
 wrote:
 On Tuesday, 30 June 2020 at 20:04:33 UTC, Steven Schveighoffer 
 wrote:

 The answer is -- update Phobos so it works with 
 -nosharedaccess :)
Yeah... and dip1000. And dip1008. And dip<yournumberhere>... :)
Didn't want to be snippity but, yeah, with "hello world" breaking I thought it was time to fix the standard library. Thanks for the polite confirmation(s).
Looking at the stdio.d source it appears that a cast on one line within a template could give nosharedaccess programs access to stdio, stdout, and stderr. A bug/enhancement request was filed.
Jul 01 2020