[Issue 19063] New: Delete useless aliases in astcodegen.d once all host compilers use 2.079.1 or later

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19063 Issue ID: 19063 Summary: Delete useless aliases in astcodegen.d once all host compilers use 2.079.1 or later Product: D Version: D2 Hardware: All OS: All

Re: Cleanup class after method?

2018-07-04 Thread Flaze07 via Digitalmars-d-learn
On Wednesday, 4 July 2018 at 16:02:25 UTC, Jonathan M Davis wrote: -dip1000 fully implements scope so that it verifies that no reference escapes, but it's not ready yet, let alone the default behavior. - Jonathan M Davis I read the proposal about -dip1000 ( not all, some ) and there is

how to import file from another path in dub ?

2018-07-04 Thread Flaze07 via Digitalmars-d-learn
I have a dub project, and I put the importPath to the path of the file I want to import and the source file to the source folder, and it appears that I have succeeded at importing the module, but there's one problem, it appears like I need to define some sort of thing, because the error says "

Re: libfirm-d - D bindings of Firm, a compiler IR based on the SSA form

2018-07-04 Thread ketmar via Digitalmars-d-announce
Basile B. wrote: On Sunday, 1 July 2018 at 15:03:30 UTC, ketmar wrote: Basile B. wrote: I've recently ported libfirm to D. great news and great work, thank you. yet i must admit that wrapping != porting. Right, i have used the wrong words. Title hopefully is not ambiguous. ah, tbh,

[Issue 19036] .tupleof order guarantee

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19036 --- Comment #7 from Guillaume Lathoud --- (In reply to Jacob Carlborg from comment #6) > You can concatenate a tuple of types using std.typecons.AliasSeq. That would > be used like this: > > alias a = AliasSeq!(typeof(BaseClass.tupleof),

[Issue 19059] Invalid integer literal 08 and 09 allowed

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19059 Mathias LANG changed: What|Removed |Added CC||pro.mathias.l...@gmail.com --- Comment #3

[Issue 19061] Specs for contracts don't include the changes brought by DIP 1009

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19061 Basile B. changed: What|Removed |Added Depends on||19062 Referenced Issues:

[Issue 19062] Accepted grammar for DIP 1009 introduces the `InExpression` which already exists

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19062 Basile B. changed: What|Removed |Added Blocks||19061 Referenced Issues:

Re: libfirm-d - D bindings of Firm, a compiler IR based on the SSA form

2018-07-04 Thread Basile B. via Digitalmars-d-announce
On Thursday, 5 July 2018 at 00:00:07 UTC, Chris M. wrote: On Sunday, 1 July 2018 at 12:04:06 UTC, Basile B. wrote: I've recently ported libfirm to D. This nice C library, developed at the Karlsruhe university, allows to build compiler back-ends, using the SSA intermediate representation.

Re: libfirm-d - D bindings of Firm, a compiler IR based on the SSA form

2018-07-04 Thread Basile B. via Digitalmars-d-announce
On Sunday, 1 July 2018 at 15:03:30 UTC, ketmar wrote: Basile B. wrote: I've recently ported libfirm to D. great news and great work, thank you. yet i must admit that wrapping != porting. Right, i have used the wrong words. Title hopefully is not ambiguous.

[Issue 19062] Accepted grammar for DIP 1009 introduces the `InExpression` which already exists

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19062 Basile B. changed: What|Removed |Added CC|reachz...@gmail.com | --- Comment #1 from Basile B. --- pull:

Re: libfirm-d - D bindings of Firm, a compiler IR based on the SSA form

2018-07-04 Thread Chris M. via Digitalmars-d-announce
On Sunday, 1 July 2018 at 12:04:06 UTC, Basile B. wrote: I've recently ported libfirm to D. This nice C library, developed at the Karlsruhe university, allows to build compiler back-ends, using the SSA intermediate representation. In theory it could even be used to make a new D compiler

[Issue 19062] Accepted grammar for DIP 1009 introduces the `InExpression` which already exists

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19062 Basile B. changed: What|Removed |Added CC||reachz...@gmail.com --

[Issue 19059] Invalid integer literal 08 and 09 allowed

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19059 Mike Franklin changed: What|Removed |Added CC||slavo5...@yahoo.com --- Comment #2 from

