Re: D alternative for node.js's socket.IO?

2018-10-21 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 10/21/18 11:59 PM, Neia Neutuladh wrote: On Sun, 21 Oct 2018 23:05:06 -0400, Nick Sabalausky (Abscissa) wrote: I'm afraid I'm not familiar with socket.io, and the homepage doesn't seem to tell me much (it doesn't even say whether it uses TCP or UDP). But that said, in D, the gold-standard

Re: Need help with setting up LDC to cross-compile to Android/ARM

2018-10-21 Thread H. S. Teoh via Digitalmars-d
On Sat, Oct 20, 2018 at 09:51:28AM +, Joakim via Digitalmars-d wrote: > On Friday, 19 October 2018 at 22:19:31 UTC, H. S. Teoh wrote: [...] > > Haha, I feel so silly now. NDK r13b does not seem to have the > > sysroot subdir required by the clang build command, that's why it > > couldn't find

Re: D Binding to GUI libraries

2018-10-21 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 10/21/18 1:29 PM, Russel Winder wrote: No, D should not forget DWT. It's one of the few (they only?) D GUI toolkit that has a native look and feel. Apart from GtkD on GTK+ systems, and dqml, QtE5, qtD, and dqt on Qt, and wxD on wxWidgets. Qt and wxWidgets pride themselves on being able to

Re: D Binding to GUI libraries

2018-10-21 Thread Gerald via Digitalmars-d
On Monday, 22 October 2018 at 04:41:08 UTC, Nick Sabalausky (Abscissa) wrote: On 10/21/18 1:13 PM, Russel Winder wrote: [...] First of all, minor nitpick: Unless some bombshell news occurred that I managed to miss, Ubuntu pushes their own Unity, NOT Gnome. Yes, that's still GTK, but

Re: D Binding to GUI libraries

2018-10-21 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 10/21/18 1:13 PM, Russel Winder wrote: On Sun, 2018-10-21 at 04:15 -0400, Nick Sabalausky (Abscissa) via Digitalmars-d wrote: […] That's pure nonsense: It's Linux - unless one option actually goes away (KDE is still actively used and developed), then there's no such thing as one "winning"

[Issue 1861] (D1 only) .sort fails if opCmp takes a ref param

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=1861 Mathias LANG changed: What|Removed |Added Status|REOPENED|RESOLVED CC|

[Issue 5749] (D1 only) argument evaluation order of chained function from right

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=5749 Mathias LANG changed: What|Removed |Added Status|NEW |RESOLVED CC|

[Issue 11904] Error: this cannot be interpreted at compile-time (core/time.di)

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=11904 Mathias LANG changed: What|Removed |Added Status|NEW |RESOLVED CC|

Re: D alternative for node.js's socket.IO?

2018-10-21 Thread Neia Neutuladh via Digitalmars-d
On Sun, 21 Oct 2018 23:05:06 -0400, Nick Sabalausky (Abscissa) wrote: > I'm afraid I'm not familiar with socket.io, and the homepage doesn't > seem to tell me much (it doesn't even say whether it uses TCP or UDP). > But that said, in D, the gold-standard for pretty much *anything* > related to

[Issue 4485] CT only arrays appear in executable

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=4485 Mathias LANG changed: What|Removed |Added Status|NEW |RESOLVED CC|

Re: D Binding to GUI libraries [was Interesting Observation from JAXLondon]

2018-10-21 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 10/21/18 7:36 AM, Andre Pany wrote: While talking about bindings, do not forget Delphi. It has still a good eco system. Combining Delphi's advanced Runtime reflection capabilities with D's advanced compile reflection capabilities opens this eco system. I created a proof of concept and

Re: D alternative for node.js's socket.IO?

