[Issue 17482] New: [REG 2.074] comile error: Comparing Nullable!Variant with basic type
    via Digitalmars-d-bugs 
    digitalmars-d-bugs at puremagic.com
       
    Thu Jun  8 18:21:42 PDT 2017
    
    
  
https://issues.dlang.org/show_bug.cgi?id=17482
          Issue ID: 17482
           Summary: [REG 2.074] comile error: Comparing Nullable!Variant
                    with basic type
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: regression
          Priority: P1
         Component: phobos
          Assignee: nobody at puremagic.com
          Reporter: bus_dbugzilla at semitwist.com
Worked fine up through 2.073.2, but 2.074.0 gives a compiler error:
----------------------------------------
import std.variant, std.typecons;
void main()
{
    Nullable!Variant a;
    a == 11; // Yes, comparison intended
}
----------------------------------------
test_nullable_variant.d(6): Error: template
std.typecons.Nullable!(VariantN!32LU).Nullable.opEquals cannot deduce function
from argument types !()(int), candidates are:
/home/nick/.dvm/compilers/dmd-2.074.0/linux/bin/../../src/phobos/std/typecons.d(2212):
       std.typecons.Nullable!(VariantN!32LU).Nullable.opEquals()(auto ref
const(typeof(this)) rhs)
/home/nick/.dvm/compilers/dmd-2.074.0/linux/bin/../../src/phobos/std/typecons.d(2222):
       std.typecons.Nullable!(VariantN!32LU).Nullable.opEquals()(auto ref
const(T) rhs)
--
    
    
More information about the Digitalmars-d-bugs
mailing list