Re: What could this OptLink Error mean?
On Thursday, 4 January 2018 at 21:33:58 UTC, Dukc wrote: On Saturday, 30 December 2017 at 00:49:48 UTC, user1234 wrote: The deps have to be rebuild too. After downloading dmd 78, it started to work. It's likely you were right about the issue, DUB rebuilt everything after detecting new compiler version. Sorry for my late reply. From a compiler version to another, the ABI can change (examples are: mangling, new overloads as seen with format a couple of months ago). You compiled the program with a slightly different ABI than the one used to compile the deps as static libraries. I don't know why DUB didn't detect this but as said user1234 always try " --force" on DUB or rebuild deps manually to eliminate this possible cause of problems.
Re: How do i activate the latest nightly without knowing the date ?
On Thursday, 4 January 2018 at 22:07:39 UTC, user789 wrote: On Thursday, 4 January 2018 at 20:37:16 UTC, user789 wrote: On Thursday, 4 January 2018 at 20:28:47 UTC, user789 wrote: After using the script to setup DMD nightly i read in the output that i have to run "source ~/dlang/dmd-master-2018-01-04/activate" to have DMD DUB etc working. Is there another activation command, working without the date, suitable for a cron job ? "source ~/dlang/dmd-nightly/activate" doesn't work but would be better when you just want to use the nightly F1nally i found that just --- wget https://nightlies.dlang.org/dmd-nightly/dmd.master.linux.tar.xz tar xf ./dmd.master.linux.tar.xz03:12 export PATH=$PATH:`pwd`/dmd2/linux/bin64 --- works fine. maybe you should add something to the script to install and activate latest nightly in one step. Oh some unrelated log material found its little guy way in the copy/paste --- https://nightlies.dlang.org/dmd-nightly/dmd.master.linux.tar.xz tar xf ./dmd.master.linux.tar.xz export PATH=$PATH:`pwd`/dmd2/linux/bin64 ---
Re: I want to transmit the class name and the member name in the method
On Friday, 5 January 2018 at 08:34:00 UTC, user789 wrote: On Friday, 5 January 2018 at 07:40:14 UTC, Brian wrote: I think code style like: ~~ struct User { int id; string name; string email; } class ORM { } auto db = new ORM; auto users = db.select(User).where(email.like("*@hotmail.com")).limit(10); foreach(user; users) { writeln("user: " + user.name + "\n"); } ~~ this rust code is support it: https://github.com/diesel-rs/diesel/blob/master/examples/postgres/all_about_updates/src/lib.rs Well in D this would be more something like that: auto users = db.select!(User).map!(a => a.email.like("*@hotmail.com")).take(10); Oh, I realize that your Q was more: "which package should i use to write this way ?"
Re: I want to transmit the class name and the member name in the method
On Friday, 5 January 2018 at 07:40:14 UTC, Brian wrote: I think code style like: ~~ struct User { int id; string name; string email; } class ORM { } auto db = new ORM; auto users = db.select(User).where(email.like("*@hotmail.com")).limit(10); foreach(user; users) { writeln("user: " + user.name + "\n"); } ~~ this rust code is support it: https://github.com/diesel-rs/diesel/blob/master/examples/postgres/all_about_updates/src/lib.rs Well in D this would be more something like that: auto users = db.select!(User).map!(a => a.email.like("*@hotmail.com")).take(10);
Re: How do i activate the latest nightly without knowing the date ?
On Thursday, 4 January 2018 at 20:37:16 UTC, user789 wrote: On Thursday, 4 January 2018 at 20:28:47 UTC, user789 wrote: After using the script to setup DMD nightly i read in the output that i have to run "source ~/dlang/dmd-master-2018-01-04/activate" to have DMD DUB etc working. Is there another activation command, working without the date, suitable for a cron job ? "source ~/dlang/dmd-nightly/activate" doesn't work but would be better when you just want to use the nightly F1nally i found that just --- wget https://nightlies.dlang.org/dmd-nightly/dmd.master.linux.tar.xz tar xf ./dmd.master.linux.tar.xz03:12 export PATH=$PATH:`pwd`/dmd2/linux/bin64 --- works fine. maybe you should add something to the script to install and activate latest nightly in one step.
Re: How do i activate the latest nightly without knowing the date ?
On Thursday, 4 January 2018 at 20:28:47 UTC, user789 wrote: After using the script to setup DMD nightly i read in the output that i have to run "source ~/dlang/dmd-master-2018-01-04/activate" to have DMD DUB etc working. Is there another activation command, working without the date, suitable for a cron job ? "source ~/dlang/dmd-nightly/activate" doesn't work but would be better when you just want to use the nightly
How do i activate the latest nightly without knowing the date ?
After using the script to setup DMD nightly i read in the output that i have to run "source ~/dlang/dmd-master-2018-01-04/activate" to have DMD DUB etc working. Is there another activation command, working without the date, suitable for a cron job ?