Thread overview
Release D 2.086.0
May 05, 2019
Martin Nowak
May 06, 2019
Aldo
May 07, 2019
Andrea Fontana
May 07, 2019
Daniel N
May 07, 2019
Seb
May 08, 2019
Andrea Fontana
May 05, 2019
Glad to announce D 2.086.0, ♥ to the 51 contributors.

This release comes with copy constructors, a lowmem dmd switch, private member access for introspection traits, import std, dub init templates, and a single RTT resolution of dub dependencies.

http://dlang.org/download.html http://dlang.org/changelog/2.086.0.html

-Martin
May 06, 2019
On Sunday, 5 May 2019 at 11:53:22 UTC, Martin Nowak wrote:
> Glad to announce D 2.086.0, ♥ to the 51 contributors.
>
> This release comes with copy constructors, a lowmem dmd switch, private member access for introspection traits, import std, dub init templates, and a single RTT resolution of dub dependencies.
>
> http://dlang.org/download.html http://dlang.org/changelog/2.086.0.html
>
> -Martin

Awesome! I really like the dub linker change and traits change.

Thanks.
May 07, 2019
On Monday, 6 May 2019 at 09:52:32 UTC, Aldo wrote:
> On Sunday, 5 May 2019 at 11:53:22 UTC, Martin Nowak wrote:
>> Glad to announce D 2.086.0, ♥ to the 51 contributors.
>>
>> This release comes with copy constructors, a lowmem dmd switch, private member access for introspection traits, import std, dub init templates, and a single RTT resolution of dub dependencies.
>>
>> http://dlang.org/download.html http://dlang.org/changelog/2.086.0.html
>>
>> -Martin
>
> Awesome! I really like the dub linker change and traits change.
>
> Thanks.

Try this:

import std;
void main()
{
  std.file.write("/tmp/test", "hello");
}

How should I fix this?
May 07, 2019
On Tuesday, 7 May 2019 at 15:13:05 UTC, Andrea Fontana wrote:
>
> import std;
> void main()
> {
>   std.file.write("/tmp/test", "hello");
> }
>
> How should I fix this?

import std;
import file = std.file;
void main()
{
  file.write("/tmp/test", "hello");
}
May 07, 2019
On Tuesday, 7 May 2019 at 17:29:34 UTC, Daniel N wrote:
> On Tuesday, 7 May 2019 at 15:13:05 UTC, Andrea Fontana wrote:
>>
>> import std;
>> void main()
>> {
>>   std.file.write("/tmp/test", "hello");
>> }
>>
>> How should I fix this?
>
> import std;
> import file = std.file;
> void main()
> {
>   file.write("/tmp/test", "hello");
> }

Alternatively, you can use toFile. It was created because of these std.file - std.stdio overlap:

https://dlang.org/phobos/std_stdio.html#.toFile
May 08, 2019
On Tuesday, 7 May 2019 at 17:29:34 UTC, Daniel N wrote:
> On Tuesday, 7 May 2019 at 15:13:05 UTC, Andrea Fontana wrote:
>>
>> import std;
>> void main()
>> {
>>   std.file.write("/tmp/test", "hello");
>> }
>>
>> How should I fix this?
>
> import std;
> import file = std.file;
> void main()
> {
>   file.write("/tmp/test", "hello");
> }

It sounds strange to me I can't use anymore full package syntax due to "import std"