I'm trying to write a thin wrapper around redblacktree, but it
seems every object of the class shares the same copy of
redblacktree. Am I doing something wrong or is this a bug.
Minimal code example:
import std.array;
import std.container;
import std.stdio;
class A {
auto tree = new RedBl
Great!
Thx
On Wednesday, 28 May 2014 at 07:13:37 UTC, BlackEdder wrote:
I'm trying to write a thin wrapper around redblacktree, but it
seems every object of the class shares the same copy of
redblacktree. Am I doing something wrong or is this a bug.
Minimal code example:
import std.array;
import std.con
On Wednesday, 28 May 2014 at 03:25:28 UTC, Suminda Dharmasena
wrote:
Hi,
D2 has been out for a while. Looking to see what the roadmap is
like towards D3?
Suminda
No, it has not been out for a while. I would even say that it's
not out yet!
It still doesn't exist yet in the same way as D1.
Mike Hearn has started a thread on the Kotlin (*) mailing list extolling
the virtues of D's transitive const. Andrey Breslav (the leader of the
Kotlin team at JetBrains) has made a couple of replies that I think may
be interesting here:
"As C++ and D show, const is not that easy. We'd like to ha
On Wednesday, 28 May 2014 at 07:13:37 UTC, BlackEdder wrote:
I'm trying to write a thin wrapper around redblacktree, but it
seems every object of the class shares the same copy of
redblacktree. Am I doing something wrong or is this a bug.
Minimal code example:
import std.array;
import std.con
On Wednesday, 28 May 2014 at 08:37:14 UTC, Chris wrote:
On Wednesday, 28 May 2014 at 07:13:37 UTC, BlackEdder wrote:
I'm trying to write a thin wrapper around redblacktree, but it
seems every object of the class shares the same copy of
redblacktree. Am I doing something wrong or is this a bug.
On Wednesday, 28 May 2014 at 03:25:28 UTC, Suminda Dharmasena
wrote:
Hi,
D2 has been out for a while. Looking to see what the roadmap is
like towards D3?
Suminda
FYI there is no stable version of D2. There are still many grey
areas and there are yet to come possible radical changes to come
On Tuesday, 27 May 2014 at 00:12:59 UTC, chuck wrote:
Would anyone be interested in a collaboration forum? I am
thinking of starting one on Proboards to aid in
development/collaboration between developers on D and
libraries/bindings. Reading through the posts, I have seen that
several people h
On Wednesday, 28 May 2014 at 08:46:30 UTC, Rene Zwanenburg wrote:
The problem is the initialization of A.tree. Short answer, move
it to a constructor and it should work.
Now what I think is going on: default values for member fields
must be known at compile time. This is why structs can do
On Wednesday, 28 May 2014 at 08:49:42 UTC, Rene Zwanenburg wrote:
On Wednesday, 28 May 2014 at 08:37:14 UTC, Chris wrote:
On Wednesday, 28 May 2014 at 07:13:37 UTC, BlackEdder wrote:
I'm trying to write a thin wrapper around redblacktree, but
it seems every object of the class shares the same c
On Friday, 16 May 2014 at 19:28:26 UTC, H. S. Teoh via
Digitalmars-d wrote:
On Fri, May 16, 2014 at 02:52:43PM -0400, Nick Sabalausky via
Digitalmars-d wrote:
But then using it as a GUI engine and software platform is like
abusing Latex or PDF to make software run inside Acrobat
Viewer. All
th
could be a nice next step for D if "D compiler as a library" comes
someday available
http://runtimecompiledcplusplus.blogspot.co.uk/
from the blog:
Runtime Compiled C++ is in Kythera, the AI behind Star Citizen.
Video: RCC++ at the 2012 Develop Conference
http://vimeo.com/85934969
and it see
example from a simulation project
a runtime-configured (0-6)-axis cinematics system able to bring axis to
an given position or calculates back to axis positions for simulation
purpose
so the interface is target/current-reached-position and axis.positions
currently done by using virtuals, can
While waiting for the new stream I wrote myself a stream for file
io only.
http://dpaste.dzfl.pl/bc470f96b357
Hope it helps your work somehow. Maybe at least the unittests are
helpful?
Java misses this feature badly, forcing programmers to copy-paste
bloated code (constructor A calls constructor B with fewer
arguments, constructor B calls constructor C etc, same thing with
methods). Please tell me, does D support this feature?
int myNiceFunc(double a, double b=0, int c=0) {.
On Wednesday, 28 May 2014 at 11:54:30 UTC, Wanderer wrote:
Java misses this feature badly, forcing programmers to
copy-paste bloated code (constructor A calls constructor B with
fewer arguments, constructor B calls constructor C etc, same
thing with methods). Please tell me, does D support this
On Wednesday, 28 May 2014 at 11:57:51 UTC, Namespace wrote:
On Wednesday, 28 May 2014 at 11:54:30 UTC, Wanderer wrote:
Java misses this feature badly, forcing programmers to
copy-paste bloated code (constructor A calls constructor B
with fewer arguments, constructor B calls constructor C etc,
Wanderer:
Please tell me, does D support this feature?
You can answer by yourself similar questions online here:
http://dpaste.dzfl.pl/
Bye,
bearophile
On Wednesday, 28 May 2014 at 06:20:29 UTC, Idan Arye wrote:
From what I know(don't know how it is implemented in D. I know
it doesn't work that way in languages that emulate closures
like C++ and Java) delegates don't "allocate a closure" -
rather, they use a the callstack frame that was alread
On Saturday, 24 May 2014 at 15:26:30 UTC, Joseph Rushton Wakeling
via Digitalmars-d wrote:
Hello all,
Just to say a big thank you to everyone speaking and involved
in the organization of DConf this year. It was fantastic to be
able to follow the conference via livestreaming (as much as
timez
Big language change which does not fix any fundamental issue. I
think at stage of language development it is better to not even
discuss those ;)
On 2014-05-28 10:22:07 +, dennis luehring said:
could be a nice next step for D if "D compiler as a library" comes
someday available
http://runtimecompiledcplusplus.blogspot.co.uk/
from the blog:
Runtime Compiled C++ is in Kythera, the AI behind Star Citizen.
Video: RCC++ at the 2012 De
On Monday, 26 May 2014 at 20:58:22 UTC, Nordlöw wrote:
I've recent fixed a few warnings in D here:
https://github.com/D-Programming-Language/dmd/pull/3543
At the end of the thread I asked:
Should I continue fixing GLUE, BACK and ROOT or focus on
remaining warnings in DMD?
but Walter has not
Am 28.05.2014 16:32, schrieb Byron Heads:
Would love to have this for vibe.d
for what use case?
Dicebot:
I don't think it is worth spending too much time on it because
of ongoing DDMD transition which will make many of those issues
obsolete.
Some of those warnings are not generated by D compiler (like
unused variables and labels, unused arguments, signed/unsigned
comparisons, etc), so
Although I should have known about it long ago, I have only just become
aware of Andrei's std.benchmark, which appears in his fork of Phobos,
but not in real Phobos. Is there an intention it should be in Phobos, or
is it intended to be a separate thing?
For me a benchmark framework should be outpu
On Wednesday, 28 May 2014 at 15:44:22 UTC, Russel Winder via
Digitalmars-d wrote:
Although I should have known about it long ago, I have only
just become
aware of Andrei's std.benchmark, which appears in his fork of
Phobos,
but not in real Phobos. Is there an intention it should be in
Phobos, o
On Wednesday, 28 May 2014 at 14:06:38 UTC, Meta wrote:
What I meant to say by "allocate a closure" is that variables
in the stack frame that the delegate has a pointer to are moved
to the heap when they go out of scope. I believe this implies
GC allocation, but I'm not 100% sure. If that *were*
On Wednesday, 28 May 2014 at 13:01:52 UTC, bearophile wrote:
Wanderer:
Please tell me, does D support this feature?
You can answer by yourself similar questions online here:
http://dpaste.dzfl.pl/
Bye,
bearophile
Thanks! :-)
On Tuesday, 27 May 2014 at 06:47:21 UTC, simendsjo wrote:
On 05/27/2014 02:12 AM, chuck wrote:
Would anyone be interested in a collaboration forum? I am
thinking of
starting one on Proboards to aid in development/collaboration
between
developers on D and libraries/bindings. Reading through the
On Wednesday, 28 May 2014 at 09:37:55 UTC, Edwin van Leeuwen
wrote:
Thank you for the reply. Does this mean I should never
initialize classes/objects like that or is it more specific to
RBT?
It's the same for any class.
I guess structs have the same problem with classes/objects?
That's rig
On Wed, 2014-05-28 at 15:54 +, Joakim via Digitalmars-d wrote:
[…]
> A google search turns up a long review thread a couple years ago:
>
> http://forum.dlang.org/thread/mailman.73.1347916419.5162.digitalmar...@puremagic.com
A somewhat depressing thread.
> Looks like it was remanded for furth
It's very hard to keep up-to-date with all these successors to
Java. Every half a year a new language appears, and it's always
"better than all previous". :-(
D's const feature is nice and clear. But what made me "fall in
love" with D, is 'immutable' modifier. No inner mutable pieces
possible
alpha(-beta 2589 J BETA
__charlie 898O^432
#143% igloo bega0r 13^* 985%2#$zero
On Wednesday, 28 May 2014 at 15:15:38 UTC, dennis luehring wrote:
Am 28.05.2014 16:32, schrieb Byron Heads:
Would love to have this for vibe.d
for what use case?
Diet templates
On Wednesday, 28 May 2014 at 14:14:40 UTC, Dicebot wrote:
It was really funny to observe output of DFeed during the
conference by the way - PR merges, issue comments and casual
hacking have never stopped. I am somewhat surprised no one has
managed to create a pull request right in the middle
On Wed, 2014-05-28 at 16:31 +, Wanderer via Digitalmars-d wrote:
> It's very hard to keep up-to-date with all these successors to
> Java. Every half a year a new language appears, and it's always
> "better than all previous". :-(
I am not sure which languages you are thinking of here, there
On 5/28/14, 8:54 AM, Wanderer wrote:
Java misses this feature badly, forcing programmers to copy-paste
bloated code (constructor A calls constructor B with fewer arguments,
constructor B calls constructor C etc, same thing with methods). Please
tell me, does D support this feature?
int myNiceFun
On Wednesday, 28 May 2014 at 17:11:09 UTC, Ary Borenszweig wrote:
But there is a 'this' in that place (it's not a static
function).
Should I file this as a bug?
I can't find exact place in spec but AFAIK default arguments in D
are evaluated in context of call scope, same as in C. Could have
On Wednesday, 28 May 2014 at 16:33:13 UTC, Russel Winder via
Digitalmars-d wrote:
On Wed, 2014-05-28 at 15:54 +, Joakim via Digitalmars-d
wrote:
[…]
A google search turns up a long review thread a couple years
ago:
http://forum.dlang.org/thread/mailman.73.1347916419.5162.digitalmar...@pur
On Wednesday, 28 May 2014 at 14:16:56 UTC, Dicebot wrote:
Big language change which does not fix any fundamental issue.
Having a GC pointer type + several other mechanisms could reduce
the amount of scanned memory to a level where it slips below the
"pain threshold" for interactive apps. That
On Wednesday, 28 May 2014 at 17:21:18 UTC, Ola Fosheim Grøstad
wrote:
On Wednesday, 28 May 2014 at 14:16:56 UTC, Dicebot wrote:
Big language change which does not fix any fundamental issue.
Having a GC pointer type + several other mechanisms could
reduce the amount of scanned memory to a leve
On Wednesday, 28 May 2014 at 16:33:13 UTC, Russel Winder via
Digitalmars-d wrote:
On Wed, 2014-05-28 at 15:54 +, Joakim via Digitalmars-d
wrote:
[…]
A google search turns up a long review thread a couple years
ago:
http://forum.dlang.org/thread/mailman.73.1347916419.5162.digitalmar...@pur
On Tuesday, 27 May 2014 at 16:47:38 UTC, Etienne wrote:
You're right, it's obviously easier to keep it as the same
pointer syntax but hijack the stdlib malloc functions to
forcibly go through the GC.
If the GC controls everything, you can keep the info in 8 byte
pointers.
- The GC always re
On Wednesday, 28 May 2014 at 17:35:18 UTC, Ola Fosheim Grøstad
wrote:
On Wednesday, 28 May 2014 at 17:27:20 UTC, Dicebot wrote:
Adding GC pointer type does not enable anything that you can't
do write now for high-level applications and does not help at
all low-level applications. It is niche so
On Wednesday, 28 May 2014 at 17:27:20 UTC, Dicebot wrote:
Adding GC pointer type does not enable anything that you can't
do write now for high-level applications and does not help at
all low-level applications. It is niche solution.
A niche solution is fine by me. Etienne has expressed interes
On Wednesday, 28 May 2014 at 17:39:21 UTC, Dicebot wrote:
Get this into upstream and you will have dozens unhappy about
updating for their code. It is never that simple.
It doesn't have to be in upstream. It could be an experimental
compiler implemented in pure D. I would back that, if Etienne
On Tuesday, 27 May 2014 at 14:55:33 UTC, Luís Marques wrote:
BTW 2, is `this(int = 0)' the best workaround (still?) for the
fact that I want the ctor to be called, even if it doesn't
really require any parameter?
AFAIK, no, since "Foo()" will actually do nothing. "this(Arg =
dummy)" is actual
On 5/28/2014 1:49 AM, Russel Winder via Digitalmars-d wrote:
Also, D's approach does not support lazy evaluation, caches of all sorts
etc, that we think are crucial in application software.
Yes, that's so-called "logical const". This has come up several times here, and
many have argued strongl
or maybe a branch/sub-set, GC-free, version of D arrays and
classes.
thumbs up for that. Everytime when i do OS-level or other
programming in D, where i can't/won't have GC i can't have
arrays/classes. One possibility is to hack the library but it
either leaks memory(because you can't free it
On Wed, 2014-05-28 at 17:33 +0100, Russel Winder wrote:
[…]
> Instead of wallowing in the backwaters of non-Phobosity, it should
> become a module accessible independently via a DVCS (presumably Git),
> and Dub? (though I will be using SCons) such that people can amend,
> extend and send in pull re
if you say so... (and god spoke "there will be light"...and there
was light)
I just mean, if you restrict users to some subset of
possibilities they will never be easily able to explore the wider
space of the set/superset...
Some of those warnings are not generated by D compiler (like
unused variables and labels, unused arguments, signed/unsigned
comparisons, etc), so better to catch and fix them before
porting the code to D.
I completely agree.
/Per
On Wednesday, 28 May 2014 at 18:08:42 UTC, Walter Bright wrote:
On 5/28/2014 1:49 AM, Russel Winder via Digitalmars-d wrote:
Also, D's approach does not support lazy evaluation, caches of
all sorts
etc, that we think are crucial in application software.
Yes, that's so-called "logical const".
My first day at DConf, during lunch, I ended up sitting next to
the CTO/CEO of a startup company that was considering D as their
language of choice. He commented to me, and which makes sense to
me, that the format of the conference wasn't very well geared to
people who are just interested in fi
On Wednesday, 28 May 2014 at 20:49:31 UTC, deadalnix wrote:
It is probably a good idea to provide such escape in a safe
interface somewhere in the library, no ?
I am not sure it is possible to design such module so that it
will be both sufficiently generic and reliably type safe. Can be
an in
On 5/28/2014 1:49 PM, deadalnix wrote:
It is probably a good idea to provide such escape in a safe
interface somewhere in the library, no ?
If anyone wants to design such a module, please do so.
On 5/28/2014 2:05 PM, Chris Williams wrote:
His recommendation was to offer two tracks over two days (instead of one over
three), whith one track focussing on things like how to get a development
environment set up on different platforms, how to debug, overview of language
features, etc. That way
Personally I think there were too many talks *per day*, it was hard not
getting tired and all the talks were extremely interesting. But I
understand that it's hard for people to take more free days for dconf alone.
On Wednesday, May 28, 2014, Walter Bright via Digitalmars-d <
digitalmars-d@puremag
On Wednesday, 28 May 2014 at 18:08:42 UTC, Walter Bright wrote:
On 5/28/2014 1:49 AM, Russel Winder via Digitalmars-d wrote:
Also, D's approach does not support lazy evaluation, caches of
all sorts
etc, that we think are crucial in application software.
Yes, that's so-called "logical const".
On Wednesday, 28 May 2014 at 22:04:47 UTC, Andrej Mitrovic via
Digitalmars-d wrote:
Personally I think there were too many talks *per day*, it was
hard not
getting tired and all the talks were extremely interesting. But
I
understand that it's hard for people to take more free days for
dconf alo
On Wed, 28 May 2014 08:41:43 +
Don via Digitalmars-d wrote:
> On Wednesday, 28 May 2014 at 03:25:28 UTC, Suminda Dharmasena
> wrote:
> > Hi,
> >
> > D2 has been out for a while. Looking to see what the roadmap is
> > like towards D3?
> >
> > Suminda
>
> No, it has not been out for a while. I
On Wed, 28 May 2014 17:20:22 +
TheFlyingFiddle via Digitalmars-d wrote:
> If i am not mistaken, parts of std.benchmark moved into
> std.datetime. After this work on std.benchmark stopped.
You're mistaken. Those were always in std.datetime. Rather, they were moving
into std.benchmark (which i
On Wednesday, 28 May 2014 at 21:22:36 UTC, Walter Bright wrote:
On 5/28/2014 1:49 PM, deadalnix wrote:
It is probably a good idea to provide such escape in a safe
interface somewhere in the library, no ?
If anyone wants to design such a module, please do so.
i have to say i'm not sure what p
On Wednesday, 28 May 2014 at 22:04:47 UTC, Andrej Mitrovic via
Digitalmars-d wrote:
Personally I think there were too many talks *per day*, it was
hard not
getting tired and all the talks were extremely interesting. But
I
understand that it's hard for people to take more free days for
dconf alo
On 5/28/2014 4:16 PM, deadalnix wrote:
I guess this is a good sign. I mean, some people are traveling
from far away, and it cost a lot.
The reason Dconf was 3 days was to make it worthwhile for people traveling some
distance to get there. 2 days is fine for a domestic conference, but 3 days is
This is currently accepted code:
void main() {
import std.array: appender;
import std.format: formattedWrite;
auto writer = appender!string;
formattedWrite(writer, "%s is the ultimate %s.", 42,
"answer");
assert(writer.data == "42 is the ultimate answer.");
}
But there
On Wednesday, 28 May 2014 at 23:16:58 UTC, deadalnix wrote:
On Wednesday, 28 May 2014 at 22:04:47 UTC, Andrej Mitrovic via
Digitalmars-d wrote:
Personally I think there were too many talks *per day*, it was
hard not
getting tired and all the talks were extremely interesting.
But I
understand th
On Wednesday, 28 May 2014 at 23:27:34 UTC, bearophile wrote:
This is currently accepted code:
void main() {
import std.array: appender;
import std.format: formattedWrite;
auto writer = appender!string;
formattedWrite(writer, "%s is the ultimate %s.", 42,
"answer");
assert
On Wednesday, 28 May 2014 at 22:48:22 UTC, Jonathan M Davis via
Digitalmars-d wrote:
That's interesting :D
On Wednesday, 28 May 2014 at 21:05:13 UTC, Chris Williams wrote:
My first day at DConf, during lunch, I ended up sitting next to
the CTO/CEO of a startup company that was considering D as
their language of choice. He commented to me, and which makes
sense to me, that the format of the conferenc
On 5/28/2014 5:20 PM, ed wrote:
a) a workshop for new D users with entry-level talks and maybe even hands-on
sessions (would require attendees bring a laptop)
We did that for Dconf 2013; having a "tutorial day" preceding the conference.
There wasn't enough interest in it, so we cancelled it.
This is just recent and only seems to be affecting posts by J M
Davies, which are often enlightening so it is a bit frustrating.
I get the following error in the web interface:
"Don't know how parse text/html message"
I have switched to email for now but I actually prefer the web
interface.
On Thursday, 29 May 2014 at 01:49:51 UTC, ed wrote:
This is just recent and only seems to be affecting posts by J M
Davies, which are often enlightening so it is a bit frustrating.
I get the following error in the web interface:
"Don't know how parse text/html message"
I have switched to em
On Wed, 28 May 2014 18:21:01 -0400, Chris Williams
wrote:
If only one person like the guy I mentioned is going to show up, then to
Walter's point, there's not much value in providing such a session in
the conference. But maybe next year advertize an "intro to D" class that
will be on the
On Wed, 28 May 2014 06:28:25 -0400, Tero wrote:
While waiting for the new stream I wrote myself a stream for file io
only.
http://dpaste.dzfl.pl/bc470f96b357
Hope it helps your work somehow. Maybe at least the unittests are
helpful?
Cool. I actually have made some progress, I have a new-
On Thursday, 29 May 2014 at 01:49:51 UTC, ed wrote:
This is just recent and only seems to be affecting posts by J M
Davies, which are often enlightening so it is a bit frustrating.
I get the following error in the web interface:
"Don't know how parse text/html message"
I have switched to em
Just noticed, the paste was screwed. Had a weird character in a
comment which seemed to confuse dpaste.
Here's the full code:
http://dpaste.dzfl.pl/fc2073c19e7d
On Thursday, 29 May 2014 at 03:43:32 UTC, Steven Schveighoffer
wrote:
On Wed, 28 May 2014 06:28:25 -0400, Tero
wrote:
While waiti
On Wednesday, 28 May 2014 at 22:48:22 UTC, Jonathan M Davis via
Digitalmars-d wrote:
Please configure your email client to include a text/plain part.
Your messages are unreadable to any users of clients that ignore
text/html parts, which includes all users of the forum web
interface.
80 matches
Mail list logo