On Wednesday, 9 September 2015 at 20:19:44 UTC, Daniel N wrote:
For the record, I think D made the right decision... omitting
friends.
However there's one case in particular which I find useful,
anyone see a good workaround for this?
#include
class Friendly
{
private:
int val;
On Tuesday, 16 June 2015 at 09:33:22 UTC, Dennis Ritchie wrote:
Hi,
I can write this:
import std.range : chain, split;
But I can not write this:
import std.range : chain, split, std.algorithm : map, each;
We have several times to write the word `import`:
import std.range : chain, split;
On Monday, 8 June 2015 at 20:36:10 UTC, Yuxuan Shui wrote:
Is there any reasons/difficulties for not implementing named
parameters?
There is clearly a need:
http://forum.dlang.org/thread/wokfqqbexazcguffw...@forum.dlang.org#post-pxndhoskpjxvnoacajaz:40forum.dlang.org
On Sunday, 24 May 2015 at 11:07:19 UTC, Dennis Ritchie wrote:
On Sunday, 24 May 2015 at 02:43:47 UTC, Idan Arye wrote:
I'm a fan of lisp(Clojure being my favorite. Too bad it takes
about a century just to load the runtime...), and yet I find
it quite ironic that Paul Graham claims lisp to be
On Sunday, 24 May 2015 at 15:40:21 UTC, Dennis Ritchie wrote:
On Sunday, 24 May 2015 at 14:15:55 UTC, Idan Arye wrote:
This IS ironic, because Paul Graham claims lisp to be the most
powerful, but if he have ever encounter a more powerful
language he couldn't accept it is more powerful than
On Saturday, 23 May 2015 at 22:01:42 UTC, Dennis Ritchie wrote:
You may find it nonsense, but Paul Graham says that each
language has its own power. He believes that Lisp is the most
powerful language, and programmers who write in other
languages, he said Blub programmers. Learn more about The
On Friday, 15 May 2015 at 03:47:46 UTC, rcorre wrote:
On Friday, 15 May 2015 at 03:22:43 UTC, rcorre wrote:
On Thursday, 14 May 2015 at 14:57:26 UTC, Idan Arye wrote:
How about a more flexible solution?
http://dpaste.dzfl.pl/2f99cc270651
Neat, thanks!
The range I don't pick may be an
On Thursday, 14 May 2015 at 12:40:57 UTC, rcorre wrote:
So I thought this might work:
struct MaybeEmpty(R) if (isInputRange!R) {
private bool _isEmpty;
private R_input;
alias _input this;
this(bool isEmpty, R input) {
_input = input;
_isEmpty = isEmpty;
}
@property
On Monday, 11 May 2015 at 22:46:00 UTC, Per Nordlöw wrote:
The pattern
final switch (_index)
{
import std.range: empty, front;
foreach (i, R; Rs)
{
case i:
On Friday, 1 May 2015 at 17:45:02 UTC, bitwise wrote:
On Friday, 1 May 2015 at 02:35:52 UTC, Idan Arye wrote:
On Thursday, 30 April 2015 at 23:27:49 UTC, bitwise wrote:
Well, the third thing was just my reasoning for asking in the
first place. I need to be able to acquire/release shared
On Thursday, 30 April 2015 at 23:27:49 UTC, bitwise wrote:
Well, the third thing was just my reasoning for asking in the
first place. I need to be able to acquire/release shared
resources reliably, like an OpenGL texture, for example.
If you want to release resources, you are going to have to
On Thursday, 30 April 2015 at 21:01:36 UTC, Vlad Levenfeld wrote:
I was wondering if there's a mechanism to make anonymous
templates, e.g.
given:
enum Policy {A, B}
alias List = TypeTuple!(...);
instead of this:
enum has_policy_A (T) = T.policy == Policy.A;
alias Result =
On Tuesday, 28 April 2015 at 11:03:09 UTC, bearophile wrote:
Gary Willoughby:
I wondered if it was possible to write a classic fizzbuzz[1]
example using a UFCS chain? I've tried and failed.
Is this OK?
void main() {
import std.stdio, std.algorithm, std.range, std.conv,
std.functional;
On Tuesday, 21 April 2015 at 13:53:15 UTC, Dicebot wrote:
On Tuesday, 21 April 2015 at 13:27:48 UTC, Marc Schütz wrote:
On Monday, 20 April 2015 at 20:22:40 UTC, Jonathan M Davis
wrote:
There may be languages out there which take the the return
type into account
when overloading, but I've
On Sunday, 12 April 2015 at 11:49:19 UTC, Baz wrote:
Hi,
while variable declarations work in list:
uint a,b,c;
function parameters declarations don't:
void foo(uint a,b,c);
Because of this, function declarations are sometimes super-wide.
(despite of the fact that:
On Tuesday, 17 March 2015 at 10:07:19 UTC, Kagamin wrote:
On Monday, 16 March 2015 at 13:24:28 UTC, Idan Arye wrote:
I don't think the problem is the lack of pattern matching. I
think the problem is that by forcing the query syntax into
lambda expression syntax, you obfuscate the syntax tree
On Monday, 16 March 2015 at 12:18:42 UTC, Ellery Newcomer wrote:
On Sunday, 15 March 2015 at 14:58:54 UTC, Idan Arye wrote:
Even if we can't get the lambdas as syntax tress, the fact
that we can send whatever types we want to the delegates and
overload operators and stuff means we can still
On Sunday, 15 March 2015 at 00:56:24 UTC, Ellery Newcomer wrote:
On Saturday, 14 March 2015 at 23:57:33 UTC, weaselcat wrote:
On Saturday, 14 March 2015 at 23:46:28 UTC, Ellery Newcomer
wrote:
And C# has LINQ, which when combined with the last point is
fricken awesome.
what does LINQ offer
On Saturday, 14 March 2015 at 09:59:05 UTC, dnewer wrote:
yes,java is good lang,but i dont think it's better than c#,if
no oracle or google support java will less and less.
C# is a good and easy lang.
i like C# .
but,C# cant compiled to native code.
So far, I have been searching for a
On Tuesday, 6 January 2015 at 16:30:14 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Tue, Jan 06, 2015 at 04:18:17PM +, Idan Arye via
Digitalmars-d-learn wrote:
I have an associative array, and I use the `in` operator to
get a
reference to a value inside it and store it in a pointer
I have an associative array, and I use the `in` operator to get a
reference to a value inside it and store it in a pointer:
int[string] aa;
aa[myKey] = 42;
int* myPointer = myKey in aa;
Is it possible that due to rehashing or something D will decide
to move the associative array's
If I have an associative array and I only modify it's values,
without changing the keys, can I assume that the order won't
change?
On Thursday, 1 January 2015 at 13:39:57 UTC, Peter Alexander
wrote:
On Thursday, 1 January 2015 at 13:13:10 UTC, Andrej Mitrovic
via Digitalmars-d-learn wrote:
On 1/1/15, Idan Arye via Digitalmars-d-learn
digitalmars-d-learn@puremagic.com wrote:
If I have an associative array and I only modify
On Sunday, 28 September 2014 at 19:32:11 UTC, Jay wrote:
thanks! but i'm still interested *why* you can't have this with
'new'. if there's no good reason i will file a bug report.
Because `new` is not a function - it's an operator.
On Monday, 25 August 2014 at 02:04:43 UTC, Aerolite wrote:
On Monday, 25 August 2014 at 01:34:14 UTC, Idan Arye wrote:
On Monday, 25 August 2014 at 01:10:32 UTC, Aerolite wrote:
-- No syntax modification (unless you want the feature to be
optional)
If this ever gets into the core language,
On Monday, 25 August 2014 at 10:02:41 UTC, Aerolite wrote:
On Monday, 25 August 2014 at 07:36:22 UTC, Idan Arye wrote:
If multi-dispatching is done at compile-time, it can't rely on
the object's runtime type - only on the static type of the
reference that holds it. This is no different than
On Monday, 25 August 2014 at 00:08:25 UTC, Jonathan M Davis wrote:
On Sunday, 24 August 2014 at 23:42:51 UTC, Aerolite wrote:
Hey all,
I was surprised to learn yesterday that D does not actually
support Multiple-Dispatch, also known as Multimethods. Why is
this? Support for this feature is
On Monday, 25 August 2014 at 00:36:40 UTC, Vladimir Panteleev
wrote:
On Monday, 25 August 2014 at 00:20:26 UTC, Vladimir Panteleev
wrote:
dynamic!ReactSpecialization(me, other);
Here's a very basic implementation:
http://dpaste.dzfl.pl/5150ca9c13f4
Idan Arye is also working on functional
On Monday, 25 August 2014 at 01:10:32 UTC, Aerolite wrote:
-- No syntax modification (unless you want the feature to be
optional)
If this ever gets into the core language, it absolutely must be
optional! Think of the implications of having this as the default
and only behavior:
* Every
On Thursday, 21 August 2014 at 23:05:48 UTC, Ali Çehreli wrote:
I don't think it is a concern as JSON does not encode types. It
is up to the receiver how to interpret the data. Here is the
output of the program above:
{value:1.234567889998901}
Ali
JSON may not encode the very specific
On Monday, 18 August 2014 at 21:17:11 UTC, Jonathan M Davis wrote:
On Monday, 18 August 2014 at 21:02:09 UTC, Gary Willoughby
wrote:
In the new D release there have been some changes regarding
built-in types.
http://dlang.org/changelog.html?2.066#array_and_aa_changes
I would like to learn
On Tuesday, 19 August 2014 at 00:54:25 UTC, Idan Arye wrote:
On Monday, 18 August 2014 at 21:17:11 UTC, Jonathan M Davis
wrote:
On Monday, 18 August 2014 at 21:02:09 UTC, Gary Willoughby
wrote:
In the new D release there have been some changes regarding
built-in types.
On Thursday, 7 August 2014 at 17:46:13 UTC, nikki wrote:
I want to learn SDL2 and learn D at the same time, for the SDL2
part autocompletion would be very nice.
I've found DCD but can't get it working (not finding symbols or
declarations) at the moment but I was wondering if there are
any
33 matches
Mail list logo