2018-10-21 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 10/21/18 4:58 PM, Fleel wrote: On Sunday, 21 October 2018 at 20:41:41 UTC, JN wrote: On Sunday, 21 October 2018 at 20:14:46 UTC, Fleel wrote: Does anyone know of a good D alternative for the socket.IO server (https://socket.io)? I would like to transition my server from node.js to D, but I

[Issue 19197] Replace instances of typeid(T).getHash(..) with hashOf

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19197 Nathan S. changed: What|Removed |Added CC||n8sh.second...@hotmail.com --- Comment #2 from

Re: D T-Shirts

2018-10-21 Thread Mike Parker via Digitalmars-d
On Monday, 22 October 2018 at 01:08:11 UTC, Manu wrote: FWIW, I'm disappointed with the quality of my dman shirt; I've put it through the wash no more than 3-4 times and the print is aggressively deteriorating with each wash. I don't tend to wear it because it's disintegrating so fast. I'm

Re: We need an internal keyword.

2018-10-21 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 10/20/18 11:17 PM, 12345swordy wrote: So that classes can share some of their variables but not others in a module. IE. class A { internal int A; //This is shared in the module private int B; // But not this. } No need to reintroduce the "Friend" feature from cpp. I've always felt the

Re: shared - i need it to be useful

2018-10-21 Thread Joakim via Digitalmars-d
On Monday, 22 October 2018 at 00:22:19 UTC, Manu wrote: On Sun, Oct 21, 2018 at 2:35 PM Walter Bright via Digitalmars-d wrote: On 10/21/2018 2:08 PM, Walter Bright wrote: > On 10/21/2018 12:20 PM, Nicholas Wilson wrote: >> Yes, but the problem you describe is arises from implicit >>

Re: Building GUI projects with D

2018-10-21 Thread dangbinghoo via Digitalmars-d-learn
On Saturday, 20 October 2018 at 15:40:07 UTC, karis njiru wrote: Hi. Am a computer science student from Kenya and decided to use D for my class project on Principles of Programming Languages. Am having a lot of fun with D but have come across an issue. I have been using Visual D for the past 2

Re: shared - i need it to be useful

2018-10-21 Thread Neia Neutuladh via Digitalmars-d
On Sun, 21 Oct 2018 17:35:38 -0700, Manu wrote: > On Sun, Oct 21, 2018 at 3:15 PM Neia Neutuladh via Digitalmars-d > wrote: >> If we only used your proposal and only used @safe code, we wouldn't >> have any data races, but that's only because we wouldn't have any >> shared data. We'd have shared

Re: assigment to null class object member compiled? is this a bug?

2018-10-21 Thread dangbinghoo via Digitalmars-d-learn
On Friday, 19 October 2018 at 09:08:32 UTC, Vijay Nayar wrote: Technically the code you have is syntactically correct. You are permitted to create a class variable without assigning it to a class object. (Assigning it to a class object would look like "A a = new A();") Which section of The

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Monday, 22 October 2018 at 00:55:00 UTC, Timon Gehr wrote: On 22.10.18 02:46, Nicholas Wilson wrote: On Monday, 22 October 2018 at 00:38:33 UTC, Timon Gehr wrote: I just did, Link please? https://forum.dlang.org/post/pqii8k$11u3$1...@digitalmars.com That contains no code. Not all of

Re: D T-Shirts

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 5:35 PM Mike Parker via Digitalmars-d wrote: > > On Sunday, 21 October 2018 at 20:04:02 UTC, Fleel wrote: > > It would be awesome if there were T-Shirts with D-man on them. > > I would totally buy one, and would help to support the > > foundation too... > > We've got a

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 5:55 PM Timon Gehr via Digitalmars-d wrote: > > On 22.10.18 02:45, Manu wrote: > > On Sun, Oct 21, 2018 at 5:35 PM Timon Gehr via Digitalmars-d > > wrote: > >> > >> On 21.10.18 20:46, Manu wrote: > Shared data is only useful if, at some point, it is read/written, >

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 5:40 PM Timon Gehr via Digitalmars-d wrote: > > On 21.10.18 21:04, Manu wrote: > > On Sun, Oct 21, 2018 at 12:00 PM Timon Gehr via Digitalmars-d > > wrote: > >> > >> On 21.10.18 17:54, Nicholas Wilson wrote: > >>> > As soon as that is done, you've got a data race

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Monday, 22 October 2018 at 00:46:04 UTC, Walter Bright wrote: That's what I was referring to, and Manu's example. It doesn't work, as I pointed out. I'm pretty sure it does, but please repeat it. We will eventually. This started as a "please point out any problems with this" and has

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 5:50 PM Walter Bright via Digitalmars-d wrote: > > On 10/21/2018 4:12 PM, Nicholas Wilson wrote: > > On Sunday, 21 October 2018 at 21:32:14 UTC, Walter Bright wrote: > >> On 10/21/2018 2:08 PM, Walter Bright wrote: > >>> On 10/21/2018 12:20 PM, Nicholas Wilson wrote: >

Re: shared - i need it to be useful

2018-10-21 Thread Timon Gehr via Digitalmars-d
On 22.10.18 02:46, Nicholas Wilson wrote: On Monday, 22 October 2018 at 00:38:33 UTC, Timon Gehr wrote: I just did, Link please? https://forum.dlang.org/post/pqii8k$11u3$1...@digitalmars.com

Re: shared - i need it to be useful

2018-10-21 Thread Timon Gehr via Digitalmars-d
On 22.10.18 02:45, Manu wrote: On Sun, Oct 21, 2018 at 5:35 PM Timon Gehr via Digitalmars-d wrote: On 21.10.18 20:46, Manu wrote: Shared data is only useful if, at some point, it is read/written, presumably by casting it to unshared in @trusted code. As soon as that is done, you've got a

Re: shared - i need it to be useful

2018-10-21 Thread Walter Bright via Digitalmars-d
On 10/21/2018 4:12 PM, Nicholas Wilson wrote: On Sunday, 21 October 2018 at 21:32:14 UTC, Walter Bright wrote: On 10/21/2018 2:08 PM, Walter Bright wrote: On 10/21/2018 12:20 PM, Nicholas Wilson wrote: Yes, but the problem you describe is arises from implicit conversion in the other

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Monday, 22 October 2018 at 00:38:33 UTC, Timon Gehr wrote: I just did, Link please?

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 5:35 PM Timon Gehr via Digitalmars-d wrote: > > On 21.10.18 20:46, Manu wrote: > >> Shared data is only useful if, at some point, it is read/written, > >> presumably by > >> casting it to unshared in @trusted code. As soon as that is done, you've > >> got a > >> data

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Monday, 22 October 2018 at 00:32:35 UTC, Timon Gehr wrote: This only works if untrusted programmers (i.e. programmers who are only allowed to write/modify @safe code) are not allowed to change your class. I.e. it does not work. This is the basis of the current @safe/@trusted/@system model.

Re: shared - i need it to be useful

2018-10-21 Thread Timon Gehr via Digitalmars-d
On 21.10.18 21:04, Manu wrote: On Sun, Oct 21, 2018 at 12:00 PM Timon Gehr via Digitalmars-d wrote: On 21.10.18 17:54, Nicholas Wilson wrote: As soon as that is done, you've got a data race with the other existing unshared aliases. You're in @trusted code, that is the whole point. The

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 3:15 PM Neia Neutuladh via Digitalmars-d wrote: > > On Sun, 21 Oct 2018 12:04:16 -0700, Manu wrote: > > On Sun, Oct 21, 2018 at 12:00 PM Timon Gehr via Digitalmars-d > > wrote: > >> Note that there may well be a good way to get the good properties of MP > >> without

Re: shared - i need it to be useful

2018-10-21 Thread Timon Gehr via Digitalmars-d
On 21.10.18 20:46, Manu wrote: Shared data is only useful if, at some point, it is read/written, presumably by casting it to unshared in @trusted code. As soon as that is done, you've got a data race with the other existing unshared aliases. If such a race is possible, then the @trusted

Re: D T-Shirts

2018-10-21 Thread Mike Parker via Digitalmars-d
On Sunday, 21 October 2018 at 20:04:02 UTC, Fleel wrote: It would be awesome if there were T-Shirts with D-man on them. I would totally buy one, and would help to support the foundation too... We've got a store coming, with t-shirts and other items. D-man shirts will not be there, though.

Re: Can this recursive template type with named type parameters be simplified or improved?

2018-10-21 Thread Hakan Aras via Digitalmars-d-learn
On Sunday, 21 October 2018 at 21:23:35 UTC, aliak wrote: Hi, I'm playing around with a recursive template type that allows for named template parameters. The problem is that it requires a lot of repetition and becomes more error prone as the number of named arguments increase. So 1) Any

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 2:35 PM Walter Bright via Digitalmars-d wrote: > > On 10/21/2018 2:08 PM, Walter Bright wrote: > > On 10/21/2018 12:20 PM, Nicholas Wilson wrote: > >> Yes, but the problem you describe is arises from implicit conversion in the > >> other direction, which is not part of the

[Issue 19325] New: The 'body' keyword is still not deprecated

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19325 Issue ID: 19325 Summary: The 'body' keyword is still not deprecated Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: minor

Re: We need an internal keyword.

2018-10-21 Thread 12345swordy via Digitalmars-d
On Sunday, 21 October 2018 at 21:48:22 UTC, Laurent Tréguier wrote: On Sunday, 21 October 2018 at 17:09:05 UTC, 12345swordy wrote: [...] It's not "my" solution. It's D's solution. I perfectly understand why you'd want this and I would probably make use of a private/internal difference

Re: We need an internal keyword.

2018-10-21 Thread 12345swordy via Digitalmars-d
On Sunday, 21 October 2018 at 19:53:35 UTC, Jonathan M Davis wrote: On Saturday, October 20, 2018 9:17:23 PM MDT 12345swordy via Digitalmars-d wrote: So that classes can share some of their variables but not others in a module. IE. class A { internal int A; //This is shared in the module

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 11:31 AM Manu wrote: > > On Sun., 21 Oct. 2018, 2:55 am Walter Bright via Digitalmars-d, > wrote: > > > > On 10/20/2018 11:24 AM, Manu wrote: > > > This is an unfair dismissal. > > > > It has nothing at all to do with fairness. It is about what the type system > >

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Sunday, 21 October 2018 at 22:12:18 UTC, Neia Neutuladh wrote: On Sun, 21 Oct 2018 12:04:16 -0700, Manu wrote: On Sun, Oct 21, 2018 at 12:00 PM Timon Gehr via Digitalmars-d wrote: Note that there may well be a good way to get the good properties of MP without breaking the type system, but

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Sunday, 21 October 2018 at 21:32:14 UTC, Walter Bright wrote: On 10/21/2018 2:08 PM, Walter Bright wrote: On 10/21/2018 12:20 PM, Nicholas Wilson wrote: Yes, but the problem you describe is arises from implicit conversion in the other direction, which is not part of the proposal. It's

Re: Wed Oct 17 - Avoiding Code Smells by Walter Bright

2018-10-21 Thread Walter Bright via Digitalmars-d-announce
On 10/21/2018 1:29 PM, David Gileadi wrote: There’s a bit more to the story, but it boils down to the fact that since I don’t have permissions to update the feature branch, I’m basically dead in the water. So the work is all done and ready, but I have no path forward to get it in. And it’s a bit

Re: shared - i need it to be useful

2018-10-21 Thread Neia Neutuladh via Digitalmars-d
On Sun, 21 Oct 2018 12:04:16 -0700, Manu wrote: > On Sun, Oct 21, 2018 at 12:00 PM Timon Gehr via Digitalmars-d > wrote: >> Note that there may well be a good way to get the good properties of MP >> without breaking the type system, but MP itself is not good because it >> breaks @safe. > > Show

Manu's `shared` vs the @trusted promise

2018-10-21 Thread ag0aep6g via Digitalmars-d
It took me a while to understand Manu's idea for `shared`, and I suspect that it was/is the same for others. At the same time, Manu seems bewildered about the objections. I'm going to try and summarize the situation. Maybe it can help advance the discussion. (1) How Does Manu's `shared`

Re: We need an internal keyword.

2018-10-21 Thread Laurent Tréguier via Digitalmars-d
On Sunday, 21 October 2018 at 17:48:08 UTC, Neia Neutuladh wrote: On Sun, 21 Oct 2018 08:40:36 +, Laurent Tréguier wrote: This is by design; the D way of dealing with this would be to split the module into a package with multiple modules. This is often a usable way of doing things, but

Re: We need an internal keyword.

2018-10-21 Thread Laurent Tréguier via Digitalmars-d
On Sunday, 21 October 2018 at 17:09:05 UTC, 12345swordy wrote: I know what the current design is!! You have zero tools in regarding to allowing class to share certain variables but not others in the same module! Create a module for every class is taking all or nothing approach, when there is a

error initializing an immutable struct member with a function that takes a lazy param

2018-10-21 Thread aliak via Digitalmars-d-learn
Hi, The code below fails with "Error: delegate `onlineapp.A!int.A.__dgliteral2` cannot be struct members": T f(T)(lazy T value) { return value; } struct A(T) { immutable a = f("hi"); } void main() { A!int i; } Removing the lazy keyword fixes the error. But I'm wondering if I can

Re: D alternative for node.js's socket.IO?

2018-10-21 Thread Neia Neutuladh via Digitalmars-d
On Sun, 21 Oct 2018 20:58:23 +, Fleel wrote: > Can std.socket provide a realtime connection between the client(web > browser) and the server, like for a chatroom or realtime multiplayer > game? Yes, but it will be a bit of work -- you'd need to implement a webserver by hand that can upgrade

[Issue 17647] Fedora/CentOS RPM x86_64 depends on i686 libraries

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17647 leeavi...@gmail.com changed: What|Removed |Added CC||leeavi...@gmail.com --- Comment #1

Re: shared - i need it to be useful

2018-10-21 Thread Walter Bright via Digitalmars-d
On 10/21/2018 2:08 PM, Walter Bright wrote: On 10/21/2018 12:20 PM, Nicholas Wilson wrote: Yes, but the problem you describe is arises from implicit conversion in the other direction, which is not part of the proposal. It's Manu's example. Then I don't know what the proposal is. Pieces of

Can this recursive template type with named type parameters be simplified or improved?

2018-10-21 Thread aliak via Digitalmars-d-learn
Hi, I'm playing around with a recursive template type that allows for named template parameters. The problem is that it requires a lot of repetition and becomes more error prone as the number of named arguments increase. So 1) Any ideas on how to make it less error prone? less repetition? a

Re: shared - i need it to be useful

2018-10-21 Thread Walter Bright via Digitalmars-d
On 10/21/2018 12:20 PM, Nicholas Wilson wrote: Yes, but the problem you describe is arises from implicit conversion in the other direction, which is not part of the proposal. It's Manu's example.

Re: shared - i need it to be useful

2018-10-21 Thread Stanislav Blinov via Digitalmars-d
On Sunday, 21 October 2018 at 19:22:45 UTC, Manu wrote: On Sun, Oct 21, 2018 at 5:50 AM Stanislav Blinov via Digitalmars-d wrote: Because the whole reason to have `shared` is to avoid the extraneous checks that you mentioned above, No, it is to assure that you write correct not-broken

Re: D alternative for node.js's socket.IO?

2018-10-21 Thread Fleel via Digitalmars-d
On Sunday, 21 October 2018 at 20:41:41 UTC, JN wrote: On Sunday, 21 October 2018 at 20:14:46 UTC, Fleel wrote: Does anyone know of a good D alternative for the socket.IO server (https://socket.io)? I would like to transition my server from node.js to D, but I can't find any D equivalents to

Re: D T-Shirts

2018-10-21 Thread welkam via Digitalmars-d
On Sunday, 21 October 2018 at 20:04:02 UTC, Fleel wrote: It would be awesome if there were T-Shirts with D-man on them. I would totally buy one, and would help to support the foundation too... well that cost 100$+

Re: D T-Shirts

2018-10-21 Thread Fleel via Digitalmars-d
On Sunday, 21 October 2018 at 20:35:20 UTC, Manu wrote: On Sun., 21 Oct. 2018, 1:05 pm Fleel via Digitalmars-d, < digitalmars-d@puremagic.com> wrote: It would be awesome if there were T-Shirts with D-man on them. I would totally buy one, and would help to support the foundation too...

Re: D alternative for node.js's socket.IO?

2018-10-21 Thread JN via Digitalmars-d
On Sunday, 21 October 2018 at 20:14:46 UTC, Fleel wrote: Does anyone know of a good D alternative for the socket.IO server (https://socket.io)? I would like to transition my server from node.js to D, but I can't find any D equivalents to socket.IO. (I've seen http://socket.io.dub.pm, but it is

Re: D Binding to GUI libraries

2018-10-21 Thread Patrick Schluter via Digitalmars-d
On Sunday, 21 October 2018 at 18:24:30 UTC, Jacob Carlborg wrote: On 2018-10-21 19:29, Russel Winder wrote: But who apart from Eclipse and JetBrains uses Java for desktop GUI applications? There's probably a ton of business/enterprise applications that are written in Java. But I don't

Re: D T-Shirts

2018-10-21 Thread Manu via Digitalmars-d
On Sun., 21 Oct. 2018, 1:05 pm Fleel via Digitalmars-d, < digitalmars-d@puremagic.com> wrote: > It would be awesome if there were T-Shirts with D-man on them. I > would totally buy one, and would help to support the foundation > too... > Lucky for you, they exist, and you can acquire one by

Re: Wed Oct 17 - Avoiding Code Smells by Walter Bright

2018-10-21 Thread David Gileadi via Digitalmars-d-announce
luckoverthere wrote: > On Friday, 19 October 2018 at 03:53:12 UTC, Walter Bright wrote: >> On 10/15/2018 2:23 PM, Walter Bright wrote: >>> I'm giving a presentation at: >>> >>> http://nwcpp.org/ >>> >>> See you there! >> >> Had a nice crowd there last night. Apparently lots of people >> were

[Issue 19316] GC runtime breaks @safe

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19316 ag0aep6g changed: What|Removed |Added Keywords||safe CC|

D alternative for node.js's socket.IO?

2018-10-21 Thread Fleel via Digitalmars-d
Does anyone know of a good D alternative for the socket.IO server (https://socket.io)? I would like to transition my server from node.js to D, but I can't find any D equivalents to socket.IO. (I've seen http://socket.io.dub.pm, but it is dead). Are there any good D libraries that can do the

D T-Shirts

2018-10-21 Thread Fleel via Digitalmars-d
It would be awesome if there were T-Shirts with D-man on them. I would totally buy one, and would help to support the foundation too...

Re: We need an internal keyword.

2018-10-21 Thread Jonathan M Davis via Digitalmars-d
On Saturday, October 20, 2018 9:17:23 PM MDT 12345swordy via Digitalmars-d wrote: > So that classes can share some of their variables but not others > in a module. > > IE. > > class A > { > internal int A; //This is shared in the module > private int B; // But not this. > } > > No need to

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Sunday, 21 October 2018 at 19:07:37 UTC, Nicholas Wilson wrote: On Sunday, 21 October 2018 at 09:50:09 UTC, Walter Bright wrote: Your proposal makes that impossible because the compiler would allow unshared data to be implicitly typed as shared. Yes, but not the other way around. Whoops

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 5:50 AM Stanislav Blinov via Digitalmars-d wrote: > > On Sunday, 21 October 2018 at 05:47:14 UTC, Manu wrote: > > >> And yet, if we're lucky, we get > >> a consistent instacrash. If we're unlucky, we get memory > >> corruption, or an unsolicited write to another currently

Re: shared - i need it to be useful

2018-10-21 Thread 12345swordy via Digitalmars-d
On Sunday, 21 October 2018 at 18:45:15 UTC, Walter Bright wrote: I'd like to add that if the compiler can prove that a T* points to a unique T, then it can be implicitly cast to shared(T)*. And it does so, like the result of .dup can be so converted. This can be achieved by using the unique

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Sunday, 21 October 2018 at 09:50:09 UTC, Walter Bright wrote: Manu's Proposal --- @safe: int i; int* a = StartNewThread(a); // Compiles! Coder has no idea! ... in the new thread ... void StartOfNewThread(shared(int)* b) { ... we have two threads accessing 'i', one thinks it is

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 12:00 PM Timon Gehr via Digitalmars-d wrote: > > On 21.10.18 17:54, Nicholas Wilson wrote: > > > >> As soon as that is done, you've got a data race with the other > >> existing unshared aliases. > > > > You're in @trusted code, that is the whole point. The onus is on the >

Re: shared - i need it to be useful

2018-10-21 Thread Timon Gehr via Digitalmars-d
On 21.10.18 17:54, Nicholas Wilson wrote: As soon as that is done, you've got a data race with the other existing unshared aliases. You're in @trusted code, that is the whole point. The onus is on the programmer to make that correct, same with regular @safe/@trusted@system code. Not all

Re: Which Docker to use?

2018-10-21 Thread Jon Degenhardt via Digitalmars-d-learn
On Sunday, 21 October 2018 at 18:11:37 UTC, Jacob Carlborg wrote: On 2018-10-18 01:15, Jon Degenhardt wrote: I need to use docker to build static linked Linux executables. My reason is specific, may be different than the OP's. I'm using Travis-CI to build executables. Travis-CI uses Ubuntu

Re: shared - i need it to be useful

2018-10-21 Thread Walter Bright via Digitalmars-d
I'd like to add that if the compiler can prove that a T* points to a unique T, then it can be implicitly cast to shared(T)*. And it does so, like the result of .dup can be so converted.

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun, Oct 21, 2018 at 3:00 AM Walter Bright via Digitalmars-d wrote: > > On 10/20/2018 11:08 AM, Nicholas Wilson wrote: > > You can if no-one else writes to it, which is the whole point of Manu's > > proposal. Perhaps it should be const shared instead of shared but still. > > There is no

Re: Can opApply be made @nogc?

2018-10-21 Thread welkam via Digitalmars-d-learn
DIP 1000 says: Delegates currently defensively allocate closures with the GC. Few actually escape, and with scope only those that actually escape need to have the closures allocated. https://github.com/dlang/DIPs/blob/master/DIPs/DIP1000.md#benefits

Re: shared - i need it to be useful

2018-10-21 Thread Manu via Digitalmars-d
On Sun., 21 Oct. 2018, 2:55 am Walter Bright via Digitalmars-d, wrote: > > On 10/20/2018 11:24 AM, Manu wrote: > > This is an unfair dismissal. > > It has nothing at all to do with fairness. It is about what the type system > guarantees in @safe code. To repeat, the current type system guarantees

Re: D Binding to GUI libraries

2018-10-21 Thread Jacob Carlborg via Digitalmars-d
On 2018-10-21 19:29, Russel Winder wrote: But who apart from Eclipse and JetBrains uses Java for desktop GUI applications? There's probably a ton of business/enterprise applications that are written in Java. But I don't care for that, that's why I'm using D :) I do not have Eclipse to

[Issue 19316] GC runtime breaks @safe

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19316 Stanislav Blinov changed: What|Removed |Added Status|RESOLVED|REOPENED Resolution|INVALID

Re: Which Docker to use?

2018-10-21 Thread Jacob Carlborg via Digitalmars-d-learn
On 2018-10-18 01:15, Jon Degenhardt wrote: I need to use docker to build static linked Linux executables. My reason is specific, may be different than the OP's. I'm using Travis-CI to build executables. Travis-CI uses Ubuntu 14.04, but static linking fails on 14.04. The standard C library from

[Issue 18448] Make std.file.write / std.stdio.write conflicts more tractable for beginners

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18448 Seb changed: What|Removed |Added CC||greeen...@gmail.com --- Comment #2 from Seb --- 1)

[Issue 18448] Make std.file.write / std.stdio.write conflicts more tractable for beginners

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18448 Tiberiu Lepadatu changed: What|Removed |Added CC||tiberiulepadat...@gmail.com --- Comment

Re: We need an internal keyword.

2018-10-21 Thread Neia Neutuladh via Digitalmars-d
On Sun, 21 Oct 2018 08:40:36 +, Laurent Tréguier wrote: > This is by design; the D way of dealing with this would be to split the > module into a package with multiple modules. This is often a usable way of doing things, but sometimes not so much. If you're writing a script for use with dub

[Issue 18467] std.format: Hangul Jamo syllables, while correctly segmented as single graphemes by graphemeStride, are designated as wide characters, and thus should occupy 2 spaces per grapheme

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18467 Tiberiu Lepadatu changed: What|Removed |Added CC||tiberiulepadat...@gmail.com --- Comment

[Issue 18464] fullyQualifiedName!ifloat and fullyQualifiedName!cfloat fail

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18464 Tiberiu Lepadatu changed: What|Removed |Added CC||tiberiulepadat...@gmail.com --- Comment

Re: D Binding to GUI libraries [was Interesting Observation from JAXLondon]

2018-10-21 Thread Russel Winder via Digitalmars-d
On Sun, 2018-10-21 at 12:54 +0200, Jacob Carlborg via Digitalmars-d wrote: > […] > As has been stated elsewhere, it's working on Windows and macOS but > looks very alien on macOS. When I was in school I wrote a program > using > C# (Mono) and GTK on macOS. GTK seemed to be the best alternative

Re: D Binding to GUI libraries

2018-10-21 Thread Russel Winder via Digitalmars-d
On Sun, 2018-10-21 at 12:49 +0200, Jacob Carlborg via Digitalmars-d wrote: > On 2018-10-21 09:33, Russel Winder wrote: > > > The SWT framework is being replaced with JavaFX, so should D forget > > DWT > > and do something similar? > > Where do you get that idea? SWT (and therefore DWT) is using

Re: D Binding to GUI libraries

2018-10-21 Thread Russel Winder via Digitalmars-d
On Sun, 2018-10-21 at 08:42 +, Paolo Invernizzi via Digitalmars-d wrote: > […] > > Linux is not only the desktop, and Qt simply dominates in > industrial, medical and automation sector, that's where the money > is. > > Qt is pushing strongly on the embedded marked, bare metal or > linux

Re: D Binding to GUI libraries

2018-10-21 Thread Russel Winder via Digitalmars-d
On Sun, 2018-10-21 at 04:15 -0400, Nick Sabalausky (Abscissa) via Digitalmars-d wrote: > […] > > That's pure nonsense: It's Linux - unless one option actually goes > away > (KDE is still actively used and developed), then there's no such > thing > as one "winning" over the other. Hardly

Re: We need an internal keyword.

2018-10-21 Thread 12345swordy via Digitalmars-d
On Sunday, 21 October 2018 at 08:40:36 UTC, Laurent Tréguier wrote: On Sunday, 21 October 2018 at 03:17:23 UTC, 12345swordy wrote: So that classes can share some of their variables but not others in a module. IE. class A { internal int A; //This is shared in the module private int B; // But

Re: shared - i need it to be useful

2018-10-21 Thread Neia Neutuladh via Digitalmars-d
On Sat, 20 Oct 2018 22:47:14 -0700, Manu wrote: > Looking at the meat of the program; you open a file, and distribute it > to do accesses (I presume?) > Naturally, this is a really weird thing to do, because even if the API > is threadsafe such that it doesn't crash and reads/writes are >

Re: shared - i need it to be useful

2018-10-21 Thread Nicholas Wilson via Digitalmars-d
On Sunday, 21 October 2018 at 09:58:18 UTC, Walter Bright wrote: On 10/20/2018 11:08 AM, Nicholas Wilson wrote: You can if no-one else writes to it, which is the whole point of Manu's proposal. Perhaps it should be const shared instead of shared but still. There is no purpose whatsoever to

Re: We need an internal keyword.

2018-10-21 Thread luckoverthere via Digitalmars-d
On Sunday, 21 October 2018 at 03:17:23 UTC, 12345swordy wrote: So that classes can share some of their variables but not others in a module. IE. class A { internal int A; //This is shared in the module private int B; // But not this. } No need to reintroduce the "Friend" feature from cpp.

Re: D Binding to GUI libraries [was Interesting Observation from JAXLondon]

2018-10-21 Thread welkam via Digitalmars-d
On Saturday, 20 October 2018 at 16:37:07 UTC, Atila Neves wrote: I've also realised that there are parts of C++ that are probably unstranslatable no matter what I do. This can be solved with good gui. It need to look like meld on linux where original cpp and translated d files are side by

Re: We need an internal keyword.

2018-10-21 Thread Basile B. via Digitalmars-d
On Sunday, 21 October 2018 at 03:17:23 UTC, 12345swordy wrote: So that classes can share some of their variables but not others in a module. IE. class A { internal int A; //This is shared in the module private int B; // But not this. } No need to reintroduce the "Friend" feature from cpp.

Re: shared - i need it to be useful

2018-10-21 Thread Simen Kjærås via Digitalmars-d
On Sunday, 21 October 2018 at 13:24:49 UTC, Stanislav Blinov wrote: On Sunday, 21 October 2018 at 11:25:16 UTC, aliak wrote: When I say ok, I mean assuming the implementer actually wrote correct code. This applies to any shared method today as well. This ("ok") can only be achieved if the

Re: Truly @nogc Exceptions?

2018-10-21 Thread welkam via Digitalmars-d
On Thursday, 20 September 2018 at 10:48:35 UTC, Atila Neves wrote: What's the fix? Have the compiler insert a call to the exception's destructor at the end of the `catch(scope Exception)` block. If I understood you correctly then we have same idea. If exception is not handled or re thrown

Re: shared - i need it to be useful

2018-10-21 Thread Simen Kjærås via Digitalmars-d
On Sunday, 21 October 2018 at 12:45:43 UTC, Stanislav Blinov wrote: On Sunday, 21 October 2018 at 05:47:14 UTC, Manu wrote: On Sat, Oct 20, 2018 at 10:10 AM Stanislav Blinov via Digitalmars-d wrote: Synchronized with what? You still have `a`, which isn't `shared` and doesn't require any

[Issue 19316] GC runtime breaks @safe

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19316 Simen Kjaeraas changed: What|Removed |Added Status|NEW |RESOLVED CC|

[Issue 18571] Missing functions in std.complex

2018-10-21 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=18571 Tiberiu Lepadatu changed: What|Removed |Added CC||tiberiulepadat...@gmail.com --- Comment

  1   2   >