[Issue 16389] New: "const" should be inferred for template methods
    via Digitalmars-d-bugs 
    digitalmars-d-bugs at puremagic.com
       
    Sun Aug 14 06:59:11 PDT 2016
    
    
  
https://issues.dlang.org/show_bug.cgi?id=16389
          Issue ID: 16389
           Summary: "const" should be inferred for template methods
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: andrei at erdani.com
Currently defining const and non-const versions of methods in generic code is
redundant and error-prone. When calling a non-const method against a const
object, D should just generate the const method and attempt to typecheck it.
This should cut down significantly on user code and aggravation.
--
    
    
More information about the Digitalmars-d-bugs
mailing list