Summary: back() and front() with ref return + opSlice() in
                    sort() constraint
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Phobos

--- Comment #0 from 2011-02-19 07:23:14 PST ---
With some experiments I have seen that the input of std.algorithm.sort() has
other requirements beside being just a random access range (dmd 2.052):

My experiment shows that beside being a random access range, the input range
needs also:
- opSlice()
- back() and front() must return their results by ref.

So to reduce troubles for the users I suggest to add those three requirements
inside the template constraint of sort(), to produce a better error message and
detect problems more early.

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to