Commit Graph

4 Commits

Author SHA1 Message Date
Arnold Schwaighofer
85d732ca26 TypeChecker: Fix dynamic replacement of protocol default implementation
Ignore the decl inside the protocol decl.

rdar://52863618
2019-07-11 10:00:31 -07:00
Arnold Schwaighofer
1b863d6787 Allow final on dynamic members
Dynamic is about dynamically replacing a method implementiation not
overriding.

rdar://49535048
2019-04-04 07:26:43 -07:00
Arnold Schwaighofer
8d9b9f328b SILGen: Fix the logic of dynamic replacements for class constructors
To correctly call designated super class initializers the designated
intializer (and not the allocator) is dynamically replaceable.
Convenience allocators are dynamically replaceable as before.
2019-02-22 10:15:06 -08:00
Doug Gregor
5d968621d7 [Type checker] Basic ambiguity resolution + diagnostics for dynamic replacement.
We weren't doing much validation when dynamically replacing storage
declarations, and has an assert() that should be an error. Clean up this
area a bit, dealing with simple ambiguities (i.e., there are two
properties or subscripts with different type signatures; pick the
matching one) and reporting an error when there is a true ambiguity.

Fixes rdar://problem/46737657.
2018-12-21 11:47:59 -08:00