assert() vs. enforce(), invariant() vs. ... ?
Namespace
rswhite4 at googlemail.com
Fri Aug 30 07:51:39 PDT 2013
On Friday, 30 August 2013 at 12:18:21 UTC, John Colvin wrote:
> On Friday, 30 August 2013 at 11:50:20 UTC, Jacob Carlborg wrote:
>> On 2013-08-30 12:56, John Colvin wrote:
>>
>>> alias this, but without implicit conversion. It just
>>> implements all the
>>> op**** functions (including opDispatch).
>>
>> So what's the difference to Typedef, declared just below?
>
> Typedef uses Proxy to do the work. Proxy is a mixing template
> for adding in to a struct/class and Typedef is a very simple
> struct making use of it to implement a library typedef.
>
> Unfortunately, Typedef is rather lacking as far as being a
> typedef is concerned, but that's not due to problems with Proxy.
What was the initial reason, to move typedef from the language
into the library? I assume, that there is something special about
typedef that can not be done with alias. If so, why was it moved?
It seems to be a trend, to move incomplete features from the
language into the library (See also scope -> scoped). I do not
like that. :/
More information about the Digitalmars-d
mailing list