[Issue 19060] [REG2.081] Incorrect "Using this as a type is deprecated" error

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19060 ag0aep6g changed: What|Removed |Added CC||ag0ae...@gmail.com --- Comment #3 from ag0aep6g

[Issue 19062] New: Accepted grammar for DIP 1009 introduces the `InExpression` which already exists

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19062 Issue ID: 19062 Summary: Accepted grammar for DIP 1009 introduces the `InExpression` which already exists Product: D Version: D2 Hardware: All OS: All

[Issue 19059] Invalid integer literal 08 and 09 allowed

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19059 ag0aep6g changed: What|Removed |Added CC||ag0ae...@gmail.com --- Comment #1 from ag0aep6g

[Issue 19061] New: Specs for contracts don't include the changes brought by DIP 1009

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19061 Issue ID: 19061 Summary: Specs for contracts don't include the changes brought by DIP 1009 Product: D Version: D2 Hardware: All OS: All Status: NEW

[Issue 19060] [REG2.081] Incorrect "Using this as a type is deprecated" error

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19060 Richard Cattermole changed: What|Removed |Added Status|RESOLVED|REOPENED Resolution|INVALID

[Issue 19060] [REG2.081] Incorrect "Using this as a type is deprecated" error

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19060 --- Comment #1 from Richard Cattermole --- This was changed on purpose. https://dlang.org/changelog/2.081.0.html#deprecate_this_super_as_types --

[Issue 19060] [REG2.081] Incorrect "Using this as a type is deprecated" error

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19060 Richard Cattermole changed: What|Removed |Added Status|NEW |RESOLVED CC|

[Issue 19060] [REG2.081] Incorrect "Using this as a type is deprecated" error

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19060 johanenge...@weka.io changed: What|Removed |Added Keywords||industry --

[Issue 19060] New: [REG2.081] Incorrect "Using this as a type is deprecated" error

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19060 Issue ID: 19060 Summary: [REG2.081] Incorrect "Using this as a type is deprecated" error Product: D Version: D2 Hardware: All OS: All Status: NEW

Re: what's the correct way to handle unicode? - trying to print out graphemes here.

2018-07-04 Thread crimaniak via Digitalmars-d-learn
On Tuesday, 3 July 2018 at 14:39:34 UTC, ag0aep6g wrote: Looks like forum.dlang.org has a problem when they appear side by-side. Works (in the preview): ‍‍‍ ️‍ Doesn't work: ‍‍‍️‍ For me, it looks as the used font has ligatures for these faces. Mozilla under Linux, I guess it's

[Issue 18868] Separate compilation generates two static this functions, runs it twice

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18868 --- Comment #6 from Atila Neves --- I forgot to mention that the issue here is the same issue as before with the unittest names - counters can't and won't work, because the number will vary depending on how the compiler is invoked. --

[Issue 18868] Separate compilation generates two static this functions, runs it twice

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18868 Atila Neves changed: What|Removed |Added CC||atila.ne...@gmail.com --- Comment #5 from

Re: Issues with undefined symbols when using Vibe on Windows

2018-07-04 Thread kinke via Digitalmars-d-learn
On Wednesday, 4 July 2018 at 20:36:55 UTC, Chris M. wrote: On Tuesday, 3 July 2018 at 18:35:43 UTC, kinke wrote: On Tuesday, 3 July 2018 at 17:54:08 UTC, Seb wrote: [...] AFAICT, the issue is that MinGW is used, as opposed to MinGW-w64 (a confusingly separate project unfortunately AFAIK).

Re: dmd optimizer now converted to D!

2018-07-04 Thread Walter Bright via Digitalmars-d
On 7/4/2018 10:22 AM, H. S. Teoh wrote: Actually, what will make dmd produce better code IMO is: (1) a more aggressive metric for the inliner (currently it gives up too easily, at the slightest increase in code complexity), and (2) implement loop unrolling. It's already doing some loop

Re: dmd optimizer now converted to D!

2018-07-04 Thread Walter Bright via Digitalmars-d
On 7/3/2018 4:03 PM, H. S. Teoh wrote: Hopefully this eventually translates to actual improvements to the optimizer? That's the plan. D code is a lot more malleable than C++.

[Issue 19059] New: Invalid integer literal 08 and 09 allowed

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19059 Issue ID: 19059 Summary: Invalid integer literal 08 and 09 allowed Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: trivial

