Ambiguous method call with Action parameter overload

前端 未结 3 1825
时光说笑
时光说笑 2021-01-18 09:47

I encountered some unexpected compiler behaviour when calling overloaded method with different Action variations.

Let\'s say I have this class

3条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-18 10:39

    There is a workaround:

        Test t = new Test(new Action(TestDecimal));
    

提交回复
热议问题