D vs Java which is more powerful

2019-11-15 Thread GreatSam4sure via Digitalmars-d-learn
According to this [1] a person that java is much more powerful than D. I am really surprised at this claim. Is this true? Because I believe D much more powerful than Java. I will really appreciate detail analysis 1.https://forum.dlang.org/thread/lnrhskowvyighdnzb...@forum.dlang.org

Re: Translating Java into D

2019-11-15 Thread GreatSam4sure via Digitalmars-d-learn
On Friday, 15 November 2019 at 03:29:16 UTC, Heromyth wrote: On Thursday, 14 November 2019 at 19:50:22 UTC, NonNull wrote: Greetings, Java seems to be almost a subset of D in various ways. No, it's not exactly right. Java is more powerful than D as for a language. Many things that Java can do

Re: Translating Java into D

2019-11-15 Thread DanielG via Digitalmars-d-learn
Potentially relevant old thread: https://forum.dlang.org/thread/ssdcoqhylmskfytfi...@forum.dlang.org

Re: Translating Java into D

2019-11-15 Thread Heromyth via Digitalmars-d-learn
On Friday, 15 November 2019 at 13:15:29 UTC, Andre Pany wrote: On Friday, 15 November 2019 at 03:29:16 UTC, Heromyth wrote: On Thursday, 14 November 2019 at 19:50:22 UTC, NonNull wrote: Greetings, Java seems to be almost a subset of D in various ways. No, it's not exactly right. Java is more

Good examples for dmd.frontend?

2019-11-15 Thread Doc Andrew via Digitalmars-d-learn
Hello, I'm doing some experiments trying to use the DMD front-end as a library to generate code (Why3ML) that can be used in a formal verification tool. However, documentation is a little sparse. I've looked through the examples in dmd/src/examples, and they were a fine starting point but

Re: std.json / nested key/value access?

2019-11-15 Thread Robert M. Münch via Digitalmars-d-learn
On 2019-11-15 17:23:38 +, Steven Schveighoffer said: On 11/15/19 12:05 PM, Robert M. Münch wrote: JSONValue j = parseJSON(json_string).object;  writeln(j); // works  writeln(j["a"]); // works  writeln(j["a"].object["b"]); // bombs

Re: std.json / nested key/value access?

2019-11-15 Thread Steven Schveighoffer via Digitalmars-d-learn
On 11/15/19 12:05 PM, Robert M. Münch wrote: JSONValue j = parseJSON(json_string).object;  writeln(j); // works  writeln(j["a"]); // works  writeln(j["a"].object["b"]); // bombs auto json_string = `{"a": {"b": 1}}`; Results with your

std.json / nested key/value access?

2019-11-15 Thread Robert M. Münch via Digitalmars-d-learn
I have: JSONValue j = parseJSON(json_string).object; writeln(j);// works writeln(j["a"]); // works writeln(j["a"].object["b"]); // bombs Runtime error: std.json.JSONException@std/json.d(276):

Blog Post #88: Nodes-n-noodles, Part VII - It's Alive! (1)

2019-11-15 Thread Ron Tarrant via Digitalmars-d-learn
Okay, time to prepare for moving that node... and it all starts with this: https://gtkdcoding.com/2019/11/15/0088-nodes-vii-its-alive.html

Re: Translating Java into D

2019-11-15 Thread Andre Pany via Digitalmars-d-learn
On Friday, 15 November 2019 at 03:29:16 UTC, Heromyth wrote: On Thursday, 14 November 2019 at 19:50:22 UTC, NonNull wrote: Greetings, Java seems to be almost a subset of D in various ways. No, it's not exactly right. Java is more powerful than D as for a language. Many things that Java can do

Re: Why same pointer type for GC and manual memory?

2019-11-15 Thread Basile B. via Digitalmars-d-learn
On Friday, 15 November 2019 at 10:55:55 UTC, IGotD- wrote: On Friday, 15 November 2019 at 08:58:43 UTC, user1234 wrote: On Wednesday, 13 November 2019 at 11:07:12 UTC, IGotD- wrote: I'm trying to find the rationale why GC pointers (should be names managed pointers) are using the exact same

Re: Why same pointer type for GC and manual memory?

2019-11-15 Thread IGotD- via Digitalmars-d-learn
On Friday, 15 November 2019 at 08:58:43 UTC, user1234 wrote: On Wednesday, 13 November 2019 at 11:07:12 UTC, IGotD- wrote: I'm trying to find the rationale why GC pointers (should be names managed pointers) are using the exact same type as any other pointer. Doesn't this limit the ability to

Re: Why same pointer type for GC and manual memory?

2019-11-15 Thread user1234 via Digitalmars-d-learn
On Wednesday, 13 November 2019 at 11:07:12 UTC, IGotD- wrote: I'm trying to find the rationale why GC pointers (should be names managed pointers) are using the exact same type as any other pointer. Doesn't this limit the ability to change the default GC type? Doesn't this confusion make GC