[Issue 19058] New: __traits(getUnitTests) stops working with separate compilation in dmd 2.081.0

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19058 Issue ID: 19058 Summary: __traits(getUnitTests) stops working with separate compilation in dmd 2.081.0 Product: D Version: D2 Hardware: x86_64 OS: Linux

LDC 1.11.0 beta

2018-07-04 Thread kinke via Digitalmars-d-announce
Glad to announce the first beta for LDC 1.11. * Based on D 2.081.0. * Prebuilt packages now using LLVM 6.0.1 and including additional cross-compilation targets (MIPS, MSP430, RISC-V and WebAssembly). Full release log and downloads:

Re: Issues with undefined symbols when using Vibe on Windows

2018-07-04 Thread Chris M. via Digitalmars-d-learn
On Tuesday, 3 July 2018 at 18:35:43 UTC, kinke wrote: On Tuesday, 3 July 2018 at 17:54:08 UTC, Seb wrote: [...] AFAICT, the issue is that MinGW is used, as opposed to MinGW-w64 (a confusingly separate project unfortunately AFAIK). There's no SetWindowLongPtr for Win32, it's #defined as

[Issue 19057] 2.079 changelog variadic template and default arguments

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19057 johanenge...@weka.io changed: What|Removed |Added Keywords||industry --

[Issue 19057] New: 2.079 changelog variadic template and default arguments

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19057 Issue ID: 19057 Summary: 2.079 changelog variadic template and default arguments Product: D Version: D2 Hardware: All OS: All Status: NEW

Re: Compilation is taking a ton of memory

2018-07-04 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 06/27/2018 12:00 PM, Mario Silva wrote: Hello, Our code base has been growing steadily and it's currently at a point where my 16GB machine just freezes when we're compiling our code. This happens because DMD just consumes all my memory for a while. Also, it's taking a long time to

Re: I have a plan.. I really DO

2018-07-04 Thread Maksim Fomin via Digitalmars-d-announce
On Friday, 29 June 2018 at 07:03:52 UTC, Dmitry Olshansky wrote: I never ever (I think) did something provocative, something to finally see: ... My 5 cents inspired by experimenting with D some years ago. 1. Programming became niche oriented and quite diverse. Writing new language requires

Re: I have a plan.. I really DO

2018-07-04 Thread JN via Digitalmars-d-announce
On Wednesday, 4 July 2018 at 19:49:00 UTC, Ecstatic Coder wrote: For instance, to be a perfect C++ alternative, D would probably need to be 100% : 1. usable (strings, slices, etc) without GC 2. interoperable with any existing C++ library For for game development : 3. compilable on all game

Re: I have a plan.. I really DO

2018-07-04 Thread Ecstatic Coder via Digitalmars-d-announce
Exactly. As Walter has said before, (and I paraphrase,) it's far more profitable to cater to *existing* customers who are already using your product, to make their experience better, than to bend over backwards to satisfy the critical crowd who points at issue X and claim that they would not

Re: D and shared librery

2018-07-04 Thread Jacob Carlborg via Digitalmars-d
On 2018-07-02 04:15, Seb wrote: Shared libraries are working fine on Linux and OSX. For macOS LDC is required. -- /Jacob Carlborg

Re: I have a plan.. I really DO

2018-07-04 Thread Ecstatic Coder via Digitalmars-d-announce
On Wednesday, 4 July 2018 at 18:05:15 UTC, wjoe wrote: On Wednesday, 4 July 2018 at 08:50:57 UTC, Ecstatic Coder wrote: But indeed, being able use D in a GC-free environment (like C++ and Rust do) would be something many people may NEED, for instance to be able to EASILY use D for

Re: Compilation is taking a ton of memory

2018-07-04 Thread Jacob Carlborg via Digitalmars-d
On 2018-06-27 18:00, Mario Silva wrote: Hello, Our code base has been growing steadily and it's currently at a point where my 16GB machine just freezes when we're compiling our code. This happens because DMD just consumes all my memory for a while. Also, it's taking a long time to compile

Re: DVM - D Version Manager 0.4.4

2018-07-04 Thread Jacob Carlborg via Digitalmars-d-announce
On 2018-07-03 03:34, Tony wrote: Thanks, that worked! It doesn't announce where it put the compiler, which turns out to be: C:\Users\\AppData\Roaming\dvm\ You're not supposed to know where it puts the compiler. You're activating it with "dvm use " where "" is the version you want to

