Issues with Vibe.d Dynamic HTML with JSON

2017-11-01 Thread SamwiseFilmore via Digitalmars-d-learn
I've got a serialized JSON structure that looks something like this: { "title": "Webpage title", "major_categories": [ { "title": "Major Category title", "categories": [ { "title": "Minor Category title",

Re: Any book recommendation for writing a compiler?

2017-11-01 Thread Michael V. Franklin via Digitalmars-d-learn
On Wednesday, 1 November 2017 at 20:53:44 UTC, Dr. Assembly wrote: Hey guys, if I were to get into dmd's source code to play a little bit (just for fun, no commercial use at all), which books/resources do you recommend to start out? I found this to be quite helpful:

Re: Any book recommendation for writing a compiler?

2017-11-01 Thread rikki cattermole via Digitalmars-d-learn
On 01/11/2017 11:13 PM, Jonathan M Davis wrote: On Wednesday, November 01, 2017 20:53:44 Dr. Assembly via Digitalmars-d- learn wrote: Hey guys, if I were to get into dmd's source code to play a little bit (just for fun, no commercial use at all), which books/resources do you recommend to start

Re: Any book recommendation for writing a compiler?

2017-11-01 Thread Alexandre via Digitalmars-d-learn
On Wednesday, 1 November 2017 at 20:56:22 UTC, Dr. Assembly wrote: On Wednesday, 1 November 2017 at 20:53:44 UTC, Dr. Assembly wrote: Hey guys, if I were to get into dmd's source code to play a little bit (just for fun, no commercial use at all), which books/resources do you recommend to start

Re: Any book recommendation for writing a compiler?

2017-11-01 Thread Jonathan M Davis via Digitalmars-d-learn
On Wednesday, November 01, 2017 20:53:44 Dr. Assembly via Digitalmars-d- learn wrote: > Hey guys, if I were to get into dmd's source code to play a > little bit (just for fun, no commercial use at all), which > books/resources do you recommend to start out? Well, if you're looking to actually buy

Re: Any book recommendation for writing a compiler?

2017-11-01 Thread Ali Çehreli via Digitalmars-d-learn
On 11/01/2017 01:53 PM, Dr. Assembly wrote: Hey guys, if I were to get into dmd's source code to play a little bit (just for fun, no commercial use at all), which books/resources do you recommend to start out? I haven't read it but one compiler bible is "the dragon book":

Re: std.format and floating point issue

2017-11-01 Thread jmh530 via Digitalmars-d-learn
On Wednesday, 1 November 2017 at 19:06:42 UTC, Ali Çehreli wrote: On 10/29/2017 03:13 AM, codephantom wrote: Can anyone help me to understand why the format in the second writeln below, does not format the output with commas? void main() {     import

Re: Any book recommendation for writing a compiler?

2017-11-01 Thread Dr. Assembly via Digitalmars-d-learn
On Wednesday, 1 November 2017 at 20:53:44 UTC, Dr. Assembly wrote: Hey guys, if I were to get into dmd's source code to play a little bit (just for fun, no commercial use at all), which books/resources do you recommend to start out? I'd like something on back-end too, for example, code

Any book recommendation for writing a compiler?

2017-11-01 Thread Dr. Assembly via Digitalmars-d-learn
Hey guys, if I were to get into dmd's source code to play a little bit (just for fun, no commercial use at all), which books/resources do you recommend to start out?

Re: std.format and floating point issue

2017-11-01 Thread Ali Çehreli via Digitalmars-d-learn
On 10/29/2017 03:13 AM, codephantom wrote: Can anyone help me to understand why the format in the second writeln below, does not format the output with commas? void main() {     import std.stdio, std.format;     writeln( format("%,.1f", 84543432.951172) );

Re: Why 2 ^^ 1 ^^ 2 = 2?

2017-11-01 Thread Igor Shirkalin via Digitalmars-d-learn
On Sunday, 22 October 2017 at 14:20:20 UTC, Ilya Yaroshenko wrote: .. i thought it should be (2 ^^ 1) ^^ 2 = 4 Imagine 2^^10^^10^^7. It's a big number, isn't? (up-up-and up) Where would you start from?

Re: Why 2 ^^ 1 ^^ 2 = 2?

2017-11-01 Thread Q. Schroll via Digitalmars-d-learn
On Saturday, 28 October 2017 at 00:14:15 UTC, Ivan Kazmenko wrote: For an argument, the TEX command "^" accepts either a single character or a bracket-enclosed string of arbitrary length. So $3^3^3$ indeed transforms to ${3^3}^3$, but not for some deeper reason this time. On my TeX

Re: Working with images

2017-11-01 Thread Daniel Kozak via Digitalmars-d-learn
You can still use CLib, if you dont find anything else. On Wed, Nov 1, 2017 at 1:22 PM, Antonio Corbi via Digitalmars-d-learn < digitalmars-d-learn@puremagic.com> wrote: > On Wednesday, 1 November 2017 at 12:02:08 UTC, Alexandre wrote: > >> I have a project written in C++, that I'm thinking to

Re: Working with images

2017-11-01 Thread Antonio Corbi via Digitalmars-d-learn
On Wednesday, 1 November 2017 at 12:02:08 UTC, Alexandre wrote: I have a project written in C++, that I'm thinking to migrating to D, but, what is preventing me from migrating to D, is the part of the system that works with images, where the system generates the image of a payment receipt,

Working with images

2017-11-01 Thread Alexandre via Digitalmars-d-learn
I have a project written in C++, that I'm thinking to migrating to D, but, what is preventing me from migrating to D, is the part of the system that works with images, where the system generates the image of a payment receipt, currently in the system written in C ++, there is an array with

Re: "version" private word

2017-11-01 Thread Basile B. via Digitalmars-d-learn
On Tuesday, 31 October 2017 at 13:46:40 UTC, Igor Shirkalin wrote: Hello! We need some conditional compilation using 'version'. Say we have some code to be compiled for X86 and X86_64. How can we do that using predefined (or other) versions? Examples: version(X86 || X86_64) // failed

Re: Line numbers in backtraces (2017)

2017-11-01 Thread Moritz Maxeiner via Digitalmars-d-learn
On Wednesday, 1 November 2017 at 06:44:44 UTC, Tobias Pankrath wrote: On Tuesday, 31 October 2017 at 11:21:30 UTC, Moritz Maxeiner wrote: On Tuesday, 31 October 2017 at 11:04:57 UTC, Tobias Pankrath wrote: [...] ??:? pure @safe void std.exception.bailOut!(Exception).bailOut(immutable(char)[],

Re: Line numbers in backtraces (2017)

2017-11-01 Thread Tobias Pankrath via Digitalmars-d-learn
On Tuesday, 31 October 2017 at 11:21:30 UTC, Moritz Maxeiner wrote: On Tuesday, 31 October 2017 at 11:04:57 UTC, Tobias Pankrath wrote: [...] ??:? pure @safe void std.exception.bailOut!(Exception).bailOut(immutable(char)[], ulong, const(char[])) [0xab5c9566] ??:? pure @safe bool