On Wed, 20 Mar 2013 13:32:50 -0400, Russel Winder rus...@winder.org.uk
wrote:
PS http://www.digitalmars.com/d/archives/digitalmars/D/announce/ appears
to stop in 2012-12
http://forum.dlang.org/group/digitalmars.D.announce
Don't use that other thing any more.
-Steve
On 03/18/2013 05:51 AM, Jordi Sayol wrote:
Al 17/03/13 23:29, En/na 1100110 ha escrit:
On 03/17/2013 04:05 PM, Jordi Sayol wrote:
Al 17/03/13 21:41, En/na Russel Winder ha escrit:
On Sun, 2013-03-17 at 20:00 +0100, Jordi Sayol wrote:
Al 17/03/13 19:22, En/na Russel Winder ha escrit:
[…]
I
On 03/20/2013 05:04 PM, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
contributions to Deimos.
Besides comments to
On Monday, March 18, 2013 00:19:03 Peter Williams wrote:
So my question is Why are the arguments to opEquals and opCmp
(for Objects) not declared in or const?.
By the way, this is post where it was officially decided that we'd be working
on
removing opCmp, opEquals, toHash, and toString from
On 03/20/2013 05:04 PM, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
contributions to Deimos.
Besides comments to
On Wednesday, 20 March 2013 at 04:39:14 UTC, Jonathan M Davis
wrote:
On Tuesday, March 19, 2013 20:51:28 Stewart Gordon wrote:
But the question still remains: How do we implement this
change without
causing mass disruption? It might be the case that
programmers just
need to remove
On 2013-03-20 23:17, Graham Fawcett wrote:
But present and blank aren't opposites in English. isNonBlank or
isNotBlank are opposites of isBlank, but isPresent would be the
opposite of isAbsent. It seems almost meaningless in the context of a
string predicate --- If I saw it in code, I would
On 2013-03-20 21:18, Simen Kjaeraas wrote:
I say do the review, make things faster afterwards. There'll always
be stuff you can do better, and it's not really harder to do after a
review. Plus, that will get it into Phobos faster.
Sorry about necroing the thread, btw. My mail client ferked up
On Thursday, March 21, 2013 08:29:28 deadalnix wrote:
Wouldn't that trigger bunch of false warning on legitimate
overloaded opSomething ?
I'm not sure that overriding a deprecated function triggers a deprecation
warning, but regardless, for opEquals and opCmp, that wouldn't be a problem,
http://d.puremagic.com/issues/show_bug.cgi?id=9773
On Thursday, 21 March 2013 at 05:01:06 UTC, Kagamin wrote:
On Wednesday, 20 March 2013 at 14:34:21 UTC, Nick Sabalausky
wrote:
Since *at least* as far back as XP, Windows has handled \n
newlines
perfectly fine. The command line displays them properly, .BAT
scripts
handle them properly, every
On 2013-03-21 02:52, Alan wrote:
I really wanted to use GtkD for example (I know it is an extension for
the language, not part of it), but the only tutorials I could find with
good examples were for C, C++, C#, Python, etc. For someone like me who
does not have much experience writing a GUI,
On 2013-03-20 22:08, Nick Sabalausky wrote:
I doubt there's a bugzilla entry for this since it is, unfortunately,
the intended behavior. I didn't want to go posting a 'zilla issue for
it before discussing here because I figured that might just end up
INVALID or WONTFIX.
If you make it an
On 2013-03-20 23:00, Graham Fawcett wrote:
Is anyone still using MacOS earlier than version 10 (OSX)? Mac OS 9 was
discontinued in 2002.
On OSX, there's certainly no problem with Unix line endings. But I guess
if we include ancient Windows support as an option, then ancient Mac
support should
On 2013-03-21 11:00, Jacob Carlborg wrote:
I would say that each #include should have _at least_ one corresponding
import. Then there could be additional imports as well.
Sure, there could be unnecessary includes but that's not very likely.
Forgot to say, I usually just remove all includes
On 2013-03-21 07:59, 1100110 wrote:
In particular,
Replace C's include
Each #include needs to have a corresponding import path.to.header;
That has certainly not been my experience. Often one D import will map
to a couple of c includes.
I would suggest amending that statement.
19.03.2013 2:34, Denis Shelomovskij пишет:
1. DM C++ compiler source is required to build Optlink.
2. C++ compiler is not open-source.
3. You can not build Optlink.
4. Walter isn't going to change anything
It works now! Thanks be to God!
Optlink Issue 7139 now looks like this (with Optlink
On 2013-03-20 23:04, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
contributions to Deimos.
Besides comments to improve
On Wednesday, 20 March 2013 at 22:46:58 UTC, Lars T. Kyllingstad
wrote:
Sorry for the delay, but I've pushed a new version now. There
are still a few things I haven't done wrt. documentation* and
unittests**, but the changes to the API and internals should be
in place.
Since (IIRC) all
On 03/21/2013 05:00 AM, Jacob Carlborg wrote:
On 2013-03-21 07:59, 1100110 wrote:
In particular,
Replace C's include
Each #include needs to have a corresponding import path.to.header;
That has certainly not been my experience. Often one D import will map
to a couple of c includes.
I
On 2013-03-21 13:01, 1100110 wrote:
Oh, we aren't on the same page.
Here, I'm curious as to how you would translate these into D.
#include stdbool.h
#include stdarg.h/* we need va_list */
#include stddef.h/* we want wchar_t */
Right, that's a good point. You still need stddef if you
On Thursday, 21 March 2013 at 07:39:53 UTC, Jacob Carlborg wrote:
On 2013-03-20 23:17, Graham Fawcett wrote:
But present and blank aren't opposites in English.
isNonBlank or
isNotBlank are opposites of isBlank, but isPresent would
be the
opposite of isAbsent. It seems almost meaningless in
On 03/21/2013 07:09 AM, Jacob Carlborg wrote:
On 2013-03-21 13:01, 1100110 wrote:
Oh, we aren't on the same page.
Here, I'm curious as to how you would translate these into D.
#include stdbool.h
#include stdarg.h /* we need va_list */
#include stddef.h /* we want wchar_t */
Right, that's a
On Wednesday, 20 March 2013 at 22:04:50 UTC, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's
still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
contributions to Deimos.
1100110 wrote:
On 03/20/2013 05:04 PM, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
contributions to Deimos.
1100110 wrote:
On 03/20/2013 05:04 PM, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
contributions to Deimos.
Jens Mueller wrote:
1100110 wrote:
On 03/20/2013 05:04 PM, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
Jacob Carlborg wrote:
On 2013-03-20 23:04, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
contributions to Deimos.
Craig Dillabaugh wrote:
On Wednesday, 20 March 2013 at 22:04:50 UTC, Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still
very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
On Thu, 21 Mar 2013 10:41:35 +0100
Jacob Carlborg d...@me.com wrote:
On 2013-03-20 22:08, Nick Sabalausky wrote:
I doubt there's a bugzilla entry for this since it is,
unfortunately, the intended behavior. I didn't want to go posting a
'zilla issue for it before discussing here because I
On 2013-03-21 14:53, 1100110 wrote:
That does sound vaguely familiar...
Yes, it's size is 16 on Windows and 32 on Linux and OSX.
My bad, dchar then. (with wchar for Windows)
Or just use wchar_t and it will work correctly, I assume.
--
/Jacob Carlborg
On 2013-03-21 15:35, Jens Mueller wrote:
My bad. The sentence does not belong there. It belongs to Tag the
library version. Though I'm not sure how to do this yet.
Will fix. Thanks.
Perhaps we could create list that maps C defines to D versions. Example,
for Mac OS X the __APPLE__ define is
Jacob Carlborg wrote:
On 2013-03-21 15:35, Jens Mueller wrote:
My bad. The sentence does not belong there. It belongs to Tag the
library version. Though I'm not sure how to do this yet.
Will fix. Thanks.
Perhaps we could create list that maps C defines to D versions.
Example, for Mac OS
On 03/21/2013 10:25 AM, Jacob Carlborg wrote:
On 2013-03-21 14:53, 1100110 wrote:
That does sound vaguely familiar...
Yes, it's size is 16 on Windows and 32 on Linux and OSX.
My bad, dchar then. (with wchar for Windows)
Or just use wchar_t and it will work correctly, I assume.
Ok, you
On Thu, Mar 21, 2013 at 12:08:00PM +0100, Vladimir Panteleev wrote:
On Wednesday, 20 March 2013 at 22:46:58 UTC, Lars T. Kyllingstad
wrote:
Sorry for the delay, but I've pushed a new version now. There are
still a few things I haven't done wrt. documentation* and
unittests**, but the changes
21-Mar-2013 09:01, Kagamin пишет:
On Wednesday, 20 March 2013 at 14:34:21 UTC, Nick Sabalausky wrote:
Since *at least* as far back as XP, Windows has handled \n newlines
perfectly fine. The command line displays them properly, .BAT scripts
handle them properly, every code editor in existence
On 03/21/2013 11:35 AM, H. S. Teoh wrote:
On Thu, Mar 21, 2013 at 12:08:00PM +0100, Vladimir Panteleev wrote:
On Wednesday, 20 March 2013 at 22:46:58 UTC, Lars T. Kyllingstad
wrote:
Sorry for the delay, but I've pushed a new version now. There are
still a few things I haven't done wrt.
Suppose you create a range: struct MyRange{...}
Now you have to unittest it. And there's a lot of ways a range
implementation can go wrong. There's a fair amount of things to test.
And they all, ideally, need to be done for *every* range type created.
But, ranges are all supposed to conform to a
On Thursday, March 21, 2013 13:08:58 Nick Sabalausky wrote:
Suppose you create a range: struct MyRange{...}
Now you have to unittest it. And there's a lot of ways a range
implementation can go wrong. There's a fair amount of things to test.
And they all, ideally, need to be done for *every*
On Thursday, 21 March 2013 at 16:37:38 UTC, H. S. Teoh wrote:
On Thu, Mar 21, 2013 at 12:08:00PM +0100, Vladimir Panteleev
wrote:
Since (IIRC) all issues regarding incompatibility with
std.process
have been resolved, how about renaming the module to
std.process?
This way it'll also be easier
On 2013-03-21 16:40, Jens Mueller wrote:
That would be very helpful. But these are not portable in C, right?
Anyway I should add a link to D versioning and some example.
No, they are vendor and platform specific. But they are reliable.
--
/Jacob Carlborg
On Thu, Mar 21, 2013 at 06:32:59PM +0100, Lars T. Kyllingstad wrote:
On Thursday, 21 March 2013 at 16:37:38 UTC, H. S. Teoh wrote:
On Thu, Mar 21, 2013 at 12:08:00PM +0100, Vladimir Panteleev
wrote:
Since (IIRC) all issues regarding incompatibility with std.process
have been resolved, how
On Thu, 21 Mar 2013 13:29:35 -0400
Jonathan M Davis jmdavisp...@gmx.com wrote:
But I don't
know how you'd automate testing behavior when the exact behavior of
the range is very much dependent on the range itself.
I don't think that's true at all. Granted, you can't automate testing
of the
On Thu, 21 Mar 2013 13:48:54 -0400
Nick Sabalausky seewebsitetocontac...@semitwist.com wrote:
- Calling popFront doesn't throw unless range is empty.
- Calling popFront on an empty range throws a RangeError.
Actually, I'm not certain about those two, but I know
they're true if you just
21-Mar-2013 21:48, Nick Sabalausky пишет:
On Thu, 21 Mar 2013 13:29:35 -0400
Jonathan M Davis jmdavisp...@gmx.com wrote:
But I don't
know how you'd automate testing behavior when the exact behavior of
the range is very much dependent on the range itself.
I don't think that's true at all.
On Thu, Mar 21, 2013 at 01:48:54PM -0400, Nick Sabalausky wrote:
On Thu, 21 Mar 2013 13:29:35 -0400
Jonathan M Davis jmdavisp...@gmx.com wrote:
But I don't know how you'd automate testing behavior when the exact
behavior of the range is very much dependent on the range itself.
I don't
On Thursday, March 21, 2013 13:52:12 Nick Sabalausky wrote:
On Thu, 21 Mar 2013 13:48:54 -0400
Nick Sabalausky seewebsitetocontac...@semitwist.com wrote:
- Calling popFront doesn't throw unless range is empty.
- Calling popFront on an empty range throws a RangeError.
Actually, I'm not
On Thursday, March 21, 2013 13:48:54 Nick Sabalausky wrote:
On Thu, 21 Mar 2013 13:29:35 -0400
Jonathan M Davis jmdavisp...@gmx.com wrote:
But I don't
know how you'd automate testing behavior when the exact behavior of
the range is very much dependent on the range itself.
I don't
#!/usr/bin/rdmd
void main(string[] arg) {
// Observation: I'd like to say:
/*
auto r = myfunc.call(named) with { z= 2; x = -123; y = 200; }
*/
// and have it turned into this:
with(myfunc) { x = -123; y = 200; z = -20; }
auto r = myfunc.call(named);
// Q: is there some way to
// CORRECTION:
// and have it turned into this:
with(myfunc) { z =2; x = -123; y = 200; }
auto r = myfunc.call(named);
On Thu, 21 Mar 2013 11:04:31 -0700
H. S. Teoh hst...@quickfur.ath.cx wrote:
- Calling popFront and then front returns the next element.
How do you know if something is the next element? What if the range
is repeat(1)?
- If range has length, then 'empty' returns true IFF popFront has
On Thursday, 21 March 2013 at 18:19:00 UTC, Jonathan M Davis
wrote:
I could definitely see an argument for adopting the
policy of having popFront throw RangeError when the range is
empty.
- Jonathan M Davis
In release mode, assert expressions are removed. This would not
be possible for
On Thursday, 21 March 2013 at 17:29:46 UTC, Jonathan M Davis
wrote:
Hmmm. I've been working on stuff which makes creating ranges to
test range-
based functions easier, but I've never thought about creating
something to
test conformance.
- Jonathan M Davis
One of the things I've been trying
On Thu, Mar 21, 2013 at 07:52:32PM +0100, monarch_dodra wrote:
On Thursday, 21 March 2013 at 17:29:46 UTC, Jonathan M Davis wrote:
Hmmm. I've been working on stuff which makes creating ranges to
test range-
based functions easier, but I've never thought about creating
something to
test
/* Similarly but different (here I am instantiating a new
struct
before the call, rather than re-using a global single
struct each time),
it would be lovely and elegant to say:
*/
void main(string[] arg) {
/* Elegant:
auto r = myfunc() with { z= 2; x = -123; y = 200;
- Upon instantiating a new random access range, 'r.front == r[0]', and
then after 'r.popFront()', 'r.front == r[1]', etc.
This should be relatively easy to check.
Is that really the behaviour for RA ranges? I'd say that after calling
r.popFront(), then r.front == r[0].
The test could be:
On 2013-03-21 19:35, J wrote:
Here's another workaround:
https://github.com/jacob-carlborg/mambo/blob/master/mambo/util/Reflection.d#L135
--
/Jacob Carlborg
The code below works fine without optimizations. But with optimizations
(the -O flag) turned on it segfaults. The behavior with optimizations
turned on is a bit different depending on which version of DMD I try and
if I compile for 32 or 64bit.
DMD 2.062 64bit: Segfault
DMD 2.062 32bit:
Jacob Carlborg:
Here's another workaround:
https://github.com/jacob-carlborg/mambo/blob/master/mambo/util/Reflection.d#L135
Maybe such two links should go in one page of the D wiki about
lack of named parameters workarounds.
Eventually D should introduce a syntax for named arguments at the
void testForwardRange(R, E)(R range, E[] content)
{
// Deliberately not contraints, because this *is* a test,
after all.
// *Or* maybe it just auto-detects range type and leaves it
// up to the user to check for isForwardRange!R or
whatever.
static assert(isForwardRange!R);
On Thursday, 21 March 2013 at 19:59:01 UTC, Jacob Carlborg wrote:
On 2013-03-21 19:35, J wrote:
Here's another workaround:
https://github.com/jacob-carlborg/mambo/blob/master/mambo/util/Reflection.d#L135
Intriguing, Jacob! I could learn alot about reflection by
studying your code.
How is
On Thu, 21 Mar 2013 20:24:40 +0100
Philippe Sigaud philippe.sig...@gmail.com wrote:
- Upon instantiating a new random access range, 'r.front == r[0]',
and then after 'r.popFront()', 'r.front == r[1]', etc.
This should be relatively easy to check.
Is that really the behaviour for RA
On Thu, 21 Mar 2013 21:41:52 +0100
jerro a...@a.com wrote:
void testForwardRange(R, E)(R range, E[] content)
{
// Deliberately not contraints, because this *is* a test,
after all.
// *Or* maybe it just auto-detects range type and leaves it
// up to the user to check for
On 2013-03-21 21:33, bearophile wrote:
Maybe such two links should go in one page of the D wiki about lack of
named parameters workarounds.
Eventually D should introduce a syntax for named arguments at the call
point plus a syntax to deprecate argument names. It's not the most
important thing
On 2013-03-21 21:42, J wrote:
Intriguing, Jacob! I could learn alot about reflection by studying your
code.
How is it installed? I installing by downloading that single file, and
with a quick hack to the Reflection.d top three lines (commenting out
the module and imports at the top), I tried
UFCS, plus some tweaks to the standard library like this one
(http://d.puremagic.com/issues/show_bug.cgi?id=8755 ) help write
D code in a more functional (flow programming, Walter calls it
component programming) style.
So tuples become more and more useful, and the lack of a syntax
to unpack
Jacob Carlborg:
What do you think about my suggestion for anonymous structs as
named parameters?
You show code like:
void foo ({ int x, int y } point)
{
}
foo({ y: 5, x: 3 });
D already has two kinds of tuples so I don't want a third kind
of tuple. What I want is D to manage better the
My idea: http://dpaste.dzfl.pl/de19d31a
On 21 March 2013 20:29, Jacob Carlborg d...@me.com wrote:
The code below works fine without optimizations. But with optimizations
(the -O flag) turned on it segfaults. The behavior with optimizations
turned on is a bit different depending on which version of DMD I try and if
I compile for 32
On 21 March 2013 21:46, Iain Buclaw ibuc...@ubuntu.com wrote:
On 21 March 2013 20:29, Jacob Carlborg d...@me.com wrote:
The code below works fine without optimizations. But with optimizations
(the -O flag) turned on it segfaults. The behavior with optimizations
turned on is a bit different
On Wednesday, 27 February 2013 at 06:57:16 UTC, Russel Winder
wrote:
The summary is that D on the JVM is like C++ or C on the JVM, a
non-starter.
Interesting, can java into CTFE and compile-time code generation?
On 20.03.2013 15:34, Nick Sabalausky wrote:
Since *at least* as far back as XP, Windows has handled \n newlines
perfectly fine. The command line displays them properly, .BAT scripts
handle them properly, every code editor in existence handles them
properly. The *only* thing I've found that
Jens Mueller wrote:
Hi,
I wrote some guidelines for writing a Deimos interface. It's still very
rough but it's a start. I'd like to add it to dlang.org to give
contributors better guidance, ultimately hoping to see more
contributions to Deimos.
Besides comments to improve my poor phrasing
On Thu, 21 Mar 2013 23:37:06 +0100
torhu no@spam.invalid wrote:
You're mixing binary and text mode functions. read() is binary,
stdout.write() is text mode. And yes, you are asking for newlines to
be messed with, as File.write is documented to write in text mode.
But I agree that the
I would like to see tuple syntax and abilities improved. It's
been a while since I last tried to use them so I'm not prepared
to explain in detail what I'd like to see for improvements,
however I can say that when I did try to use them I remember they
were much more unwieldy to use and more
On 3/13/13, H. S. Teoh hst...@quickfur.ath.cx wrote:
If you don't want the hassle of hosting the docs on a webserver with
separate css stylesheets, etc., you could try the simple macros I wrote
for generating nicer-looking ddocs:
On Thursday, March 21, 2013 19:46:08 John Colvin wrote:
On Thursday, 21 March 2013 at 18:19:00 UTC, Jonathan M Davis
wrote:
I could definitely see an argument for adopting the
policy of having popFront throw RangeError when the range is
empty.
- Jonathan M Davis
In release mode,
On Thu, 21 Mar 2013 21:55:10 -0400
Jonathan M Davis jmdavisp...@gmx.com wrote:
Anything else would be a change that would
have to be discussed, so specifically testing that a conformant range
throws a RangeError from popFront when it's empty (as Nick was
suggesting) would not be correct at
On Fri, Mar 22, 2013 at 02:19:37AM +0100, Andrej Mitrovic wrote:
On 3/13/13, H. S. Teoh hst...@quickfur.ath.cx wrote:
If you don't want the hassle of hosting the docs on a webserver with
separate css stylesheets, etc., you could try the simple macros I
wrote for generating nicer-looking
On 3/22/13, H. S. Teoh hst...@quickfur.ath.cx wrote:
Andrei has already filed this some time ago:
http://d.puremagic.com/issues/show_bug.cgi?id=9379
Ah now I understand what that's about, thanks.
On 22.03.2013 00:36, Nick Sabalausky wrote:
On Thu, 21 Mar 2013 23:37:06 +0100
torhu no@spam.invalid wrote:
You're mixing binary and text mode functions. read() is binary,
stdout.write() is text mode. And yes, you are asking for newlines to
be messed with, as File.write is documented to
On 2013-03-21 04:37, Mike Parker wrote:
Because some time ago DMD started shipping with
'--export-dynamic' in the config file on Linux to (AFAIK)
facilitate generation of exception stack traces. I was using
straight function pointers at the time and, as a result, no one
could use Derelict on
On Friday, 15 March 2013 at 08:20:18 UTC, Namespace wrote:
So far, my lexer is pure exercise.
But my goal is actually to filter variables and functions, to
see if they are ever used in the code.
I'm almost finished. In my few tests, my little parser detects
function, struct and variable
On Wednesday, 2 May 2012 at 15:27:58 UTC, Jabb wrote:
import std.algorithm;
void main() {
uint[string] counts = [ a:4, b:5, c:3, d:1 ];
string[] keys = counts.keys;
sort!((a, b) { return counts[a] counts[b]; })(keys);
}
Did you try
string[] keys = counts.keys.dup;
?
I have an enum, say:
enum AssetCategory {
Investment,
PrimaryResidence,
FamilyProperty,
FinancialInstrument
}
and I have functions that convert to/from strings to be used in
Json (via vibe json). The vibe wants to call out to user supplied
toJson/fromJson if both functions are
On 3/20/13, Andrej Mitrovic andrej.mitrov...@gmail.com wrote:
It seems to be COM-based, so it should be usable from D.
Apparently there aren't any. Anyway I've ported the basic Core Audio
sample to D, which has a slider for the main volume and a mute button:
On 03/21/2013 01:34 PM, Dan wrote:
Json serializeToJson(T)(T value) {
...
static if( __traits(compiles, value = T.fromJson(value.toJson())) ){
It looks like fromJson must be a static member function because the
condition is written in a way that fromJson is called on the type
itself. (I
On 03/21/2013 01:02 PM, Stefan wrote:
On Wednesday, 2 May 2012 at 15:27:58 UTC, Jabb wrote:
import std.algorithm;
void main() {
uint[string] counts = [ a:4, b:5, c:3, d:1 ];
string[] keys = counts.keys;
sort!((a, b) { return counts[a] counts[b]; })(keys);
}
Did you try
string[] keys
On 05/02/2012 08:27 AM, Jabb wrote:
Alone this works just fine. But if I add another file called myalgs.d,
and put the following in it:
//--
module myalgs;
import std.algorithm;
//--
Then I get the following exception:
object.Error: Access Violation
I
http://d.puremagic.com/issues/show_bug.cgi?id=9771
Summary: Remove toHash from Object
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P2
Component: druntime
http://d.puremagic.com/issues/show_bug.cgi?id=9772
Summary: Remove toString from Object
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P2
Component:
http://d.puremagic.com/issues/show_bug.cgi?id=9770
Summary: Remove opCmp from Object
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P2
Component: druntime
http://d.puremagic.com/issues/show_bug.cgi?id=9769
--- Comment #1 from Jonathan M Davis jmdavisp...@gmx.com 2013-03-21 00:05:46
PDT ---
Related:
opCmp: issue# 9770
toHash: issue# 9771
toString: issue# 9772
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
---
http://d.puremagic.com/issues/show_bug.cgi?id=9770
--- Comment #1 from Jonathan M Davis jmdavisp...@gmx.com 2013-03-21 00:05:48
PDT ---
Related:
opEquals: issue# 9769
toHash: issue# 9771
toString: issue# 9772
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
http://d.puremagic.com/issues/show_bug.cgi?id=9771
--- Comment #1 from Jonathan M Davis jmdavisp...@gmx.com 2013-03-21 00:05:52
PDT ---
Related:
opEquals: issue# 9769
opCmp: issue# 9770
toString: issue# 9772
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
http://d.puremagic.com/issues/show_bug.cgi?id=9772
--- Comment #1 from Jonathan M Davis jmdavisp...@gmx.com 2013-03-21 00:05:55
PDT ---
Related:
opEquals: issue# 9769
opCmp: issue# 9770
toHash: issue# 9771
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
---
http://d.puremagic.com/issues/show_bug.cgi?id=9769
Jacob Carlborg d...@me.com changed:
What|Removed |Added
CC||d...@me.com
--- Comment
http://d.puremagic.com/issues/show_bug.cgi?id=9769
--- Comment #3 from Jonathan M Davis jmdavisp...@gmx.com 2013-03-21 00:42:37
PDT ---
https://github.com/D-Programming-Language/druntime/pull/459
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are
http://d.puremagic.com/issues/show_bug.cgi?id=9769
--- Comment #4 from Jonathan M Davis jmdavisp...@gmx.com 2013-03-21 00:45:19
PDT ---
Was there a conclusion on how this will affect backwards compatible?
No, other than the fact that we'd probably have to keep the functions on
opEquals for a
http://d.puremagic.com/issues/show_bug.cgi?id=9773
Summary: ref parameter with default value should not compile
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
1 - 100 of 141 matches
Mail list logo