You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
swift-ci opened this issue
Apr 5, 2019
· 0 comments
Labels
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.compilerThe Swift compiler in itselfparserArea → compiler: The legacy C++ parser
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.compilerThe Swift compiler in itselfparserArea → compiler: The legacy C++ parser
Additional Detail from JIRA
md5: db223fce161d3f1610d14346ddaa647a
Issue Description:
Enter the following program:
import Foundation
print ("import Foundation")
print ("type alias bigFunc = (")
for i in 0 ..< 65537 {
}
print ("let t = bigFunc.self")
print ("print (t)")
Collect the output and use it as input to the swift compiler (LimitCheck | pbcopy).
The compiler will compile this (good on you!), but the output is:
(Int8)->()
Instead of the expected 65536 parameters.
This is because the function type metadata in swift has a limit of 65535 parameters.
The compiler should flag this as an error.
I'm fairly certain you will get a similar error if you use a tuple type instead of a function type.
The text was updated successfully, but these errors were encountered: