Re: std.logger sharedLog usage

2015-03-30 Thread Robert burner Schadek via Digitalmars-d-learn
On Monday, 30 March 2015 at 04:05:12 UTC, lobo wrote: Thank you, lobo. next version will have equal default LogLevel for all Logger. https://github.com/D-Programming-Language/phobos/pull/3124

Re: std.logger sharedLog usage

2015-03-29 Thread Robert burner Schadek via Digitalmars-d-learn
On Sunday, 29 March 2015 at 01:36:24 UTC, lobo wrote: Hi, I'm trying to use std.experimental.logger and I'd like the logf(), tracef() style functions to log to a file and stdout. (note: I can use sharedLog.logf(), sharedLog.tracef(), but I prefer just logf()) So I did this: shared static

Re: Release D 2.067.0

2015-03-25 Thread Robert burner Schadek via Digitalmars-d-announce
On Wednesday, 25 March 2015 at 02:02:50 UTC, Paul O'Neil wrote: I have been eagerly awaiting this release for a while - especially for std.experimental.logger! let me know how you like it! I always need feedback on it

Re: Making byLine faster: we should be able to delegate this

2015-03-23 Thread Robert burner Schadek via Digitalmars-d
On Monday, 23 March 2015 at 15:00:07 UTC, John Colvin wrote: What would be really great would be a performance test suite for phobos. I'm working on it https://github.com/D-Programming-Language/phobos/pull/2995

Re: How to generate a random string ...

2015-03-16 Thread Robert burner Schadek via Digitalmars-d-learn
On Monday, 16 March 2015 at 22:19:52 UTC, Gary Willoughby wrote: I guess it depends on the encoding? No the character itself are encoding independent. Some references: http://stackoverflow.com/questions/23853489/generate-a-random-unicode-string This will not work as the caller has to

How to generate a random string ...

2015-03-16 Thread Robert burner Schadek via Digitalmars-d-learn
... from all Unicode characters in an idiomatic D way? (std.interal.unicode_*) ``` T genUnicodeString(T)(size_t minChars, size_t maxChars) if(isSomeString!T) { ... } ```

Re: How to generate a random string ...

2015-03-16 Thread Robert burner Schadek via Digitalmars-d-learn
On Monday, 16 March 2015 at 18:48:29 UTC, bearophile wrote: Perhaps by rejection? I mean, generating a uint, test if it's a character and repeat until the result is true. hm, that must not even terminate.

Re: D 2.067.0-b3

2015-03-04 Thread Robert burner Schadek via Digitalmars-d-announce
On Wednesday, 4 March 2015 at 16:14:31 UTC, Mario Kröplin wrote: I just tried the beta with one of our applications, which receives and decodes tens of thousands of XML documents and makes heavy use of the garbage collector. Compared to D 2.066.1, there is a speed-up from 34.5 seconds to 26.5

Re: DConf 2015 discounted hotel rooms now available

2015-03-04 Thread Robert burner Schadek via Digitalmars-d-announce
On Monday, 2 March 2015 at 15:14:57 UTC, Andrew Edwards wrote: What is the unofficial hangout spot for this year? DConf15 takes place at a university, can't we hang on campus.

Re: H1 2015 - db access support in Phobos

2015-02-03 Thread Robert burner Schadek via Digitalmars-d
IMO the java way is to uncreative. We have UDA, CTFE and string mixins anything short of perfect SQL generated at compile time without anything else than UDA annotation to my structs is an epic lose for D. I mean, who wants to write string statements when the lib can generate them for you. For

Re: H1 2015 - db access support in Phobos

2015-02-03 Thread Robert burner Schadek via Digitalmars-d
nice! get it into phobos or vibe

Re: H1 2015 - db access support in Phobos

2015-02-03 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 3 February 2015 at 10:33:25 UTC, Vadim Lopatin wrote: ORM operations are not a simple single query/statement. They often use several queries to load dependent objects. make it an output range Of course, some CTFE/UDAs may be used for generation of field list, but it is not

Re: H1 2015 - db access support in Phobos

2015-02-03 Thread Robert burner Schadek via Digitalmars-d
But for such high level DB library must be based on some lower level DB API (connector). Like JDBC for JPA or Hibernate in Java. really, does it? there is no need for an abstraction layer. you can have functions generate the correct source for mysql, sqlite, you name it. e.g. just generate

sort no @safe in BUILD=debug

2015-02-01 Thread Robert burner Schadek via Digitalmars-d
something wired is going on. phobos HEAD fails to build in multiple places. sort seams to be non-safe in BUILD=debug. After I got it to build by marking some unittests as non-safe utf.d fails when running its unittests. help, please

