Project
ReSharper
Priority
Critical
Type
Bug
Fix versions
5.1
State
Can't Reproduce
Assignee
Olga Lobacheva
Subsystem
Psi
Affected versions
No Affected versions
Fixed in build
5.0.1619.139  
  • Created by   Evgeny Pasynkov
    2 years ago (11 Dec 2009 13:24)
  • Updated by   Olga Lobacheva
    22 months ago (14 Jul 2010 17:51)
  • Jira: RSRP-142020
    (history, comments)
 
RSRP-142020 Type inference bug
0
Issue is visible to: All Users
  The issue is visible to the selected user group only
internal interface IVisitor<VTR>
    {
        VTR OnAdd<LT, RT>(IExpression<LT?, RT?, float?> expr) where LT : struct where RT : struct;
    }

    internal interface IExpression<T, T1, T2>
    {
    }

    class Visitor : IVisitor<object>
    {
        public object OnAdd<LT, RT>(IExpression<LT?, RT?, float?> expr) where LT : struct where RT : struct
        {
            throw new NotImplementedException();
        }
    }

    internal class MyClass<LT, RT> : IExpression<LT?, RT?, float?> where LT:struct where RT:struct 
    {
        VTR Process<VTR>(IVisitor<VTR> visitor)
        {
            return visitor.OnAdd(this);//OnAdd - cannot be inferred from usage
        }
    }
Comments (0)
 
History
 
Linked Issues (?)
 
TeamCity Changes (0)
 
Issue has no comments