[Issue 19036] .tupleof order guarantee

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19036 --- Comment #6 from Jacob Carlborg --- (In reply to Guillaume Lathoud from comment #5) > One the side: is there an easy way to concatenate two expression sequences? > I am thinking of something like BaseClass.tupleof ~ ChildClass.tupleof You can

Re: I have a plan.. I really DO

2018-07-04 Thread H. S. Teoh via Digitalmars-d-announce
On Wed, Jul 04, 2018 at 06:05:15PM +, wjoe via Digitalmars-d-announce wrote: > On Wednesday, 4 July 2018 at 08:50:57 UTC, Ecstatic Coder wrote: > > But indeed, being able use D in a GC-free environment (like C++ and > > Rust do) would be something many people may NEED, for instance to be > >

Re: I have a plan.. I really DO

2018-07-04 Thread wjoe via Digitalmars-d-announce
On Wednesday, 4 July 2018 at 08:50:57 UTC, Ecstatic Coder wrote: But indeed, being able use D in a GC-free environment (like C++ and Rust do) would be something many people may NEED, for instance to be able to EASILY use D for soft-realtime applications like games. This has to be the no. 1

Re: Using C++ with D / returning a templated type from C++

2018-07-04 Thread Steven Schveighoffer via Digitalmars-d-learn
On 7/4/18 1:32 PM, Robert M. Münch wrote: I have the following C++ code and want to give the D/C++ integration a new try: template class Array {...} class myClass {...} typedef Array myClassArray; myClassArray classA::getArray() noexcept {...} How does the D binding for

Re: Using C++ with D / returning a templated type from C++

2018-07-04 Thread vit via Digitalmars-d-learn
On Wednesday, 4 July 2018 at 17:32:49 UTC, Robert M. Münch wrote: I have the following C++ code and want to give the D/C++ integration a new try: template class Array {...} class myClass {...} typedef Array myClassArray; myClassArray classA::getArray() noexcept

[Issue 19056] New: UDAs can be added to imports but not retrieved

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19056 Issue ID: 19056 Summary: UDAs can be added to imports but not retrieved Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: minor

Re: dmd optimizer now converted to D!

2018-07-04 Thread rikki cattermole via Digitalmars-d
On 05/07/2018 5:22 AM, H. S. Teoh wrote: If we can nail down these two things, I think dmd's codegen quality should improve significantly. Not disagreeing with your assessment. But that is a lot of work, so why not try out a 'free' experiment as an addition? Just for interests sake.

Using C++ with D / returning a templated type from C++

2018-07-04 Thread Robert M. Münch via Digitalmars-d-learn
I have the following C++ code and want to give the D/C++ integration a new try: template class Array {...} class myClass {...} typedef Array myClassArray; myClassArray classA::getArray() noexcept {...} How does the D binding for this look like? I tried something

Re: Inference of auto storage classes for interface function return type

2018-07-04 Thread ag0aep6g via Digitalmars-d-learn
On 07/04/2018 05:59 PM, Timoses wrote: There's an empty 19.10.10 point without content[3] : D. Maybe a placeholder? [...] [3]: https://dlang.org/spec/function.html#inout-functions Just a bug. https://github.com/dlang/dlang.org/pull/2407

Re: dmd optimizer now converted to D!

2018-07-04 Thread H. S. Teoh via Digitalmars-d
On Thu, Jul 05, 2018 at 04:55:09AM +1200, rikki cattermole via Digitalmars-d wrote: > On 05/07/2018 4:06 AM, jmh530 wrote: > > On Tuesday, 3 July 2018 at 23:05:00 UTC, rikki cattermole wrote: > > > > > > On that note, I have a little experiment that I'd like to see > > > done. How would the

Re: dmd optimizer now converted to D!

2018-07-04 Thread rikki cattermole via Digitalmars-d
On 05/07/2018 4:06 AM, jmh530 wrote: On Tuesday, 3 July 2018 at 23:05:00 UTC, rikki cattermole wrote: On that note, I have a little experiment that I'd like to see done. How would the codegen change, if you were to triple the time the optimizer had to run? Would it make any difference to

Re: what's the correct way to handle unicode? - trying to print out graphemes here.

