On Sat, 16 Oct 2010 17:28:17 -0400, Andrei Alexandrescu <seewebsiteforem...@erdani.org> wrote:

On 10/16/2010 02:58 PM, Tomek Sowiński wrote:
Andrei Alexandrescu napisał:

On 10/16/2010 01:39 PM, Steven Schveighoffer wrote:
I suggest wrapping a char[] or wchar[] (of all constancies) with a
special range that imposes the restrictions.

I did so. It was called byDchar and it would accept a string type. It
sucked.

Why it sucked?

Because 99% of the times you'd want to pass byDchar, but it was easy to forget. Then the algorithm would compile and run without byDchar, just with useless semantics.

So call it string, and make the compiler use it as the default type for string literals.

-Steve

Reply via email to