2007-12-01 00:00:00 +00:00
|
|
|
/*
|
2014-10-01 21:15:40 +00:00
|
|
|
* @test /nodynamiccopyright/
|
|
|
|
* @bug 4035346 4097402
|
2007-12-01 00:00:00 +00:00
|
|
|
* @summary Compiler used to allow this initialization, despite the overflow.
|
|
|
|
* @author turnidge
|
|
|
|
*
|
2014-10-01 21:15:40 +00:00
|
|
|
* @compile/fail/ref=UncaughtOverflow.out -XDrawDiagnostics UncaughtOverflow.java
|
2007-12-01 00:00:00 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
public
|
|
|
|
class UncaughtOverflow {
|
2014-10-01 21:15:40 +00:00
|
|
|
int i1 = 100000000000;
|
|
|
|
int i2 = -2147483649;
|
2007-12-01 00:00:00 +00:00
|
|
|
}
|