-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Closed
Labels
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.A deviation from expected or documented behavior. Also: expected but undesirable behavior.compilerThe Swift compiler itselfThe Swift compiler itselfoptimized onlyFlag: An issue whose reproduction requires optimized compilationFlag: An issue whose reproduction requires optimized compilation
Description
Previous ID | SR-452 |
Radar | None |
Original Reporter | loic (JIRA User) |
Type | Bug |
Environment
Swift 2.2-dev (December 31)
OS X El Capitan
Additional Detail from JIRA
Votes | 1 |
Component/s | Compiler |
Labels | Bug, OptimizedOnly |
Assignee | None |
Priority | Medium |
md5: 546cfc45f510272795c24cb4aa0daa3d
Issue Description:
This code will crash (segfault) when compiled with -Onone, but returns garbage when compiled with -O.
func rec(x: Int) -> Int {
return rec(x)
}
print(rec(0))
I think it should always crash.
Metadata
Metadata
Assignees
Labels
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.A deviation from expected or documented behavior. Also: expected but undesirable behavior.compilerThe Swift compiler itselfThe Swift compiler itselfoptimized onlyFlag: An issue whose reproduction requires optimized compilationFlag: An issue whose reproduction requires optimized compilation