[SR-13018] Type constraints are not honored when invoking method #55463
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
crash
Bug: A crash, i.e., an abnormal termination of software
run-time crash
Bug → crash: Swift code crashed during execution
Additional Detail from JIRA
md5: 2c03afa2034e8d179cd73102ecf6a551
Issue Description:
Consider the following method:
This should restrict the collection passed into `run` to be such that its subsequence matches the generic A.
For example, these following compile just fine:
However, there seem to be some situations where we can pass in a collection that does not match this constraint and yet it still compiles, and hence crashes at runtime:
The text was updated successfully, but these errors were encountered: