News for hackers. Stuff that matters.
Re:Toward Go 2 by avip on Thursday July 13, 2017 @04:10PM (#14764734)
The dynamic type was added to C# to facilitate interoperability (ex. DLR), not so much to encourage lazy devs to get their bugs at runtime rather than compile time.
Re:Toward Go 2 by pjmlp on Thursday July 13, 2017 @04:46PM (#14765056)
Additionally to simplify dynamic dispatch calls on COM.
Re:Toward Go 2 by willtim on Thursday July 13, 2017 @04:52PM (#14765113)
I still do not understand why this cannot be done via a Variant type. Also it doesn't explain why Dart 2 has a similar feature.
Re:Toward Go 2 by masklinn on Friday July 14, 2017 @06:14AM (#14768728)
> I still do not understand why this cannot be done via a Variant type.

Makes little difference, either way you need a magical type since it has to allow any method call at compile time, and then requires enough RTTI that it can check for and dispatch method calls at runtime. Whether you call it Variant or dynamic has no relevance.

Re:Toward Go 2 by barrkel on Thursday July 13, 2017 @05:48PM (#14765570)
Think of dynamic as a different word for Variant.

The semantic differences for OLE2 Variants vs C# dynamic mostly only exist in implementation protocols.