Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-07 Thread Kagamin via Digitalmars-d
On Friday, 6 June 2014 at 13:04:24 UTC, Jonathan M Davis via Digitalmars-d wrote: I've never understood why my employer's IT department insists on blocking _outgoing_ ports. Blocking outgoing SMPT is a good and easy practice to block spam.

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-07 Thread Jonathan M Davis via Digitalmars-d
On Sat, 07 Jun 2014 20:24:39 + Kagamin via Digitalmars-d digitalmars-d@puremagic.com wrote: On Friday, 6 June 2014 at 13:04:24 UTC, Jonathan M Davis via Digitalmars-d wrote: I've never understood why my employer's IT department insists on blocking _outgoing_ ports. Blocking outgoing

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-07 Thread Kagamin via Digitalmars-d
Of course sending spam is worse than receiving. You can try secure SMTP, if your server supports it. AFAIK, it was a solution to spam problem, so it shouldn't be blocked.

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-07 Thread Kagamin via Digitalmars-d
Or better - some mail servers provide additional smtp port, which handles only authenticated client-server smtp, it shouldn't be blocked either (spamers use unauthenticated server-server smtp).

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-07 Thread Jonathan M Davis via Digitalmars-d
On Sat, 07 Jun 2014 21:07:49 + Kagamin via Digitalmars-d digitalmars-d@puremagic.com wrote: Of course sending spam is worse than receiving. If you say so. I don't know why you'd really care beyond the fact that it's rude. Concern about getting blocked by other SMTP servers? You can try

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Dicebot via Digitalmars-d
On Friday, 6 June 2014 at 00:34:19 UTC, Jonathan M Davis via Digitalmars-d wrote: And like with them, it's impossible to use ref for this, because you can't use ref with variadic template arguments. Wait what? void foo(T...)(ref T args) { args[0] = 42; } void main() { int x;

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Kagamin via Digitalmars-d
It happens regularly with posts going through mailman.

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread monarch_dodra via Digitalmars-d
On Friday, 6 June 2014 at 08:58:44 UTC, Kagamin wrote: It happens regularly with posts going through mailman. It happens sometimes. Jonathan's post have been doing it *every time* in the last couple of days...

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Jonathan M Davis via Digitalmars-d
On Fri, 06 Jun 2014 08:14:13 + Dicebot via Digitalmars-d digitalmars-d@puremagic.com wrote: On Friday, 6 June 2014 at 00:34:19 UTC, Jonathan M Davis via Digitalmars-d wrote: And like with them, it's impossible to use ref for this, because you can't use ref with variadic template

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Jonathan M Davis via Digitalmars-d
On Fri, 06 Jun 2014 09:21:56 + monarch_dodra via Digitalmars-d digitalmars-d@puremagic.com wrote: On Friday, 6 June 2014 at 08:58:44 UTC, Kagamin wrote: It happens regularly with posts going through mailman. It happens sometimes. Jonathan's post have been doing it *every time* in the

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread monarch_dodra via Digitalmars-d
On Friday, 6 June 2014 at 09:35:56 UTC, Jonathan M Davis via Digitalmars-d wrote: On Fri, 06 Jun 2014 08:14:13 + Dicebot via Digitalmars-d digitalmars-d@puremagic.com wrote: On Friday, 6 June 2014 at 00:34:19 UTC, Jonathan M Davis via Digitalmars-d wrote: And like with them, it's

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Dicebot via Digitalmars-d
On Friday, 6 June 2014 at 10:35:58 UTC, monarch_dodra wrote: On Friday, 6 June 2014 at 09:35:56 UTC, Jonathan M Davis via Digitalmars-d wrote: On Fri, 06 Jun 2014 08:14:13 + Dicebot via Digitalmars-d digitalmars-d@puremagic.com wrote: On Friday, 6 June 2014 at 00:34:19 UTC, Jonathan M

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Steven Schveighoffer via Digitalmars-d
On Thu, 05 Jun 2014 18:42:29 -0400, Brad Anderson e...@gnuk.net wrote: On Thursday, 5 June 2014 at 22:06:02 UTC, monarch_dodra wrote: On Thursday, 5 June 2014 at 08:49:18 UTC, Jonathan M Davis via Digitalmars-d long days; int seconds; short msecs; d.split!(days, seconds,

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Wyatt via Digitalmars-d
On Friday, 6 June 2014 at 09:47:24 UTC, Jonathan M Davis via Digitalmars-d wrote: I may have to stop posting from work for the time being. :| I understand it may not be ideal from the perspective of your usual NG workflow, but maybe the forum interface could offer some relief? -Wyatt

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Byron Heads via Digitalmars-d
On Thu, 05 Jun 2014 21:00:39 +0200, Jonathan M Davis via Digitalmars-d wrote: It's a common idiom in core.time and std.datetime to use strings to represent units when you need to give the units as template arguments. If it hade't been strings, it would have been an enum (otherwise, they would

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Jonathan M Davis via Digitalmars-d
On Fri, 06 Jun 2014 12:49:42 + Wyatt via Digitalmars-d digitalmars-d@puremagic.com wrote: On Friday, 6 June 2014 at 09:47:24 UTC, Jonathan M Davis via Digitalmars-d wrote: I may have to stop posting from work for the time being. :| I understand it may not be ideal from the

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-06 Thread Wyatt via Digitalmars-d
On Friday, 6 June 2014 at 13:04:24 UTC, Jonathan M Davis via Digitalmars-d wrote: It took us ages to get them to even open the outbound ssh port. Oh? This is promising. Sounds like it's time to set up a reverse SSH tunnel! ...Not that I have all sort of experience with these because of

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Jonathan M Davis via Digitalmars-d
On Wed, 04 Jun 2014 09:12:06 +0200 Sönke Ludwig via Digitalmars-d digitalmars-d@puremagic.com wrote: Just a minor note: What about just .only!minutes, analogous .total!minutes? Removing both the .minutes shortcut and the short get method, pretty heavily increases verbosity, so shortening

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread H. S. Teoh via Digitalmars-d
On Thu, Jun 05, 2014 at 01:23:47AM -0700, Jonathan M Davis via Digitalmars-d wrote: On Wed, 04 Jun 2014 09:12:06 +0200 Sönke Ludwig via Digitalmars-d digitalmars-d@puremagic.com wrote: Just a minor note: What about just .only!minutes, analogous .total!minutes? Removing both the .minutes

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Byron Heads via Digitalmars-d
On Thu, 05 Jun 2014 07:18:59 -0700, H. S. Teoh via Digitalmars-d wrote: On Thu, Jun 05, 2014 at 01:23:47AM -0700, Jonathan M Davis via Digitalmars-d wrote: { auto d = dur!days(12) + dur!minutes(7) + dur!usecs(501223); long days; int seconds; short msecs;

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Chris Cain via Digitalmars-d
On Wednesday, 4 June 2014 at 15:51:58 UTC, John Colvin wrote: On Wednesday, 4 June 2014 at 14:16:31 UTC, Meta wrote: On Wednesday, 4 June 2014 at 11:28:52 UTC, Kagamin wrote: Does one really needs only one component, but not the others? Maybe it should provide full computed broken form instead

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Jonathan M Davis via Digitalmars-d
On Thu, 5 Jun 2014 14:35:16 + (UTC) Byron Heads via Digitalmars-d digitalmars-d@puremagic.com wrote: On Thu, 05 Jun 2014 07:18:59 -0700, H. S. Teoh via Digitalmars-d wrote: On Thu, Jun 05, 2014 at 01:23:47AM -0700, Jonathan M Davis via Digitalmars-d wrote: { auto d =

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Artur Skawina via Digitalmars-d
On 06/05/14 16:18, H. S. Teoh via Digitalmars-d wrote: On Thu, Jun 05, 2014 at 01:23:47AM -0700, Jonathan M Davis via Digitalmars-d wrote: Actually, after some further discussion, I think that we've decided to remove get/getOnly entirely. Instead, we'll have a function called split which

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread monarch_dodra via Digitalmars-d
On Thursday, 5 June 2014 at 08:49:18 UTC, Jonathan M Davis via Digitalmars-d long days; int seconds; short msecs; d.split!(days, seconds, msecs)(days, seconds, msecs); Please don't use pass-by-pointer in D APIs. It makes it a real *nightmare* to ever use the code in a safe

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Steven Schveighoffer via Digitalmars-d
On Thu, 05 Jun 2014 18:06:01 -0400, monarch_dodra monarchdo...@gmail.com wrote: On Thursday, 5 June 2014 at 08:49:18 UTC, Jonathan M Davis via Digitalmars-d long days; int seconds; short msecs; d.split!(days, seconds, msecs)(days, seconds, msecs); Please don't use

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Steven Schveighoffer via Digitalmars-d
On Thu, 05 Jun 2014 17:54:49 -0400, Artur Skawina via Digitalmars-d digitalmars-d@puremagic.com wrote: On 06/05/14 16:18, H. S. Teoh via Digitalmars-d wrote: On Thu, Jun 05, 2014 at 01:23:47AM -0700, Jonathan M Davis via Digitalmars-d wrote: Actually, after some further discussion, I think

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Brad Anderson via Digitalmars-d
On Thursday, 5 June 2014 at 22:06:02 UTC, monarch_dodra wrote: On Thursday, 5 June 2014 at 08:49:18 UTC, Jonathan M Davis via Digitalmars-d long days; int seconds; short msecs; d.split!(days, seconds, msecs)(days, seconds, msecs); Please don't use pass-by-pointer in D APIs. It

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Artur Skawina via Digitalmars-d
On 06/06/14 00:15, Steven Schveighoffer via Digitalmars-d wrote: On Thu, 05 Jun 2014 17:54:49 -0400, Artur Skawina via Digitalmars-d digitalmars-d@puremagic.com wrote: I'd say it is very C-ish and very unidiomatic. Why? Well, compare with: struct D { // In real code these methods

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Jonathan M Davis via Digitalmars-d
On Thu, 05 Jun 2014 23:54:49 +0200 Artur Skawina via Digitalmars-d digitalmars-d@puremagic.com wrote: I'm just saying that encouraging that kind of return-by-weakly-typed-pointers-with-string-selectors interfaces is /not/ a good idea; there are other, much better, options in D. There's no

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Jonathan M Davis via Digitalmars-d
On Thu, 05 Jun 2014 18:18:33 -0400 Steven Schveighoffer via Digitalmars-d digitalmars-d@puremagic.com wrote: On Thu, 05 Jun 2014 18:06:01 -0400, monarch_dodra monarchdo...@gmail.com wrote: On Thursday, 5 June 2014 at 08:49:18 UTC, Jonathan M Davis via Digitalmars-d long days;

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Jonathan M Davis via Digitalmars-d
On Thu, 05 Jun 2014 18:15:11 -0400 Steven Schveighoffer via Digitalmars-d digitalmars-d@puremagic.com wrote: Respectfully disagree, the API looks very good to me. And decidedly not C-like. It's not even _possible_ to write a function like this in C or in C++98 (though - though maybe C++11/14

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Artur Skawina via Digitalmars-d
On 06/06/14 02:34, Jonathan M Davis via Digitalmars-d wrote: On Thu, 05 Jun 2014 18:18:33 -0400 Steven Schveighoffer via Digitalmars-d digitalmars-d@puremagic.com wrote: On Thu, 05 Jun 2014 18:06:01 -0400, monarch_dodra monarchdo...@gmail.com wrote: On Thursday, 5 June 2014 at 08:49:18

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Artur Skawina via Digitalmars-d
On 06/06/14 02:34, Jonathan M Davis via Digitalmars-d wrote: On Thu, 05 Jun 2014 23:54:49 +0200 Artur Skawina via Digitalmars-d digitalmars-d@puremagic.com wrote: I'm just saying that encouraging that kind of return-by-weakly-typed-pointers-with-string-selectors interfaces is /not/ a good

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Jonathan M Davis via Digitalmars-d
On Fri, 06 Jun 2014 03:30:19 +0200 Artur Skawina via Digitalmars-d digitalmars-d@puremagic.com wrote: On 06/06/14 02:34, Jonathan M Davis via Digitalmars-d wrote: And you get an API which looks like this: auto r = d.split!q{ days, seconds, msecs }; // access r.days etc You can already

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-05 Thread Walter Bright via Digitalmars-d
Jonathan, every one of your postings starts a new thread rather than staying in the one you reply to.

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread Sönke Ludwig via Digitalmars-d
Just a minor note: What about just .only!minutes, analogous .total!minutes? Removing both the .minutes shortcut and the short get method, pretty heavily increases verbosity, so shortening getOnly might be a good idea.

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread David Nadlinger via Digitalmars-d
On Tuesday, 3 June 2014 at 17:35:42 UTC, Russel Winder via Digitalmars-d wrote: This all sounds like implementation detail rather than API usage. How can an API problem be an implementation detail? I'm not quite getting your point here. David

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread Andrei Alexandrescu via Digitalmars-d
On 6/4/14, 9:12 AM, Sönke Ludwig wrote: Just a minor note: What about just .only!minutes, analogous ..total!minutes? Like -- Andrei

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread Kagamin via Digitalmars-d
On Tuesday, 3 June 2014 at 17:01:15 UTC, Jonathan M Davis via Digitalmars-d wrote: As of Sunday. The problem is that they seem to be very prone for misuse. Not only do they not match what TickDuration uses those same names for (it uses them for the equivelent of total!hours(), etc. rather than

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread Meta via Digitalmars-d
On Wednesday, 4 June 2014 at 11:28:52 UTC, Kagamin wrote: Does one really needs only one component, but not the others? Maybe it should provide full computed broken form instead of separate components? auto d=dur.breakUp; d.hours; d.minutes; d.seconds; In some glorious future where we can

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread John Colvin via Digitalmars-d
On Wednesday, 4 June 2014 at 14:16:31 UTC, Meta wrote: On Wednesday, 4 June 2014 at 11:28:52 UTC, Kagamin wrote: Does one really needs only one component, but not the others? Maybe it should provide full computed broken form instead of separate components? auto d=dur.breakUp; d.hours;

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread Meta via Digitalmars-d
On Wednesday, 4 June 2014 at 15:51:58 UTC, John Colvin wrote: Assuming hours, minutes and seconds are already declared, you can do this already TypeTuple!(hours, minutes, seconds) = dur.parts; A full working example of the syntax: import std.typetuple; import std.typecons; import std.stdio;

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread Nick Sabalausky via Digitalmars-d
On 6/4/2014 3:12 AM, Sönke Ludwig wrote: Just a minor note: What about just .only!minutes, analogous .total!minutes? Removing both the .minutes shortcut and the short get method, pretty heavily increases verbosity, so shortening getOnly might be a good idea. +1 for only

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-04 Thread John Colvin via Digitalmars-d
On Wednesday, 4 June 2014 at 17:06:22 UTC, Meta wrote: On Wednesday, 4 June 2014 at 15:51:58 UTC, John Colvin wrote: Assuming hours, minutes and seconds are already declared, you can do this already TypeTuple!(hours, minutes, seconds) = dur.parts; A full working example of the syntax:

(git HEAD) std.datetime spewing deprecation messages

2014-06-03 Thread H. S. Teoh via Digitalmars-d
https://issues.dlang.org/show_bug.cgi?id=12846 Since when is x.hours, x.minutes, etc., deprecated? Well, in any case, looks like std.datetime needs to be fixed. --T

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-03 Thread Jonathan M Davis via Digitalmars-d
On Tue, 3 Jun 2014 07:21:12 -0700 H. S. Teoh via Digitalmars-d digitalmars-d@puremagic.com wrote: https://issues.dlang.org/show_bug.cgi?id=12846 Since when is x.hours, x.minutes, etc., deprecated? As of Sunday. The problem is that they seem to be very prone for misuse. Not only do they not

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-03 Thread Russel Winder via Digitalmars-d
On Tue, 2014-06-03 at 10:00 -0700, Jonathan M Davis via Digitalmars-d wrote: On Tue, 3 Jun 2014 07:21:12 -0700 H. S. Teoh via Digitalmars-d digitalmars-d@puremagic.com wrote: https://issues.dlang.org/show_bug.cgi?id=12846 Since when is x.hours, x.minutes, etc., deprecated? As of

Re: (git HEAD) std.datetime spewing deprecation messages

2014-06-03 Thread Jonathan M Davis via Digitalmars-d
On Tue, 03 Jun 2014 18:35:31 +0100 Russel Winder via Digitalmars-d digitalmars-d@puremagic.com wrote: On Tue, 2014-06-03 at 10:00 -0700, Jonathan M Davis via Digitalmars-d wrote: On Tue, 3 Jun 2014 07:21:12 -0700 H. S. Teoh via Digitalmars-d digitalmars-d@puremagic.com wrote: