DLL on LDC

2019-11-11 Thread Márcio Martins via Digitalmars-d-learn
Hi, I am trying to create a simple DLL and a simple app that loads it on Linux with end goal of having it work on MacOS. Everything seems to work fine with DMD, but when I use LDC2 to build the loader, I don't get the `shared static this()` and `~this` called when I `dlopen()` and

Error: need this for method of type

2019-10-23 Thread Márcio Martins via Digitalmars-d-learn
Hi! Consider this simplified program: ``` import std.stdio; struct X { void method(int x) { writeln("method called"); } } void main() { X x; foreach (member; __traits(allMembers, X)) { alias method = __traits(getMember, x, member); method(1); } }

Re: Compiler benchmarker for D, C, C++, Go, Rust with more to come

2019-10-21 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 21 October 2019 at 12:25:20 UTC, Per Nordlöw wrote: On Monday, 21 October 2019 at 12:12:56 UTC, Per Nordlöw wrote: Is it prepackaged on Ubuntu? Do you mean the package golang-go? Most likely it is that one, but also, very likely to be outdated. You can download the latest

Re: Compiler benchmarker for D, C, C++, Go, Rust with more to come

2019-10-21 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 21 October 2019 at 11:27:05 UTC, Per Nordlöw wrote: On Monday, 21 October 2019 at 11:07:14 UTC, Márcio Martins wrote: Any reason why you left Go's `gc` out? What do you mean by `gc`? Is `gc` a checker or checker flag to some compiler? Can't find any relevant hits for hit the web.

Re: Compiler benchmarker for D, C, C++, Go, Rust with more to come

2019-10-21 Thread Márcio Martins via Digitalmars-d-announce
On Thursday, 17 October 2019 at 17:05:14 UTC, Per Nordlöw wrote: On Saturday, 16 March 2019 at 21:23:18 UTC, Per Nordlöw wrote: https://github.com/nordlow/compiler-benchmark Just added support for V (vlang.io), Zig and Julia. Very interesting - thanks for this! Any reason why you left Go's

Re: Release D 2.085.1

2019-04-08 Thread Márcio Martins via Digitalmars-d-announce
On Saturday, 6 April 2019 at 09:12:40 UTC, Martin Nowak wrote: Glad to announce D 2.085.1, ♥ to the 14 contributors. http://dlang.org/download.html This point release fixes a few issues over 2.085.0, see the changelog for more details. http://dlang.org/changelog/2.085.1.html -Martin

Re: LDC2 with -fxray-instrument

2019-01-21 Thread Márcio Martins via Digitalmars-d-learn
On Thursday, 17 January 2019 at 00:11:10 UTC, Johan Engelen wrote: On Wednesday, 16 January 2019 at 23:29:45 UTC, Johan Engelen wrote: On Wednesday, 16 January 2019 at 22:10:14 UTC, Johan Engelen wrote: On Wednesday, 16 January 2019 at 17:36:31 UTC, Márcio Martins wrote: On Tuesday, 15 January

Re: LDC2 with -fxray-instrument

2019-01-16 Thread Márcio Martins via Digitalmars-d-learn
On Tuesday, 15 January 2019 at 22:51:15 UTC, Johan Engelen wrote: What platform are you on? Linux x64

LDC2 with -fxray-instrument

2019-01-15 Thread Márcio Martins via Digitalmars-d-learn
Anyone has any idea how to build with LDC and -fxray-instrument? I am running LDC 1.13 on Linux (x64) The XRay section is in the binary, and the compiler-rt is linked in, but when I run the binary with XRAY_OPTIONS="patch_premain=true verbosity=1" in the environment, and I get nothing. No

std.digest

2018-10-17 Thread Márcio Martins via Digitalmars-d
Hi! To my surprise, std.digest.MurmurHash3 doesn't work in CTFE. Would it be hard to have it explicit in the documentation if a particular Phobos symbol works in CTFE? Maybe it could be manual, and vote-based, to avoid building infrastructure around it. Also, MurmurHash3 only outputs 32-bit

Re: Is this a bug?

2018-10-16 Thread Márcio Martins via Digitalmars-d-learn
On Tuesday, 16 October 2018 at 13:09:34 UTC, Steven Schveighoffer wrote: On 10/15/18 4:36 PM, Márcio Martins wrote: [...] Hm... didn't realize that. It seems to me like an odd limitation, but I can see how it's ambiguous. The solution is to double-template: template incx(Args...) {

Re: Is this a bug?

2018-10-16 Thread Márcio Martins via Digitalmars-d-learn
On Tuesday, 16 October 2018 at 02:13:21 UTC, Ali Çehreli wrote: On 10/15/2018 01:36 PM, Márcio Martins wrote: > Considering that the declaration is legal, and that the template > parameter deduction works when Args.length == 0, but stops working when > Args.length > 0. For deduction to work,

Re: Is this a bug?

2018-10-15 Thread Márcio Martins via Digitalmars-d-learn
On Monday, 15 October 2018 at 16:46:34 UTC, Steven Schveighoffer wrote: On 10/15/18 12:40 PM, Márcio Martins wrote: import std.stdio; void incx(T, Args...)(ref T t) {     ++t.x; } static struct Test(T) {     T x; } void main() {     Test!uint t;     t.incx();   // works    

Is this a bug?

2018-10-15 Thread Márcio Martins via Digitalmars-d-learn
import std.stdio; void incx(T, Args...)(ref T t) { ++t.x; } static struct Test(T) { T x; } void main() { Test!uint t; t.incx(); // works t.incx!(); // works incx(t);// works t.incx!(1, 2, 3); // what? incx(t, 1, 2, 3); // what?

Re: std.data.json formal review

2018-10-09 Thread Márcio Martins via Digitalmars-d
On Tuesday, 28 July 2015 at 14:07:19 UTC, Atila Neves wrote: Start of the two week process, folks. Code: https://github.com/s-ludwig/std_data_json Docs: http://s-ludwig.github.io/std_data_json/ Atila Sorry for the late ping, but it's been 3 years - what has happened to this? Has it been

Re: Quick C bindings

2018-09-29 Thread Márcio Martins via Digitalmars-d
On Friday, 28 September 2018 at 16:44:31 UTC, Adam D. Ruppe wrote: What, exactly do you want to do with them? Using them is well-supported, but creating them is more iffy. Create/load/unload. I want to create a hot-reload workflow of smaller components of my projects, since compilation times

Re: Quick C bindings

2018-09-29 Thread Márcio Martins via Digitalmars-d
On Friday, 28 September 2018 at 21:42:25 UTC, bachmeier wrote: If they're pure C, you can use dpp: https://github.com/atilaneves/dpp Even if you want to work with the bindings, not just call the C functions, you can use the intermediate files that dpp creates. It works with pretty much

Quick C bindings

2018-09-28 Thread Márcio Martins via Digitalmars-d
Hi y'all! If you'd be so kind and help me out here with a few questions/opinions: I would like to generate decent D bindings for https://github.com/libuv/libuv with as little pain as possible. What are you guys using these days to generate bindings? I remember trying Dstep a few years

Re: Weird compilation error only as static library

2018-09-28 Thread Márcio Martins via Digitalmars-d-learn
On Friday, 28 September 2018 at 15:24:03 UTC, Andrea Fontana wrote: On Wednesday, 26 September 2018 at 19:08:45 UTC, Márcio Martins wrote: Hi! I am getting this error when compiling my code as a static library. It works fine as an executable. I have no idea what's happening. Has someone seen

Weird compilation error only as static library

2018-09-26 Thread Márcio Martins via Digitalmars-d-learn
Hi! I am getting this error when compiling my code as a static library. It works fine as an executable. I have no idea what's happening. Has someone seen something like this before? What could be different? This is the error: /usr/include/dmd/druntime/import/core/stdc/stdint.d(159,26):

Re: Semantic change from 2.078.3 to 2.079.0

2018-05-23 Thread Márcio Martins via Digitalmars-d
On Wednesday, 23 May 2018 at 09:43:28 UTC, Jonathan M Davis wrote: [...] Got it! Thanks!

Re: Semantic change from 2.078.3 to 2.079.0

2018-05-23 Thread Márcio Martins via Digitalmars-d
On Wednesday, 23 May 2018 at 09:26:48 UTC, ag0aep6g wrote: On 05/23/2018 11:21 AM, Márcio Martins wrote: Hi, recently we tried to upgrade DMD from 2.078.3 to 2.080 and found an unexpected semantic change. Consider this program: import std.traits; enum X { Y = "z" }; alias T = typeof(X.Y);

Semantic change from 2.078.3 to 2.079.0

2018-05-23 Thread Márcio Martins via Digitalmars-d
Hi, recently we tried to upgrade DMD from 2.078.3 to 2.080 and found an unexpected semantic change. Consider this program: import std.traits; enum X { Y = "z" }; alias T = typeof(X.Y); pragma(msg, is(T == enum)); pragma(msg, isSomeString!T); void main() {}` Output in DMD <= 2.078.3: true