Re: 521 days, 22 hours, 7 minutes and 52 seconds...

2015-01-26 Thread Robert burner Schadek via Digitalmars-d
On Monday, 26 January 2015 at 18:25:13 UTC, Robert burner Schadek wrote: thank you @!In order of appearance on github() { Dicebot, JakobOvrum, monarchdodra, klamonte, grogancolin, fugalh, Geod24, andralex, braddr, AndrejMitrovic, MetaLang, p0nce, yglukhov, elendel-, sigod, sybrandy,

Re: 521 days, 22 hours, 7 minutes and 52 seconds...

2015-01-26 Thread Robert burner Schadek via Digitalmars-d
thank you @!In order of appearance on github() { Dicebot, JakobOvrum, monarchdodra, klamonte, grogancolin, fugalh, Geod24, andralex, braddr, AndrejMitrovic, MetaLang, p0nce, yglukhov, elendel-, sigod, sybrandy, DmitryOlshansky, SerialVelocity, drasha, klickverbot, MartinNowak, jacob-carlborg,

Re: std.experimental.logger formal review round 3

2015-01-25 Thread Robert burner Schadek via Digitalmars-d
On Sunday, 25 January 2015 at 09:43:36 UTC, Jacob Carlborg wrote: On 2015-01-24 18:45, Robert burner Schadek wrote: I will fix the bug this weekend and rebase to upstream/master. The alias doc has seen some updates this week (please check the rebuild gh-pages, links are in the PR description)

Re: std.experimental.logger formal review round 3

2015-01-24 Thread Robert burner Schadek via Digitalmars-d
I will fix the bug this weekend and rebase to upstream/master. The alias doc has seen some updates this week (please check the rebuild gh-pages, links are in the PR description)

Re: dlang.org redesign n+1

2015-01-21 Thread Robert burner Schadek via Digitalmars-d
shut up and take my money love it

Re: Why exceptions for error handling is so important

2015-01-11 Thread Robert burner Schadek via Digitalmars-d
to not let ranges succumb to such a problem I wrote: https://github.com/D-Programming-Language/phobos/pull/2724

Re: Improving http://dlang.org/library/index.html

2015-01-11 Thread Robert burner Schadek via Digitalmars-d
what about making it multi column like on http://en.cppreference.com/w/

Re: Improving http://dlang.org/library/index.html

2015-01-11 Thread Robert burner Schadek via Digitalmars-d
lets combine both there is enough space, something like || name | desc || name | desc ||

Re: Alignment of dynamic arrays

2015-01-09 Thread Robert burner Schadek via Digitalmars-d
not 16 bit, 16 byte. -Steve known how to read helps, of course you're right.

Re: Why do the same work about 'IndexOfAny' and 'indexOf' function?

2015-01-09 Thread Robert burner Schadek via Digitalmars-d-learn
On Friday, 9 January 2015 at 14:03:21 UTC, ketmar via Digitalmars-d-learn wrote: std.regex can use CTFE to compile regular expressions (yet it sometimes slower than non-CTFE variant), and i mean that we compile regexp before doing alot of searches, not before each single search. if you have

Re: Why do the same work about 'IndexOfAny' and 'indexOf' function?

2015-01-09 Thread Robert burner Schadek via Digitalmars-d-learn
On Friday, 9 January 2015 at 13:25:17 UTC, ketmar via Digitalmars-d-learn wrote: if you *really* concerned with speed here, you'd better consider using regular expressions. as regular expression can be precompiled and then search for multiple words with only one pass over the source string. i

Re: NASA/JPL Rules for writing Critical Software

2015-01-09 Thread Robert burner Schadek via Digitalmars-d
On Thursday, 8 January 2015 at 23:37:38 UTC, Walter Bright wrote: http://pixelscommander.com/wp-content/uploads/2014/12/P10.pdf from the document (Rule 5): A typical use of an assertion would be as follows: if (!c_assert(p = 0) == true) { return ERROR; } that is just bad code. IMO I'm

Re: Alignment of dynamic arrays

2015-01-09 Thread Robert burner Schadek via Digitalmars-d
On Friday, 9 January 2015 at 11:19:47 UTC, bearophile wrote: If you have a 16-byte aligned array of doubles and you slice the first double away, what's the alignment of the result? the first double[0] is 16-byte aligned, double[1] would be 20-byte aligned as a double is 4 byte long. p.s.

Re: Alignment of dynamic arrays

2015-01-09 Thread Robert burner Schadek via Digitalmars-d
On Friday, 9 January 2015 at 00:23:47 UTC, bearophile wrote: Luc Bourhis: With auto a = new double[1000], is there any guarantee that a.ptr is aligned on a 16-byte boundary? Arrays are aligned on a 16-byte. But if you slice them, this alignment can be broken. IMO, If you slice a double

Re: Why do the same work about 'IndexOfAny' and 'indexOf' function?

2015-01-09 Thread Robert burner Schadek via Digitalmars-d-learn
On Friday, 9 January 2015 at 14:21:04 UTC, ketmar via Digitalmars-d-learn wrote: heh. regexps *are* fast enough. it's hard to beat well-optimised generated thingy on a complex grammar. ;-) I don't see your point, anyway I think he got his help or at least some help.

Re: Why do the same work about 'IndexOfAny' and 'indexOf' function?

2015-01-08 Thread Robert burner Schadek via Digitalmars-d-learn
use canFind like such: bool a = canFind(strs,s) = 1; let the compiler figger out what the types of the parameter are.

Re: D idioms list

2015-01-08 Thread Robert burner Schadek via Digitalmars-d-announce
that a really nice idea, thanks. substring position, std.string.(last)indexOf(|Any|Neither) may be better btw. this should move to the dlang wiki. Any takers?

Re: Ready to make page-per-item ddocs the default?

2015-01-07 Thread Robert burner Schadek via Digitalmars-d
On Wednesday, 7 January 2015 at 01:13:21 UTC, Andrei Alexandrescu wrote: On 1/6/15 4:26 PM, Robert burner Schadek wrote: std.string looks fine only the indexOfNeither and lastIndexOfNeither are missing Could you please fix -- thanks! -- Andrei I think I just did. Does the webpage show

Re: Ready to make page-per-item ddocs the default?

2015-01-06 Thread Robert burner Schadek via Digitalmars-d
std.string looks fine only the indexOfNeither and lastIndexOfNeither are missing

Re: std.experimental.logger formal review round 3

2015-01-06 Thread Robert burner Schadek via Digitalmars-d
recent updates: * Martins CT log function disabling (thanks Martin) * new thread local indirection Logger between free standing log functions and program global Logger * more documentation * some @trusted have been remove (thanks Dicebot) * local imports please review

Re: Ranges and Exception handling PR 2724

2014-12-27 Thread Robert burner Schadek via Digitalmars-d
On Saturday, 15 November 2014 at 01:43:07 UTC, Robert burner Schadek wrote: This PR https://github.com/D-Programming-Language/phobos/pull/2724 adds an generic way of handling Exception in Range processing. quickfur and Dicebot ask me to start a thread here so the concept could be discussed.

Re: ini library in OSX

2014-12-23 Thread Robert burner Schadek via Digitalmars-d-learn
as you properly know, ini files don't support sections arrays. If you know all items at compile time, you could create structs for all of them, but that is properly not what you're looking for.

Re: ini library in OSX

2014-12-22 Thread Robert burner Schadek via Digitalmars-d-learn
On Saturday, 20 December 2014 at 08:09:06 UTC, Joel wrote: On Monday, 13 October 2014 at 16:06:42 UTC, Robert burner Schadek wrote: On Saturday, 11 October 2014 at 22:38:20 UTC, Joel wrote: On Thursday, 11 September 2014 at 10:49:48 UTC, Robert burner Schadek wrote: some self promo:

Re: LogLevel [was std.experimental.logger formal review round 3]

2014-12-09 Thread Robert burner Schadek via Digitalmars-d
On Monday, 8 December 2014 at 21:20:20 UTC, Andrei Alexandrescu wrote: On 12/4/14 8:37 PM, Robert burner Schadek wrote: That is much nicer, thank you for taking the time. Couldn't way just say that we don't import __MODULE__ but rather __MODULE__ ~ _loggerinfo.d and then describe the import

Re: LogLevel [was std.experimental.logger formal review round 3]

2014-12-05 Thread Robert burner Schadek via Digitalmars-d
On Friday, 5 December 2014 at 10:30:08 UTC, Dicebot wrote: On Thursday, 4 December 2014 at 14:32:27 UTC, Daniel Murphy wrote: FWIW I don't really like this - it feels like a hack. I'd rather just declare a private logger alias (or something like that) and use that in the library. Decision

Re: DIP69 - Implement scope for escape proof references

2014-12-04 Thread Robert burner Schadek via Digitalmars-d
thank you for pushing on this. Lifetime last bullet point: , but lower than any variables in higher scopes. isn't that redundant to the first bullet point? Or am I missing something? Scope affects variables according to these rules: Could you enumerate the list instead of bullet points, I

Re: LogLevel [was std.experimental.logger formal review round 3]

2014-12-04 Thread Robert burner Schadek via Digitalmars-d
That is much nicer, thank you for taking the time. Couldn't way just say that we don't import __MODULE__ but rather __MODULE__ ~ _loggerinfo.d and then describe the import constraint in the documentation.

Re: LogLevel [was std.experimental.logger formal review round 3]

2014-12-04 Thread Robert burner Schadek via Digitalmars-d
As I have explained countless times, the configuration in source and through inheritance will always be more powerful and flexible than a config file. I'm not gone create any config file support, as there will be always one feature missing and there is just no way to anticipate all possible

Re: LogLevel [was std.experimental.logger formal review round 3]

2014-12-04 Thread Robert burner Schadek via Digitalmars-d
On Thursday, 4 December 2014 at 11:02:23 UTC, Ola Fosheim Grøstad wrote: On Thursday, 4 December 2014 at 10:56:29 UTC, Robert burner Schadek wrote: As I have explained countless times, the configuration in source and through inheritance will always be more powerful and There is no

Re: LogLevel [was std.experimental.logger formal review round 3]

2014-12-04 Thread Robert burner Schadek via Digitalmars-d
On Thursday, 4 December 2014 at 11:49:53 UTC, Ola Fosheim Grøstad wrote: I think D lacks a generic project configuration mechanism. I generally want configurations to be located in one or at least a few files that are easy to modify and which can have tools written for them. So yes, this

Re: LogLevel [was std.experimental.logger formal review round 3]

2014-12-04 Thread Robert burner Schadek via Digitalmars-d
On Thursday, 4 December 2014 at 11:12:02 UTC, Martin Nowak wrote: On Thursday, 4 December 2014 at 10:37:12 UTC, Robert burner Schadek wrote: That is much nicer, thank you for taking the time. Couldn't way just say that we don't import __MODULE__ but rather __MODULE__ ~ _loggerinfo.d and then

Re: std.experimental.logger formal review round 3

2014-11-30 Thread Robert burner Schadek via Digitalmars-d
On Saturday, 29 November 2014 at 19:18:01 UTC, Martin Nowak wrote: On 11/29/2014 05:25 PM, Robert burner Schadek wrote: Yes, there is a lock free, thread local indirection now. That can be used to build a lock free, thread local logger. p.s. You should have taken the phun I commented on

Re: std.experimental.logger formal review round 3

2014-11-29 Thread Robert burner Schadek via Digitalmars-d
On Saturday, 29 November 2014 at 14:15:12 UTC, Martin Nowak wrote: On Friday, 14 November 2014 at 21:49:09 UTC, David Nadlinger wrote: On Friday, 14 November 2014 at 21:46:00 UTC, Robert burner Schadek wrote: You can always roll your own non locking Logger, but the default should be

Re: std.experimental.logger formal review round 3

2014-11-26 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 25 November 2014 at 23:41:51 UTC, Walter Bright wrote: On 11/25/2014 2:26 AM, Robert burner Schadek wrote: On Tuesday, 25 November 2014 at 00:37:00 UTC, Walter Bright wrote: Anyone know anything about this?

Re: std.experimental.logger formal review round 3

2014-11-25 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 25 November 2014 at 00:37:00 UTC, Walter Bright wrote: Anyone know anything about this? https://www.reddit.com/r/programming/comments/2n9gfb/d_is_for_data_science/cmbssac You mean the second part, about him leaving D because of the discussion about the logger?

Re: std.experimental.logger formal review round 3

2014-11-24 Thread Robert burner Schadek via Digitalmars-d
On Friday, 14 November 2014 at 23:06:22 UTC, Dicebot wrote: On Friday, 14 November 2014 at 22:20:17 UTC, Robert burner Schadek wrote: I will test something this weekend regarding the additional indirection. Thanks! I may try hacking some sample implementation too but pessimistic about ETA

Re: Ranges and Exception handling PR 2724

2014-11-21 Thread Robert burner Schadek via Digitalmars-d
Your idea designs an idiom on how to let ranges handle exceptions. My PR is about how to handle exceptions thrown by ranges. Both sort-of do the same thing but at different points. Your design idiom needs source access (needs to be programmed in). Mine can be bolted on later (an additional

Re: Ranges and Exception handling PR 2724

2014-11-20 Thread Robert burner Schadek via Digitalmars-d
On Wednesday, 19 November 2014 at 05:49:55 UTC, H. S. Teoh via Digitalmars-d w From what I understand, this PR is proposing to add a range wrapper that catches exceptions thrown from range primitives and passes them to a user-specified handler. Seems to be a promising idea, but it's probably

Re: Ranges and Exception handling PR 2724

2014-11-20 Thread Robert burner Schadek via Digitalmars-d
hm, the thing is there are ranges that will throw, making them nothrow is of course a very good idea, but some will still throw map(a = throw ...) This handleXXX ranges deal with them.

Re: std.experimental.logger formal review round 3

2014-11-14 Thread Robert burner Schadek via Digitalmars-d
On Friday, 14 November 2014 at 21:43:53 UTC, David Nadlinger wrote: Except that they can't actually get rid of all the overhead involved, as the locking is hard-coded into the Logger base-class. Granted, acquiring an uncontended lock isn't terribly expensive, but it's still a noticeable

Re: std.experimental.logger formal review round 3

2014-11-14 Thread Robert burner Schadek via Digitalmars-d
On Friday, 14 November 2014 at 21:49:09 UTC, David Nadlinger wrote: On Friday, 14 November 2014 at 21:46:00 UTC, Robert burner Schadek wrote: You can always roll your own non locking Logger, but the default should be thread-safe. You can't, since you need to inherit from Logger, which already

Re: std.experimental.logger formal review round 3

2014-11-14 Thread Robert burner Schadek via Digitalmars-d
I will test something this weekend regarding the additional indirection.

Ranges and Exception handling PR 2724

2014-11-14 Thread Robert burner Schadek via Digitalmars-d
This PR https://github.com/D-Programming-Language/phobos/pull/2724 adds an generic way of handling Exception in Range processing. quickfur and Dicebot ask me to start a thread here so the concept could be discussed.

Re: std.experimental.logger formal review round 3

2014-11-14 Thread Robert burner Schadek via Digitalmars-d
On Friday, 14 November 2014 at 23:40:21 UTC, David Nadlinger wrote: On Friday, 14 November 2014 at 22:18:41 UTC, Robert burner Schadek wrote: Yes, but this way allows to add structured logging in an easy way. What. The actual log call is split into multiple parts so that the user can

Re: std.experimental.logger formal review round 3

2014-11-13 Thread Robert burner Schadek via Digitalmars-d
IMO this defeats the design goal off having the default case very easy and just working. Therefore, I think thread local global Logger and how to make them interact is something that should be left to the advanced user.

Re: std.experimental.logger formal review round 3

2014-11-13 Thread Robert burner Schadek via Digitalmars-d
On Wednesday, 12 November 2014 at 15:05:29 UTC, Ola Fosheim Grøstad wrote: On Wednesday, 12 November 2014 at 12:39:24 UTC, Robert burner Schadek wrote: Only one thread can write to one Logger at a time, also known as synchronization. Anything else is properly wrong. But you can have as many

Re: std.experimental.logger formal review round 3

2014-11-13 Thread Robert burner Schadek via Digitalmars-d
On Thursday, 13 November 2014 at 22:13:53 UTC, Marco Leise wrote: Am Wed, 12 Nov 2014 17:56:06 + schrieb Dicebot pub...@dicebot.lv: […] have means to explicitly capture lock on global one from local proxies for optimized bulk logging. That's certainly something that occurred to me when

Re: std.experimental.logger formal review round 3

2014-11-12 Thread Robert burner Schadek via Digitalmars-d
On Wednesday, 12 November 2014 at 05:36:40 UTC, Jose wrote: On Tuesday, 11 November 2014 at 15:06:49 UTC, Dicebot wrote: https://github.com/Dicebot/phobos/tree/logger-safety One shared Logger: https://github.com/burner/phobos/blob/logger/std/experimental/logger/core.d#L1696 One global

Re: std.experimental.logger formal review round 3

2014-11-10 Thread Robert burner Schadek via Digitalmars-d
On Sunday, 9 November 2014 at 21:42:09 UTC, Dicebot wrote: And back to the frontpage. Martin / Robert, have you managed to come to an agreement on conditional level thing? After your last reply we haven't done anything else. I would merge his idea, but there is pushback from your side.

Re: std.experimental.logger formal review round 3

2014-11-10 Thread Robert burner Schadek via Digitalmars-d
On Monday, 10 November 2014 at 17:03:31 UTC, Dicebot wrote: On Monday, 10 November 2014 at 11:46:34 UTC, Robert burner Schadek wrote: After your last reply we haven't done anything else. I would merge his idea, but there is pushback from your side. Anyway, this idea would not break the api.

Re: std.experimental.logger formal review round 3

2014-11-03 Thread Robert burner Schadek via Digitalmars-d
I will remove the trusted later this week

Re: std.experimental.logger formal review round 3

2014-10-29 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 28 October 2014 at 22:03:18 UTC, Martin Nowak wrote: On 10/28/2014 07:22 PM, Martin Nowak wrote: On Tuesday, 28 October 2014 at 12:02:16 UTC, Robert burner Schadek wrote: It is a design goal to disable certain LogLevel at CT of a compile unit (CU). e.g. make all logs to trace

Re: std.experimental.logger formal review round 3

2014-10-29 Thread Robert burner Schadek via Digitalmars-d
The reason for the crowbar sometimes you need to disable all calls to the Logger or any calls to a specific LogLevel in the compile unit, even for Logger not wrapped in LoggerCT.

Re: std.experimental.logger formal review round 3

2014-10-28 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 28 October 2014 at 01:37:48 UTC, Martin Nowak wrote: On 10/28/2014 12:58 AM, Robert burner Schadek wrote: Disabling a version at CT of the lib has no consequence to compile units that are not compiled with that version statement. Yes setting a version in my app has no effect on

Re: std.experimental.logger formal review round 3

2014-10-28 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 28 October 2014 at 01:42:12 UTC, Martin Nowak wrote: On 10/28/2014 01:01 AM, Robert burner Schadek wrote: is different from the code that has been in the PR for quite some time. And the code you show does exactly what you say and the current code does something different. No it

Re: std.experimental.logger formal review round 3

2014-10-28 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 28 October 2014 at 05:44:48 UTC, Andrei Alexandrescu wrote: Being able to select maximum logging level statically at client application level is a deal maker/breaker for me. The mechanics aren't important but it's likely they will affect the API. So I think that needs to be

Re: std.experimental.logger formal review round 3

2014-10-28 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 28 October 2014 at 09:39:24 UTC, Martin Nowak wrote: On Tuesday, 28 October 2014 at 08:38:50 UTC, Robert burner Schadek wrote: Actually, that is only true for LogLevel given to a log call at runtime. calls to info, trace etc. are guarded with static if. So you're not paying any

Re: std.experimental.logger formal review round 3

2014-10-28 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 28 October 2014 at 11:11:09 UTC, Martin Nowak wrote: Yep, let's try that. I think part of the misunderstanding is that I'm thinking of an app as user code plus a number of libraries all on top of phobos. Say I have an app using vibe.d and I want to enable logging in my app, but

Re: std.experimental.logger formal review round 3

2014-10-27 Thread Robert burner Schadek via Digitalmars-d
On Sunday, 26 October 2014 at 23:45:56 UTC, Martin Nowak wrote: On 10/26/2014 11:29 PM, Robert burner Schadek wrote: And I forgot to add, no better solution presented itself in one year. Well I showed one solution, but reduce it to its essence. If you allow to define a Logger with a

Re: std.experimental.logger formal review round 3

2014-10-27 Thread Robert burner Schadek via Digitalmars-d
On Monday, 27 October 2014 at 07:03:11 UTC, Dicebot wrote: I don't consider it a major issue as I don't think std.logger should be used inside Phobos at all. Yes, using std.logger inside of phobos is a no-no

Re: std.experimental.logger formal review round 3

2014-10-27 Thread Robert burner Schadek via Digitalmars-d
On Sunday, 26 October 2014 at 23:58:14 UTC, Martin Nowak wrote: On 10/27/2014 12:45 AM, Martin Nowak wrote: If you allow to define a Logger with a LogLevel know at compile time and you statically pass the LogLevel of your message to the logging function you can elide that call. For anything

Re: std.experimental.logger formal review round 3

2014-10-27 Thread Robert burner Schadek via Digitalmars-d
On Sunday, 26 October 2014 at 22:57:51 UTC, Martin Nowak wrote: On 10/26/2014 11:27 PM, Robert burner Schadek wrote: it is not really a dependency as the one template that uses the version identifier uses them optionally. It simply doesn't work, e.g. you could not statically disable logging

Re: std.experimental.logger formal review round 3

2014-10-27 Thread Robert burner Schadek via Digitalmars-d
On Monday, 27 October 2014 at 12:03:33 UTC, Dicebot wrote: Ayway, let's come with an agreement/compromise with Martin and I'll start voting immediately after. Well, as far as I can see his argument was based on old code that has long been rewritten and he hasn't answered since I pointed

Re: std.experimental.logger formal review round 3

2014-10-27 Thread Robert burner Schadek via Digitalmars-d
On Monday, 27 October 2014 at 20:49:35 UTC, Dicebot wrote: On Monday, 27 October 2014 at 20:42:10 UTC, Martin Nowak wrote: Say I want to add tracing/logging to [`parseJson`](http://dlang.org/library/std/json/parseJSON.html) or [`findRoot`](http://dlang.org/phobos/std_numeric.html#.findRoot)

Re: std.experimental.logger formal review round 3

2014-10-27 Thread Robert burner Schadek via Digitalmars-d
On Monday, 27 October 2014 at 22:27:12 UTC, Martin Nowak wrote: On 10/27/2014 09:28 AM, Robert burner Schadek wrote: If it where done this way, yes of course you're right. But it is not, please take a look a the source first. I'm looking at

Re: std.experimental.logger formal review round 3

2014-10-27 Thread Robert burner Schadek via Digitalmars-d
On Monday, 27 October 2014 at 22:20:04 UTC, Martin Nowak wrote: On 10/27/2014 01:36 PM, Robert burner Schadek wrote: Well, as far as I can see his argument was based on old code that has long been rewritten and he hasn't answered since I pointed that out. How do come to that insight?

Re: std.experimental.logger formal review round 3

2014-10-26 Thread Robert burner Schadek via Digitalmars-d
On Sunday, 26 October 2014 at 22:27:55 UTC, Robert burner Schadek wrote: The dependency on external version identifiers in phobos is still a complete bummer it is not really a dependency as the one template that uses the version identifier uses them optionally. And I forgot to add, no

Re: std.experimental.logger formal review round 3

2014-10-26 Thread Robert burner Schadek via Digitalmars-d
On Sunday, 26 October 2014 at 22:12:20 UTC, Martin Nowak wrote: On 10/25/2014 06:43 PM, Dicebot wrote: Because of that I am going to start voting despite some arguments being still in process. I hope that won't cause any tension. The dependency on external version identifiers in phobos is

Re: std.experimental.logger formal review round 3

2014-10-24 Thread Robert burner Schadek via Digitalmars-d
On Friday, 24 October 2014 at 11:01:40 UTC, Martin Nowak wrote: On Sunday, 12 October 2014 at 12:06:44 UTC, Robert burner Schadek wrote: What's stopping an interface or class to implement a logging concept? Same as last time: Logger[], Logger without a LogLevel not real useful IMO, (new) no

Re: std.experimental.logger formal review round 3

2014-10-24 Thread Robert burner Schadek via Digitalmars-d
On Friday, 24 October 2014 at 09:53:57 UTC, Dicebot wrote: Will start review round in ~2 days. I am very sorry for delay :( No problem the PR has been open since Aug. 2013, one or two weeks more or less don't really matter anymore ;)

Re: Really in need of help with std.container.array.d

2014-10-16 Thread Robert burner Schadek via Digitalmars-d-learn
On Wednesday, 15 October 2014 at 21:15:14 UTC, Nordlöw wrote: Comint exited abnormally with code 1 at Wed Oct 15 23:14:37 I'm stuck. Need help. I will give it a try

Re: std.experimental.logger formal review round 3

2014-10-15 Thread Robert burner Schadek via Digitalmars-d
On Wednesday, 15 October 2014 at 02:54:27 UTC, Dicebot wrote: As there was quite some last moment feedback I am giving some more time for me to research issues a bit and Robert to address them :) No need, I fixed the MultiLogger last weekend.

Re: std.experimental.logger formal review round 3

2014-10-15 Thread Robert burner Schadek via Digitalmars-d
On Wednesday, 15 October 2014 at 10:12:56 UTC, Jakob Ovrum wrote: On Wednesday, 15 October 2014 at 09:25:07 UTC, Robert burner Schadek wrote: On Wednesday, 15 October 2014 at 02:54:27 UTC, Dicebot wrote: As there was quite some last moment feedback I am giving some more time for me to research

Re: Parameterized unit testing and benchmarking of phobos

2014-10-14 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 14 October 2014 at 06:54:42 UTC, Martin Nowak wrote: On 10/08/2014 11:37 PM, Robert burner Schadek wrote: Lately, I find myself wondering, if I should add parameterized unit tests to std.string, because the last few bugs I fixed where not caught by tests, as the test-data was not

Re: Parameterized unit testing and benchmarking of phobos

2014-10-14 Thread Robert burner Schadek via Digitalmars-d
On Tuesday, 14 October 2014 at 12:17:05 UTC, Martin Nowak wrote: On 10/14/2014 10:38 AM, Robert burner Schadek wrote: well quite a nice and big library. You add the benchmark feature, get a merged into phobos and I will gladly use it to test std.string. Not sure whether a random testing

Re: Really in need of help with std.container.array.d

2014-10-14 Thread Robert burner Schadek via Digitalmars-d-learn
On Tuesday, 14 October 2014 at 12:51:29 UTC, Nordlöw wrote: Could you please give me a code example? I'm not skilled enough in D to follow this description. struct Range(T) { Array!S array; T opIndex(size_t i) { return cast(T)array[i]; } } struct Array(T) { Range!(const(T))

Re: Really in need of help with std.container.array.d

2014-10-13 Thread Robert burner Schadek via Digitalmars-d-learn
hm, the problems seams to be that inout Array is not becoming const Array and friends. A blunt force solution would be to create a range as Range!(ReturnType!Array...)(cast(Array!T)this, low, high); and then do the correct casts in Range. The ReturnType would be the ReturnType of opIndex of the

Re: ini library in OSX

2014-10-13 Thread Robert burner Schadek via Digitalmars-d-learn
On Saturday, 11 October 2014 at 22:38:20 UTC, Joel wrote: On Thursday, 11 September 2014 at 10:49:48 UTC, Robert burner Schadek wrote: some self promo: http://code.dlang.org/packages/inifiled I would like an example? go to the link and scroll down a page

Re: std.experimental.logger formal review round 3

2014-10-12 Thread Robert burner Schadek via Digitalmars-d
On Sunday, 12 October 2014 at 09:07:37 UTC, Jacob Carlborg wrote: On 2014-10-11 15:34, Robert burner Schadek wrote: - Why do loggers have to be classes? As answered multiply times before, to build log hierarchies. What's stopping an interface or class to implement a logging concept? Same

Re: std.experimental.logger formal review round 3

2014-10-12 Thread Robert burner Schadek via Digitalmars-d
On Saturday, 11 October 2014 at 23:37:42 UTC, Marco Leise wrote: I had the same feeling as Jakob about an `Appender` already in the base class and would have expected a bare bones abstract class + a batteries included version using `Appender`. (A bit like Java's …Listener and …Adapter classes.)

Re: Parameterized unit testing and benchmarking of phobos

2014-10-12 Thread Robert burner Schadek via Digitalmars-d
On Friday, 10 October 2014 at 14:20:39 UTC, Jacob Carlborg wrote: On 10/10/14 10:09, Robert burner Schadek wrote: This will work for me private project, but I want this in std.string. Why wouldn't this working std.string? because, this would require changing the phobos unittester, doing

Re: std.experimental.logger formal review round 3

2014-10-11 Thread Robert burner Schadek via Digitalmars-d
On Saturday, 11 October 2014 at 10:48:00 UTC, Jacob Carlborg wrote: On 2014-10-11 05:41, Dicebot wrote: I don't see critical objections so far and this will move to voting stage this weekend. Please hurry up if you want to say something bad :) I think it's unacceptable that the documentation

Re: std.experimental.logger formal review round 3

2014-10-11 Thread Robert burner Schadek via Digitalmars-d
On Saturday, 11 October 2014 at 04:31:17 UTC, Jakob Ovrum wrote: On Saturday, 11 October 2014 at 03:41:08 UTC, Dicebot wrote: I don't see critical objections so far and this will move to voting stage this weekend. Please hurry up if you want to say something bad :) Attributes need to be

Re: std.experimental.logger formal review round 3

2014-10-11 Thread Robert burner Schadek via Digitalmars-d
On Saturday, 11 October 2014 at 13:16:18 UTC, Martin Nowak wrote: On 09/28/2014 02:24 PM, Dicebot wrote: Important changes since last review: - new approach for compile-time log level filtering What's new here? It still relies on version identifiers to do so. As I said in some earlier

Re: std.experimental.logger formal review round 3

2014-10-11 Thread Robert burner Schadek via Digitalmars-d
On Saturday, 11 October 2014 at 03:41:08 UTC, Dicebot wrote: I don't see critical objections so far and this will move to voting stage this weekend. Please hurry up if you want to say something bad :) MultiLogger got a new simpler impl.

Re: Parameterized unit testing and benchmarking of phobos

2014-10-10 Thread Robert burner Schadek via Digitalmars-d
On Friday, 10 October 2014 at 06:39:25 UTC, Jacob Carlborg wrote: I think you should use a UDA's instead. The a unit test framework can, hopefully, handle this automatically. This will work for me private project, but I want this in std.string.

<    1   2   3   4   5   >