-
Notifications
You must be signed in to change notification settings - Fork 833
Closed
Labels
Feature ImprovementTheme-Simple-F#A cross-community initiative called "Simple F#", keeping people in the sweet spot of the language.A cross-community initiative called "Simple F#", keeping people in the sweet spot of the language.
Milestone
Description
What
let foo () : IDictionary<'a,'b> = Dictionary<'a,'b>()Error: This expression was expected to have type IDictionary<'a,'b> but here has type Dictionary<'a,'b>.
Why
New commers don't know about need for upcast, nor they know the idiomatic
let foo () : IDictionary<'a,'b> = Dictionary<'a,'b>() :> _How
Error: This expression was expected to have type IDictionary<'a,'b> but here has type Dictionary<'a,'b>, consider using cast operator :> _.
Metadata
Metadata
Assignees
Labels
Feature ImprovementTheme-Simple-F#A cross-community initiative called "Simple F#", keeping people in the sweet spot of the language.A cross-community initiative called "Simple F#", keeping people in the sweet spot of the language.