November 27, 2006
http://d.puremagic.com/issues/show_bug.cgi?id=610

           Summary: Undocumented behaviour: ~ and ~= can now concatenate an
                    array with a single element
           Product: D
           Version: 0.175
          Platform: All
               URL: http://www.digitalmars.com/d/expression.html
        OS/Version: All
            Status: NEW
          Keywords: spec
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla@digitalmars.com
        ReportedBy: smjg@iname.com
 BugsThisDependsOn: 511


Once upon a time, both sides of a ~ had to be arrays of the same type, even though ~= allowed the rvalue to be a single element to be apppended to an array.

Now, ~ can also take a single element on one side.  For example:

----------
int[] qwert = [ 2, 3, 4, 5, 6 ];
int[] yuiop = qwert ~ 8;
int[] asdfg = 10 ~ yuiop;
----------

However, this capability is not documented, either for ~ or for ~=, as far as I can see.


-- 

December 03, 2006
http://d.puremagic.com/issues/show_bug.cgi?id=610


deewiant@gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED




------- Comment #1 from deewiant@gmail.com  2006-12-03 04:09 -------
Documented for DMD 0.176.


--