Jump to page: 1 2
Thread overview
Idiomatic D?
Jan 30, 2014
Tofu Ninja
Jan 30, 2014
Dicebot
Jan 30, 2014
Tofu Ninja
Jan 31, 2014
Meta
Jan 31, 2014
Stanislav Blinov
Jan 31, 2014
Meta
Jan 31, 2014
Stanislav Blinov
Jan 31, 2014
Meta
Jan 31, 2014
Matt Soucy
Jan 31, 2014
Stanislav Blinov
Jan 31, 2014
qznc
Jan 31, 2014
Dicebot
Jan 31, 2014
Kelet
January 30, 2014
I hear it thrown around a lot but what does it actually mean? What does the ideal D code look like? What kind of things should some one think about if they are trying to do idiomatic D?
January 30, 2014
On Thursday, 30 January 2014 at 20:05:11 UTC, Tofu Ninja wrote:
> I hear it thrown around a lot but what does it actually mean? What does the ideal D code look like? What kind of things should some one think about if they are trying to do idiomatic D?

There is no "official" idiomatic style like, for example, in python. When I speak about idiomatic D I usually think about style Phobos is written in (omitting legacy modules) as it is the code that gets most attention from most experienced D developers.
January 30, 2014
On Thursday, 30 January 2014 at 20:10:01 UTC, Dicebot wrote:
> On Thursday, 30 January 2014 at 20:05:11 UTC, Tofu Ninja wrote:
>> I hear it thrown around a lot but what does it actually mean? What does the ideal D code look like? What kind of things should some one think about if they are trying to do idiomatic D?
>
> There is no "official" idiomatic style like, for example, in python. When I speak about idiomatic D I usually think about style Phobos is written in (omitting legacy modules) as it is the code that gets most attention from most experienced D developers.

Got any tips?
January 31, 2014
On Thursday, 30 January 2014 at 22:40:24 UTC, Tofu Ninja wrote:
> On Thursday, 30 January 2014 at 20:10:01 UTC, Dicebot wrote:
>> On Thursday, 30 January 2014 at 20:05:11 UTC, Tofu Ninja wrote:
>>> I hear it thrown around a lot but what does it actually mean? What does the ideal D code look like? What kind of things should some one think about if they are trying to do idiomatic D?
>>
>> There is no "official" idiomatic style like, for example, in python. When I speak about idiomatic D I usually think about style Phobos is written in (omitting legacy modules) as it is the code that gets most attention from most experienced D developers.
>
> Got any tips?

Ranges, templates and structs.
January 31, 2014
On Friday, 31 January 2014 at 00:08:02 UTC, Meta wrote:
> On Thursday, 30 January 2014 at 22:40:24 UTC, Tofu Ninja wrote:

>> Got any tips?
>
> Ranges, templates and structs.

~= CTFE ~ UFCS
January 31, 2014
On Friday, 31 January 2014 at 00:09:34 UTC, Stanislav Blinov wrote:
> On Friday, 31 January 2014 at 00:08:02 UTC, Meta wrote:
>> On Thursday, 30 January 2014 at 22:40:24 UTC, Tofu Ninja wrote:
>
>>> Got any tips?
>>
>> Ranges, templates and structs.
>
> ~= CTFE ~ UFCS

~= std.algorithm ~ std.range
January 31, 2014
On Friday, 31 January 2014 at 00:13:02 UTC, Meta wrote:

>>>
>>> Ranges, templates and structs.
>>
>> ~= CTFE ~ UFCS
>
> ~= std.algorithm ~ std.range

~= immutable ~ (isProperlyImplemented!shared ? shared : repeatedlyAskAndreiWhatsGoingOnWith!shared
January 31, 2014
On Friday, 31 January 2014 at 00:17:47 UTC, Stanislav Blinov wrote:
> On Friday, 31 January 2014 at 00:13:02 UTC, Meta wrote:
>
>>>>
>>>> Ranges, templates and structs.
>>>
>>> ~= CTFE ~ UFCS
>>
>> ~= std.algorithm ~ std.range
>
> ~= immutable ~ (isProperlyImplemented!shared ? shared : repeatedlyAskAndreiWhatsGoingOnWith!shared

Repeat these steps until you have a beautiful, elegant solution, or ten pages of compiler errors because a template constraint failed somewhere down the line.
January 31, 2014
On 01/30/2014 07:17 PM, Stanislav Blinov wrote:
> On Friday, 31 January 2014 at 00:13:02 UTC, Meta wrote:
>
>>>>
>>>> Ranges, templates and structs.
>>>
>>> ~= CTFE ~ UFCS
>>
>> ~= std.algorithm ~ std.range
>
> ~= immutable ~ (isProperlyImplemented!shared ? shared :
> repeatedlyAskAndreiWhatsGoingOnWith!shared

);

// Sorry but that was going to cause a slight error.

-- 
Matt Soucy
http://msoucy.me/
January 31, 2014
On Thursday, 30 January 2014 at 20:05:11 UTC, Tofu Ninja wrote:
> I hear it thrown around a lot but what does it actually mean? What does the ideal D code look like? What kind of things should some one think about if they are trying to do idiomatic D?

Here is one of the few previous threads on the topic:
http://forum.dlang.org/thread/awutlttzvqaawkrjnfqe@forum.dlang.org
« First   ‹ Prev
1 2