13 lines
148 B
Text
13 lines
148 B
Text
|
// Test types in a Cast
|
||
|
// cannot cast an int to an boolean
|
||
|
|
||
|
class Main {
|
||
|
void main() {
|
||
|
int a;
|
||
|
boolean b;
|
||
|
a = 1;
|
||
|
|
||
|
b = (boolean) a;
|
||
|
}
|
||
|
}
|