[:] as empty associative array literal, plus warning for null
Regan Heath
regan at netmail.co.nz
Thu Jul 4 08:02:39 PDT 2013
On Thu, 04 Jul 2013 15:35:30 +0100, Andrei Alexandrescu
<SeeWebsiteForEmail at erdani.org> wrote:
> On 7/4/13 6:32 AM, Steven Schveighoffer wrote:
>> I would not be opposed to a pull request that made [] be non-null, as
>> long as it doesn't allocate.
>
> What would be the benefits?
Being able to naturally specify a non-null empty array (literal) such
that...
char[] n = null;
char[] e = [];
assert(n is null)
assert(e !is null);
R
--
Using Opera's revolutionary email client: http://www.opera.com/mail/
More information about the Digitalmars-d
mailing list