2018-07-04 Thread ag0aep6g via Digitalmars-d-learn
On 07/04/2018 05:12 PM, aliak wrote: Is updating unicode stuff to the latest a matter of some config file somewhere with the code point configurations that result in specific graphemes? I don't know. [...] Also, any reason (technical or otherwise) that we have to slice a grapheme to get it

Re: Release D 2.081.0

2018-07-04 Thread Joakim via Digitalmars-d-announce
On Wednesday, 4 July 2018 at 14:55:56 UTC, Mike Parker wrote: On Wednesday, 4 July 2018 at 10:03:57 UTC, Martin Nowak wrote: Glad to announce D 2.081.0. This release comes with... http://dlang.org/download.html http://dlang.org/changelog/2.081.0.html - -Martin The blog announcement:

Re: dmd optimizer now converted to D!

2018-07-04 Thread jmh530 via Digitalmars-d
On Tuesday, 3 July 2018 at 23:05:00 UTC, rikki cattermole wrote: On that note, I have a little experiment that I'd like to see done. How would the codegen change, if you were to triple the time the optimizer had to run? Would it make any difference to compile DMD with LDC?

Re: Is package.d a good idea?

2018-07-04 Thread Jonathan M Davis via Digitalmars-d
On Wednesday, July 04, 2018 11:50:07 Steven Schveighoffer via Digitalmars-d wrote: > The obvious pros to ditching package.d and using a directory and module > with the same name are: 1. no ambiguity in the filesystem (assuming you > don't have weird package/file schemes) and 2. It's more

Re: Cleanup class after method?

2018-07-04 Thread Jonathan M Davis via Digitalmars-d-learn
On Wednesday, July 04, 2018 15:47:25 JN via Digitalmars-d-learn wrote: > Imagine I have a very short-lived class: > > void print(File f) > { > PrinterManager pm = new PrinterManager(); > pm.print(f); > } > > My understanding is that PrinterManager will be GC allocated, and > when it goes

Re: Inference of auto storage classes for interface function return type

2018-07-04 Thread Timoses via Digitalmars-d-learn
On Wednesday, 4 July 2018 at 15:12:15 UTC, Jonathan M Davis wrote: You can make opIndex inout instead of const. That way, inout applies to the invisible this reference, just like it would with const. Awww, thanks! I was kinda hovering around this[1] section and didn't quite see the

Re: Cleanup class after method?

2018-07-04 Thread Mr.Bingo via Digitalmars-d-learn
On Wednesday, 4 July 2018 at 15:47:25 UTC, JN wrote: Imagine I have a very short-lived class: void print(File f) { PrinterManager pm = new PrinterManager(); pm.print(f); } My understanding is that PrinterManager will be GC allocated, and when it goes out of scope, the GC will possibly

Re: Is package.d a good idea?

2018-07-04 Thread Steven Schveighoffer via Digitalmars-d
On 7/4/18 11:29 AM, Jonathan M Davis wrote: On Wednesday, July 04, 2018 11:13:07 Steven Schveighoffer via Digitalmars-d wrote: I think if we went the different route we would have to provide a mechanism to declare inside the module "this is a package". Maybe "package module"? I would point

Cleanup class after method?

2018-07-04 Thread JN via Digitalmars-d-learn
Imagine I have a very short-lived class: void print(File f) { PrinterManager pm = new PrinterManager(); pm.print(f); } My understanding is that PrinterManager will be GC allocated, and when it goes out of scope, the GC will possibly clean it up at some point in the future. But I know

Re: Is package.d a good idea?

2018-07-04 Thread Jonathan M Davis via Digitalmars-d
On Wednesday, July 04, 2018 11:13:07 Steven Schveighoffer via Digitalmars-d wrote: > I think if we went the different route we would have to provide a > mechanism to declare inside the module "this is a package". Maybe > "package module"? I would point out that the pretty much the only reason

Re: what's the correct way to handle unicode? - trying to print out graphemes here.

2018-07-04 Thread aliak via Digitalmars-d-learn
On Tuesday, 3 July 2018 at 14:37:32 UTC, Adam D. Ruppe wrote: On Tuesday, 3 July 2018 at 13:32:52 UTC, aliak wrote: [...] What system are you on? Successfully printing this stuff depends on a lot of display details too, like writeln goes to a terminal/console and they are rarely configured

Re: Is package.d a good idea?

2018-07-04 Thread Steven Schveighoffer via Digitalmars-d
On 7/4/18 11:06 AM, aliak wrote: On Wednesday, 4 July 2018 at 14:54:41 UTC, Steven Schveighoffer wrote: On 7/1/18 7:36 AM, Yuxuan Shui wrote: In Rust, they have something call mod.rs, which is very similar to package.d. When you use a module 'foo' in Rust, it can either be 'foo.rs' or

Re: what's the correct way to handle unicode? - trying to print out graphemes here.

2018-07-04 Thread aliak via Digitalmars-d-learn
On Tuesday, 3 July 2018 at 14:43:37 UTC, Steven Schveighoffer wrote: On 7/3/18 10:37 AM, ag0aep6g wrote: On Tuesday, 3 July 2018 at 13:32:52 UTC, aliak wrote: foreach (c; "‍‍‍️‍") {   writeln(c); } So basically the above just doesn't work. Prints gibberish. Because you're printing one

Re: Inference of auto storage classes for interface function return type

2018-07-04 Thread Jonathan M Davis via Digitalmars-d-learn
On Wednesday, July 04, 2018 14:07:35 Timoses via Digitalmars-d-learn wrote: > How can I return inferred storage class from interface functions? > I can't use auto as return value in interface. Neither can I use > "inout" as I don't pass a parameter. > > // Ref Type > interface IRef > { >

Re: Is package.d a good idea?

2018-07-04 Thread Steven Schveighoffer via Digitalmars-d
On 7/4/18 10:59 AM, Adam D. Ruppe wrote: On Wednesday, 4 July 2018 at 14:54:41 UTC, Steven Schveighoffer wrote: How would this affect the package attribute? Nothing should change, since packages are determined from the D module declaration, not the filename or directory layout. This is

Re: Inference of auto storage classes for interface function return type

2018-07-04 Thread Nicholas Wilson via Digitalmars-d-learn
On Wednesday, 4 July 2018 at 14:07:35 UTC, Timoses wrote: How can I return inferred storage class from interface functions? I can't use auto as return value in interface. Neither can I use "inout" as I don't pass a parameter. // Ref Type interface IRef {

Re: Is package.d a good idea?

2018-07-04 Thread aliak via Digitalmars-d
On Wednesday, 4 July 2018 at 14:54:41 UTC, Steven Schveighoffer wrote: On 7/1/18 7:36 AM, Yuxuan Shui wrote: In Rust, they have something call mod.rs, which is very similar to package.d. When you use a module 'foo' in Rust, it can either be 'foo.rs' or 'foo/mod.rs'. If 'foo' has sub-modules,

Re: Is package.d a good idea?

2018-07-04 Thread Adam D. Ruppe via Digitalmars-d
On Wednesday, 4 July 2018 at 14:54:41 UTC, Steven Schveighoffer wrote: How would this affect the package attribute? Nothing should change, since packages are determined from the D module declaration, not the filename or directory layout. This is even true with package.d itself, but it is a

Re: Release D 2.081.0

2018-07-04 Thread Mike Parker via Digitalmars-d-announce
On Wednesday, 4 July 2018 at 10:03:57 UTC, Martin Nowak wrote: Glad to announce D 2.081.0. This release comes with... http://dlang.org/download.html http://dlang.org/changelog/2.081.0.html - -Martin The blog announcement: https://dlang.org/blog/2018/07/04/dmd-2-081-0-released/ Reddit:

Re: Is package.d a good idea?

2018-07-04 Thread Steven Schveighoffer via Digitalmars-d
On 7/1/18 7:36 AM, Yuxuan Shui wrote: In Rust, they have something call mod.rs, which is very similar to package.d. When you use a module 'foo' in Rust, it can either be 'foo.rs' or 'foo/mod.rs'. If 'foo' has sub-modules, it has to be 'foo/mod.rs'. Now in the Rust 2018 edition, they are

Re: Parenthesis around if/for/while condition is not necessary

2018-07-04 Thread Timon Gehr via Digitalmars-d
On 24.06.2018 13:27, Basile B. wrote: FYI this works fine, as expected it's just some small parser changes. I didn't touch to for and foreach for now. I think that SwitchStatement is a candidate too. https://github.com/BBasile/dmd/commit/5455a65c8fdee5a6d198782d1f168906b59e6d3d if (a+b)*c

Inference of auto storage classes for interface function return type

2018-07-04 Thread Timoses via Digitalmars-d-learn
How can I return inferred storage class from interface functions? I can't use auto as return value in interface. Neither can I use "inout" as I don't pass a parameter. // Ref Type interface IRef { Ref opIndex(size_t idx) const; } class

[Issue 18743] ConditionalExpression and AssignExpression should require parentheses

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18743 github-bugzi...@puremagic.com changed: What|Removed |Added Status|NEW |RESOLVED

[Issue 18743] ConditionalExpression and AssignExpression should require parentheses

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18743 --- Comment #7 from github-bugzi...@puremagic.com --- Commits pushed to master at https://github.com/dlang/dmd https://github.com/dlang/dmd/commit/0cfc780539838d8c6294174a0587fd5b5c33de94 Fix Issue 18743 - ConditionalExpression and AssignExpression

Re: Why do core.atomic functions require shared

2018-07-04 Thread Boris-Barboris via Digitalmars-d
On Wednesday, 4 July 2018 at 10:47:12 UTC, Jonathan M Davis wrote: At this point, to operate on anything that's shared, either means using atomics or protecting the data with a mutex (be that with a synchronized block / function or a mutex object) and temporarily casting away shared while

[Issue 19036] .tupleof order guarantee

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19036 --- Comment #5 from Guillaume Lathoud --- (In reply to Jacob Carlborg from comment #4) > To get the fields of the base class you can upcast it and then use .tupleof. > That is: (cast(Base) subclassObject).tupleof. You can also use some traits > in

Re: DotfiM v0.0.1 - A dotfile manager

2018-07-04 Thread Timoses via Digitalmars-d-announce
On Wednesday, 4 July 2018 at 09:36:18 UTC, biocyberman wrote: On Saturday, 30 June 2018 at 14:27:39 UTC, Timoses wrote: Thought I'd try a release of this project of mine which I find very useful. [...] Dot files are usually very personalized. I wonder what DotfiM can do more than cloning

Re: Why do core.atomic functions require shared

2018-07-04 Thread Jonathan M Davis via Digitalmars-d
On Wednesday, July 04, 2018 09:25:27 Boris-Barboris via Digitalmars-d wrote: > Given the pain of shared usage with std and pretty much every > library in existence, I cowboyed the server without this > qualifier. One of the mechanisms required atomic class reference > compare-and-set, and the

[Issue 19036] .tupleof order guarantee

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19036 --- Comment #4 from Jacob Carlborg --- (In reply to Guillaume Lathoud from comment #3) > In another use case there is a class hierarchy, I > also need the fields of the base class, which .tupleof does not provide, so > I am not sure anymore how

Re: Release D 2.081.0

2018-07-04 Thread Martin Nowak via Digitalmars-d-announce
On 07/04/2018 12:03 PM, Martin Nowak wrote: > Glad to announce D 2.081.0. > > This release comes with... Improved C++ compatibility (https://dlang.org/changelog/2.081.0.html#extern_cpp_overhaul) DIP1009 - Expression-Based Contract Syntax

[Issue 19053] debug should escape @safe

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19053 github-bugzi...@puremagic.com changed: What|Removed |Added Status|NEW |RESOLVED

[Issue 19053] debug should escape @safe

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19053 --- Comment #1 from github-bugzi...@puremagic.com --- Commits pushed to master at https://github.com/dlang/dmd https://github.com/dlang/dmd/commit/aae8f5610f7843b272e2aa21119d99c4f30d1036 Fix Issue 19053 - debug should escape @safe

Re: Release D 2.081.0

2018-07-04 Thread Basile B. via Digitalmars-d-announce
On Wednesday, 4 July 2018 at 10:09:27 UTC, Basile B. wrote: On Wednesday, 4 July 2018 at 10:03:57 UTC, Martin Nowak wrote: Glad to announce D 2.081.0. This release comes with... http://dlang.org/download.html http://dlang.org/changelog/2.081.0.html - -Martin thx, keep on "git gud".

Re: Release D 2.081.0

2018-07-04 Thread Basile B. via Digitalmars-d-announce
On Wednesday, 4 July 2018 at 10:03:57 UTC, Martin Nowak wrote: Glad to announce D 2.081.0. This release comes with... http://dlang.org/download.html http://dlang.org/changelog/2.081.0.html - -Martin thx, keep on "git gud".

Release D 2.081.0

2018-07-04 Thread Martin Nowak via Digitalmars-d-announce
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 Glad to announce D 2.081.0. This release comes with... http://dlang.org/download.html http://dlang.org/changelog/2.081.0.html - -Martin -BEGIN PGP SIGNATURE- iQIzBAEBCgAdFiEEpzRNrTw0HqEtE8TmsnOBFhK7GTkFAls8m4QACgkQsnOBFhK7

Re: DotfiM v0.0.1 - A dotfile manager

2018-07-04 Thread biocyberman via Digitalmars-d-announce
On Saturday, 30 June 2018 at 14:27:39 UTC, Timoses wrote: Thought I'd try a release of this project of mine which I find very useful. [...] Dot files are usually very personalized. I wonder what DotfiM can do more than cloning and linking stuffs.

Why do core.atomic functions require shared

2018-07-04 Thread Boris-Barboris via Digitalmars-d
Given the pain of shared usage with std and pretty much every library in existence, I cowboyed the server without this qualifier. One of the mechanisms required atomic class reference compare-and-set, and the class reference is not shared, because it would otherwise require, like, 30 or 40

[Issue 19055] New: [404 Not Found] std.digest.digest

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19055 Issue ID: 19055 Summary: [404 Not Found] std.digest.digest Product: D Version: D2 Hardware: All URL: http://dlang.org/ OS: All Status: NEW

Re: I have a plan.. I really DO

2018-07-04 Thread Ecstatic Coder via Digitalmars-d-announce
Throw everything we can this dude's way so we can make D the most powerful we can We need pattern matching, we need typeclasses, we need HKT's, we need linear types, we need @nogc Phobos, we need concurrency so fearless I can change any variable and not give two shits Personally I don't

Re: How to call a C function from D that takes a FILE * as an argument?

2018-07-04 Thread WebFreak001 via Digitalmars-d-learn
On Wednesday, 4 July 2018 at 02:54:47 UTC, Joe wrote: On Wednesday, 4 July 2018 at 02:16:00 UTC, Seb wrote: Hmm, calling e.g. fprintf with stdout should just work: --- void main() { import core.stdc.stdio; fprintf(stdout, "Hello %s", "world".ptr); } --- Could you maybe provide your

Re: Is package.d a good idea?

2018-07-04 Thread WebFreak001 via Digitalmars-d
On Sunday, 1 July 2018 at 11:36:51 UTC, Yuxuan Shui wrote: In Rust, they have something call mod.rs, which is very similar to package.d. When you use a module 'foo' in Rust, it can either be 'foo.rs' or 'foo/mod.rs'. If 'foo' has sub-modules, it has to be 'foo/mod.rs'. Now in the Rust 2018

Re: Parenthesis around if/for/while condition is not necessary

2018-07-04 Thread Daniel N via Digitalmars-d
On Monday, 2 July 2018 at 20:28:06 UTC, Seb wrote: On Sunday, 1 July 2018 at 12:02:03 UTC, Nick Treleaven wrote: On Sunday, 24 June 2018 at 23:40:56 UTC, Timoses wrote: The others may be rewritten to not have a leading "!" as well, e.g. if (!(t1.ty == Tarray && t2.ty == Tarray &&

Re: Parenthesis around if/for/while condition is not necessary

2018-07-04 Thread FeepingCreature via Digitalmars-d
On Saturday, 23 June 2018 at 04:45:07 UTC, user1234 wrote: There is this case that requires parens: if a && b c; Is there a missing && or not ? It seems obvious for a human but compiler parsers are "apparatchiks", i.e rules are rules. That being said this would work by allowing parens

[Issue 19031] [REG 2.080.0] assert failure when subclassing C++ class with D class

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19031 RazvanN changed: What|Removed |Added CC||razvan.nitu1...@gmail.com --- Comment #2 from

[Issue 19054] alloca() crashes with SEGFAULT after an exception

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19054 --- Comment #2 from Tomer Filiba (weka) --- i mentioned RCX because of https://github.com/dlang/druntime/blob/9a8edfb48e4842180c706ee26ebd8edb10be53f4/src/rt/alloca.d#L230 --

[Issue 19054] alloca() crashes with SEGFAULT after an exception

2018-07-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19054 Tomer Filiba (weka) changed: What|Removed |Added CC||e...@weka.io --

  1   2   >