Re: vibe.d 0.7.33 maintenance release

2018-05-18 Thread Márcio Martins via Digitalmars-d-announce
On Wednesday, 16 May 2018 at 08:48:15 UTC, Sönke Ludwig wrote: Being the final public release on the 0.7.x branch, this version on DMD 2.068.2 up to DMD 2.080.0 and LDC 1.9.0. It includes some major fixes and improvements backported from the 0.8.x branch. Since this marks the last 0.7.x

Issue with traits usability

2018-03-21 Thread Márcio Martins via Digitalmars-d-learn
Hi! How do I get past this? static struct X { int x; private enum T = 1; private alias M = string; } foreach (Member; __traits(allMembers, X)) { pragma(msg, __traits(getProtection, __traits(getMember, X, Member))); } Output: public private c.d(1084): Error:

Re: DMD Callstacks

2017-10-23 Thread Márcio Martins via Digitalmars-d-learn
On Monday, 23 October 2017 at 12:54:33 UTC, Nicholas Wilson wrote: On Monday, 23 October 2017 at 12:41:09 UTC, Márcio Martins wrote: What is everyone doing to get proper file name and line number info for callstacks with DMD? addr2line just gives me ??:0 What OS, etc? Linux 64-bit (Ubuntu

DMD Callstacks

2017-10-23 Thread Márcio Martins via Digitalmars-d-learn
What is everyone doing to get proper file name and line number info for callstacks with DMD? addr2line just gives me ??:0

SIMD GC

2017-09-02 Thread Márcio Martins via Digitalmars-d
I was curious if anyone has tried implementing the GC mark phase with SIMD instrs? If so, what were the results, and why didn't it get accepted? At first thought, it seems like a simple project that could improve performance of big-memory programs by a significant margin, right?

Re: My simple implementation of PHP strip_tags()

2017-06-30 Thread Márcio Martins via Digitalmars-d
On Wednesday, 28 June 2017 at 18:08:12 UTC, aberba wrote: I wanted strip_tags() for sanitization in vibe.d and I set out for algorithms on how to do it and came across this JavaScript library at https://github.com/ericnorris/striptags/blob/master/src/striptags.js which is quite popular judging

glibc resolve.h for D

2017-02-08 Thread Márcio Martins via Digitalmars-d
Anyone has a binding readily available that I can use? code.dlang.org is down, so I can't check there - I am in a hurry! :)

Re: Release D 2.072.1

2016-12-01 Thread Márcio Martins via Digitalmars-d-announce
On Thursday, 1 December 2016 at 12:36:35 UTC, Gary Willoughby wrote: On Wednesday, 30 November 2016 at 22:49:12 UTC, Martin Nowak wrote: Glad to announce D 2.072.1. http://dlang.org/download.html This point release fixes a few issues over 2.072.0, see the changelog for more details.

Re: Beta D 2.072.1-b1

2016-11-30 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 28 November 2016 at 07:46:24 UTC, deadalnix wrote: On Tuesday, 22 November 2016 at 12:54:12 UTC, Martin Nowak wrote: First beta for the 2.072.1 point release. This version resolves a number of regressions and bugs in the 2.072.0 release. http://dlang.org/download.html#dmd_beta

Re: hashOf()

2016-11-03 Thread Márcio Martins via Digitalmars-d
On Thursday, 3 November 2016 at 13:11:41 UTC, Steven Schveighoffer wrote: On 11/2/16 12:14 PM, Márcio Martins wrote: [...] You are not the only one: https://forum.dlang.org/post/nv85ou$gi5$1...@digitalmars.com Note, I wholly disagree with the idea that hashOf(arr) hashes the pointer and

Re: __traits(getMember)

2016-11-03 Thread Márcio Martins via Digitalmars-d
On Wednesday, 2 November 2016 at 19:49:24 UTC, Jacob Carlborg wrote: On 2016-11-02 17:30, Márcio Martins wrote: Can we get a getMember and a getOverloads that won't check for visibility or anything else? __traits appears really powerful, but every-time I try to use it for anything other than

__traits(getMember)

2016-11-02 Thread Márcio Martins via Digitalmars-d
Can we get a getMember and a getOverloads that won't check for visibility or anything else? __traits appears really powerful, but every-time I try to use it for anything other than a toy example or very simple serialization, it seems like everything falls apart due to some detail... and I

hashOf()

2016-11-02 Thread Márcio Martins via Digitalmars-d
There are 2 hashOf() definitions, one in object.d and one in core.internal.hash.d If you include core.internal.hash, you cannot call hashOf() anymore, because it conflicts with the implicit import in object.d, this is annoying in itself... The bigger issue though, is that they have different

Overloads

2016-06-26 Thread Márcio Martins via Digitalmars-d-learn
Consider this snippet: struct X { int foo(Args...)(Args args) if (Args.length > 1) { return Args.length; } int foo() { return 0; } int foo(int y) { return 1; } alias Name = string; int field_; } void listMembers(T)(ref T x) { foreach (Member; __traits(derivedMembers, T)) {

Work in Amsterdam

2016-06-13 Thread Márcio Martins via Digitalmars-d-announce
Forgive me if this is not the best place for this sort of posts, but we are looking for experienced developers willing to learn D to join our development team in Amsterdam. We are a fast-growing travel e-commerce startup focused on themed vacation packages. You'll be part of our small and

Re: String compare in words?

2016-05-30 Thread Márcio Martins via Digitalmars-d-learn
On Monday, 30 May 2016 at 09:28:29 UTC, ag0aep6g wrote: On 05/29/2016 10:40 PM, qznc wrote: bool string_cmp_opt(immutable(ubyte)[] x, immutable(ubyte)[] y) { Having "string" in the function name may be a bit misleading. This doesn't have any special functionality for

Re: Release D 2.071.0

2016-05-03 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 2 May 2016 at 17:02:50 UTC, Jack Stouffer wrote: On Monday, 2 May 2016 at 16:47:13 UTC, Márcio Martins wrote: with 2.070.2: real0m9.775s user0m9.036s sys 0m0.700s with 2.071.0: real0m45.011s user0m41.760s sys 0m3.144s Wow, that's pretty awful. Have you

Re: Release D 2.071.0

2016-05-02 Thread Márcio Martins via Digitalmars-d-announce
On Sunday, 10 April 2016 at 20:18:28 UTC, Lewis wrote: On Thursday, 7 April 2016 at 07:44:48 UTC, Nordlöw wrote: On Tuesday, 5 April 2016 at 22:43:05 UTC, Martin Nowak wrote: Glad to announce D 2.071.0. I read somewhere recently about performance regressions in DMD. Were these related the

Re: Official compiler

2016-02-28 Thread Márcio Martins via Digitalmars-d
On Sunday, 28 February 2016 at 15:02:24 UTC, Mike Parker wrote: On Sunday, 28 February 2016 at 13:31:17 UTC, Márcio Martins wrote: Could we maybe create a quick informative survey, (surveymonkey?), so we can get a glimpse of why people like D and what they believe would improve their

Re: Normal distribution

2016-02-28 Thread Márcio Martins via Digitalmars-d
On Friday, 26 February 2016 at 20:15:10 UTC, Andrei Alexandrescu wrote: On 2/26/16 2:32 PM, Joseph Rushton Wakeling wrote: Yup. The basic problem of getting this stuff into phobos are the architectural problems discussed in that talk. Unlike uniform distribution (which is straightforward to

Re: Official compiler

2016-02-28 Thread Márcio Martins via Digitalmars-d
On Thursday, 25 February 2016 at 01:53:51 UTC, Walter Bright wrote: On 2/17/2016 4:35 PM, Chris Wright wrote: And since DMD is something like twice as fast as LDC, there's at least some argument in favor of keeping it around. When I meet someone new who says they settled on D in their

Re: [WIP] Native SQLite Database reader (works at CTFE)

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 21:09:15 UTC, Stefan Koch wrote: Hello, It is not quite ready to post in Announce, but I would like to inform you that I am planing to open-source my native-sqlite database driver. (well currently it just reads them). However it works fully at CTFE. so if

Re: [OT] Re: Official compiler

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 20:18:14 UTC, David Nadlinger wrote: On Wednesday, 17 February 2016 at 22:57:20 UTC, Márcio Martins wrote: […] On a completely unrelated note, you aren't by any chance the Márcio Martins who is giving a talk at ETH in a couple of days, are you? — David

Re: Official compiler

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 22:33:15 UTC, Iain Buclaw wrote: On 18 February 2016 at 22:23, Jonathan M Davis via Digitalmars-d < digitalmars-d@puremagic.com> wrote: [...] Actually, I'm sure this is a great way to let bugs in. There's no saying what could happen if you switch compiler

Re: Official compiler

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 15:36:42 UTC, Jonathan M Davis wrote: On Thursday, 18 February 2016 at 14:23:12 UTC, Márcio Martins wrote: I agree, but I don't see why this would have to change. It shouldn't change. Frontend development could happen on DMD as the *reference* compiler. And

Re: Official compiler

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 13:23:34 UTC, Andrei Alexandrescu wrote: Which of these advantages cannot be taken advantage of today? I suppose if you combine the feature sets of all compilers you will to some degree be able to get the best of all worlds. But the compiler *representing*

Re: Official compiler

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 12:22:20 UTC, Andrei Alexandrescu wrote: On 02/17/2016 09:28 PM, rsw0x wrote: I'm curious where Andrei stands on this issue, IIRC he was upset at one point that dmd could not be redistributed properly on linux distros. We'd love dmd's backend to have a more

Re: Official compiler

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 12:05:12 UTC, Jonathan M Davis wrote: On Thursday, 18 February 2016 at 11:41:26 UTC, Kai Nacke wrote: On Thursday, 18 February 2016 at 10:45:54 UTC, Márcio Martins wrote: I suppose it's a lot easier to address the compilation speed issue in LDC/GDC, than to

Re: Official compiler

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 06:57:01 UTC, Kai Nacke wrote: On Wednesday, 17 February 2016 at 22:57:20 UTC, Márcio Martins wrote: I was reading the other thread "Speed kills" and was wondering if there is any practical reason why DMD is the official compiler? Currently, newcomers come

Re: Official compiler

2016-02-18 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 10:16:40 UTC, Radu wrote: On Thursday, 18 February 2016 at 00:35:01 UTC, Chris Wright wrote: On Wed, 17 Feb 2016 22:57:20 +, Márcio Martins wrote: I was reading the other thread "Speed kills" and was wondering if there is any practical reason why DMD is

Re: Official compiler

2016-02-17 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 00:06:10 UTC, Xinok wrote: On Wednesday, 17 February 2016 at 22:57:20 UTC, Márcio Martins wrote: I was reading the other thread "Speed kills" and was wondering if there is any practical reason why DMD is the official compiler? ... I pretty much asked this

Re: Official compiler

2016-02-17 Thread Márcio Martins via Digitalmars-d
On Thursday, 18 February 2016 at 00:35:01 UTC, Chris Wright wrote: On Wed, 17 Feb 2016 22:57:20 +, Márcio Martins wrote: I was reading the other thread "Speed kills" and was wondering if there is any practical reason why DMD is the official compiler? Walter Bright is the lead developer,

Official compiler

2016-02-17 Thread Márcio Martins via Digitalmars-d
I was reading the other thread "Speed kills" and was wondering if there is any practical reason why DMD is the official compiler? Currently, newcomers come expecting their algorithm from rosetta code to run faster in D than their current language, but then it seems like it's actually slower.

Re: Wannabe contributor frustrations

2016-02-11 Thread Márcio Martins via Digitalmars-d
On Thursday, 11 February 2016 at 07:23:26 UTC, Jonathan M Davis wrote: On Thursday, 11 February 2016 at 06:57:39 UTC, Daniel Kozak wrote: Dne 11.2.2016 v 01:20 Adam D. Ruppe via Digitalmars-d napsal(a): IMO it is a denial of reality to put them in three separate repositories since they are so

Re: Wannabe contributor frustrations

2016-02-11 Thread Márcio Martins via Digitalmars-d
On Thursday, 11 February 2016 at 11:47:23 UTC, Vladimir Panteleev wrote: On Thursday, 11 February 2016 at 10:55:12 UTC, Márcio Martins wrote: Is there a practical reason why they are not in the same repo? No, other than trying to put them into one would grind everything to a halt for a while

Re: Wannabe contributor frustrations

2016-02-11 Thread Márcio Martins via Digitalmars-d
On Thursday, 11 February 2016 at 14:19:13 UTC, Andrei Alexandrescu wrote: On 2/10/16 6:30 PM, Márcio Martins wrote: I decided to try a couple ideas in druntime and followed this http://wiki.dlang.org/Starting_as_a_Contributor#Fetch_dmd_from_GitHub OK, I added this section:

Wannabe contributor frustrations

2016-02-10 Thread Márcio Martins via Digitalmars-d
I decided to try a couple ideas in druntime and followed this http://wiki.dlang.org/Starting_as_a_Contributor#Fetch_dmd_from_GitHub Everything went fast and smooth - I have a custom built dmd version. Bootstrapping and building dmd was suspiciously fast - took around 15 secs maybe, if I

Re: Odd Destructor Behavior

2016-02-07 Thread Márcio Martins via Digitalmars-d-learn
On Sunday, 7 February 2016 at 21:49:24 UTC, Matt Elkins wrote: I've been experiencing some odd behavior, where it would appear that a struct's destructor is being called before the object's lifetime expires. More likely I am misunderstanding something about the lifetime rules for structs. I

Re: Conflicting UDA

2016-02-06 Thread Márcio Martins via Digitalmars-d-learn
On Saturday, 6 February 2016 at 15:01:44 UTC, Marc Schütz wrote: On Saturday, 6 February 2016 at 13:36:32 UTC, Márcio Martins wrote: [...] `@(mylib.ignore)` should work. You could open an enhancement request to enable the paren-less syntax. Thanks, that does work indeed and is not that

Conflicting UDA

2016-02-06 Thread Márcio Martins via Digitalmars-d-learn
I came across an issue with UDAs and was wondering if there really is no way or if I just missed something... Basically, my library has an @ignore UDA, which conflicts with vibe.d's vibe.data.serialization. If both mine and vibe's module are imported, DMD will fail with a very

Re: DIP83

2016-01-15 Thread Márcio Martins via Digitalmars-d
On Thursday, 14 January 2016 at 14:28:05 UTC, deadalnix wrote: Ok I'll bite: it doesn't matter. This DIP is additive. The problem with D is not that we don't have stuff in there, is most of the stuff in there are half backed. Adding more half baked things in there only makes things worse.

Re: Voting For std.experimental.ndslice

2015-12-29 Thread Márcio Martins via Digitalmars-d
On Tuesday, 29 December 2015 at 13:54:56 UTC, Jack Stouffer wrote: On Tuesday, 29 December 2015 at 13:30:47 UTC, Márcio Martins wrote: If I am reading the code right, the number of dimensions must always be known at compile time, right? Not necessarily. The dimensions for this slice are

Re: Voting For std.experimental.ndslice

2015-12-29 Thread Márcio Martins via Digitalmars-d
On Tuesday, 29 December 2015 at 07:45:14 UTC, Ilya Yaroshenko wrote: On Monday, 28 December 2015 at 22:39:45 UTC, Ilya Yaroshenko wrote: On Monday, 28 December 2015 at 21:43:35 UTC, Robert burner Schadek wrote: [...] Agreed 1. First paragraph was replaced by your variant. 2. Binary

Re: Release D 2.069.0

2015-12-08 Thread Márcio Martins via Digitalmars-d-announce
On Tuesday, 8 December 2015 at 08:39:26 UTC, Jean-Yves Vion-Dury wrote: On Monday, 7 December 2015 at 17:32:05 UTC, Márcio Martins wrote: On Monday, 7 December 2015 at 17:06:48 UTC, Jean-Yves Vion-Dury wrote: On Wednesday, 4 November 2015 at 15:25:04 UTC, Márcio Martins wrote: [...] FYI, I

Re: Question about mysql-d Object

2015-12-07 Thread Márcio Martins via Digitalmars-d-learn
On Monday, 7 December 2015 at 14:40:12 UTC, Martin Tschierschke wrote: When I do the following: auto mysql = new Mysql("localhost", 3306, "mt", "", "verwaltung"); auto rows = mysql.query("select field from my_table limit 50"); foreach(row;rows){ writeln(row["field"]);} // second time same

Re: Release D 2.069.0

2015-12-07 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 7 December 2015 at 17:06:48 UTC, Jean-Yves Vion-Dury wrote: On Wednesday, 4 November 2015 at 15:25:04 UTC, Márcio Martins wrote: [...] FYI, I just installed the 2.069 version, and now I'm unable to compile some modules, getting the same "Error: out of memory". I isolated a tiny

Re: Comparison operator overloading

2015-12-07 Thread Márcio Martins via Digitalmars-d-learn
On Monday, 7 December 2015 at 00:43:50 UTC, Ali Çehreli wrote: On 12/06/2015 06:41 AM, Márcio Martins wrote: > auto m = (a > b) * a + 15; > auto c = a.choose(a > b)^^2; What do those operations do? Are you thinking of a special meaning for '>', perhaps common in numerical computations, which

Comparison operator overloading

2015-12-06 Thread Márcio Martins via Digitalmars-d-learn
I am writing a generic numerical array struct, and I can't find a way to do element-wise comparison operators. What I had envisioned was something like the following, assuming a, b, c and m are array-like, and all operations return arrays. auto m = (a > b) * a + 15; auto c = a.choose(a >

Re: Release D 2.069.0

2015-11-23 Thread Márcio Martins via Digitalmars-d-announce
On Thursday, 5 November 2015 at 01:08:42 UTC, Martin Nowak wrote: On Wednesday, 4 November 2015 at 17:52:23 UTC, Dmitry Olshansky wrote: If host machine is x64 bit windows try setting large address aware bit on the executable (there are tools to do that IRC), would allow it to eat up to ~4

Re: String interpolation

2015-11-10 Thread Márcio Martins via Digitalmars-d-learn
On Tuesday, 10 November 2015 at 11:29:32 UTC, TheFlyingFiddle wrote: On Tuesday, 10 November 2015 at 10:41:52 UTC, tired_eyes wrote: On Tuesday, 10 November 2015 at 10:33:30 UTC, Tobias Pankrath wrote: Ruby: a = 1 b = 4 puts "The number #{a} is less than #{b}" PHP: $a = 1; $b = 4; echo "The

Re: Scientific computing in D

2015-11-10 Thread Márcio Martins via Digitalmars-d
On Tuesday, 10 November 2015 at 10:13:46 UTC, Russel Winder wrote: On Mon, 2015-11-09 at 19:31 +, Márcio Martins via Digitalmars-d wrote: I have been running some MCMC simulations in Python and it's hard to cope with how unbelievably slow it is. Takes me almost a minute to run a few

Re: Rust's simple download script

2015-11-10 Thread Márcio Martins via Digitalmars-d
On Monday, 9 November 2015 at 23:07:57 UTC, Andrei Alexandrescu wrote: Rust has a nice way to download at https://www.rust-lang.org/downloads.html for Posix: $ curl -sSf https://static.rust-lang.org/rustup.sh | sh -s -- The method is simple and transparent. An optional --channel=beta or

Re: Rust's simple download script

2015-11-10 Thread Márcio Martins via Digitalmars-d
On Tuesday, 10 November 2015 at 04:43:18 UTC, Zekereth wrote: ... I agree completely. Please NO! What's wrong with the current system? It seems to work just fine for me. Well, you already use D so obviously it works good enough for you. However, there might be a million people out there that

Scientific computing in D

2015-11-09 Thread Márcio Martins via Digitalmars-d
I have been running some MCMC simulations in Python and it's hard to cope with how unbelievably slow it is. Takes me almost a minute to run a few hundred thousand samples on my laptop whereas I can run the same simulation with a million samples in under 100ms, on my phone with JavaScript on a

Re: Release D 2.069.0

2015-11-04 Thread Márcio Martins via Digitalmars-d-announce
On Wednesday, 4 November 2015 at 01:50:38 UTC, Martin Nowak wrote: Glad to announce D 2.069.0. http://dlang.org/download.html http://downloads.dlang.org/releases/2.x/2.069.0/ This is the first release with a self-hosted dmd compiler and comes with even more rangified phobos functions,

Re: DMD is slow for matrix maths?

2015-10-26 Thread Márcio Martins via Digitalmars-d
On Monday, 26 October 2015 at 02:37:18 UTC, Etienne Cimon wrote: I've been playing around with perf and my web server and found that the bottleneck is by far the math module of Botan: https://github.com/etcimon/botan/blob/master/source/botan/math/mp/mp_core.d [...]

Re: Is Anything Holding you back?

2015-10-02 Thread Márcio Martins via Digitalmars-d
On Friday, 2 October 2015 at 09:44:00 UTC, ponce wrote: On Friday, 2 October 2015 at 02:25:21 UTC, Yaser wrote: Are there any critical frameworks or libraries that are holding you back in fully investing in D? Obviously I think D is an awesome language, but some frameworks/libraries hold me

Re: New blog about D

2015-10-02 Thread Márcio Martins via Digitalmars-d-announce
On Tuesday, 29 September 2015 at 10:23:25 UTC, Chris wrote: On Tuesday, 29 September 2015 at 04:19:58 UTC, Mike Parker wrote: On Monday, 28 September 2015 at 14:26:35 UTC, Chris wrote: I really don't like blog posts that have overly broad titles when the subject matter is technical. I

Re: New blog about D

2015-09-28 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 28 September 2015 at 13:12:35 UTC, Chris wrote: On Monday, 28 September 2015 at 12:14:56 UTC, Márcio Martins wrote: On Monday, 28 September 2015 at 11:53:28 UTC, Vladimir Panteleev wrote: On Sunday, 27 September 2015 at 23:23:05 UTC, Márcio Martins wrote: Today I launched a very

Re: New blog about D

2015-09-28 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 28 September 2015 at 09:49:03 UTC, John Colvin wrote: On Sunday, 27 September 2015 at 23:23:05 UTC, Márcio Martins wrote: Today I launched a very tiny and humble blog, with the first post being about D. It's likely all posts will be about D in the end... [...] this is what

Re: New blog about D

2015-09-28 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 28 September 2015 at 11:53:28 UTC, Vladimir Panteleev wrote: On Sunday, 27 September 2015 at 23:23:05 UTC, Márcio Martins wrote: Today I launched a very tiny and humble blog, with the first post being about D. It's likely all posts will be about D in the end... You can reach it

Re: New blog about D

2015-09-28 Thread Márcio Martins via Digitalmars-d-announce
On Monday, 28 September 2015 at 10:02:20 UTC, Chris wrote: "A common problem in game programming and how D solved it" That indeed sounds more appealing for a general audience. Thanks Chris!

New blog about D

2015-09-27 Thread Márcio Martins via Digitalmars-d-announce
Today I launched a very tiny and humble blog, with the first post being about D. It's likely all posts will be about D in the end... You can reach it http://www.mmartins.me I want to get better at writing, as I have barely ever written anything other than code, and my name... I noticed there