Open ghost opened 6 years ago
The late-binder just needs to be updated to use the same logic and we do for the early bound case where ()
can invoke a delegate. Today the late-binder only uses (arguments)
for default property access or actual method invocation. I'll leave this issue open to reminder to fix this bug ASAP. Thanks!
@AnthonyDGreen Thanks.
This sample will work fine:
But in I erase the Invoke method from the last line:
Dim z = Test.Inc(2)
it will raise an exception. This doesn't happen in C#, where I can call the delegate without the Invoke method:In fact , C# raise an exception when I use the Invoke method!
This is the VB.NET Exception details