|
| 1 | +-- Error: tests/neg/i5525.scala:1:0 ------------------------------------------------------------------------------------ |
| 2 | +1 |abstract enum Foo1 { case C } // error: only access modifiers allowed |
| 3 | + |^^^^^^^^ |
| 4 | + |This modifier is not allowed on an enum |
| 5 | +-- Error: tests/neg/i5525.scala:2:0 ------------------------------------------------------------------------------------ |
| 6 | +2 |final enum Foo2 { case C } // error: only access modifiers allowed |
| 7 | + |^^^^^ |
| 8 | + |This modifier is not allowed on an enum |
| 9 | +-- Error: tests/neg/i5525.scala:3:0 ------------------------------------------------------------------------------------ |
| 10 | +3 |sealed enum Foo3 { case C } // error: only access modifiers allowed |
| 11 | + |^^^^^^ |
| 12 | + |This modifier is not allowed on an enum |
| 13 | +-- Error: tests/neg/i5525.scala:4:0 ------------------------------------------------------------------------------------ |
| 14 | +4 |implicit enum Foo4 { case C } // error: only access modifiers allowed |
| 15 | + |^^^^^^^^ |
| 16 | + |This modifier is not allowed on an enum |
| 17 | +-- Error: tests/neg/i5525.scala:5:0 ------------------------------------------------------------------------------------ |
| 18 | +5 |lazy enum Foo5 { case C } // error: only access modifiers allowed |
| 19 | + |^^^^ |
| 20 | + |This modifier is not allowed on an enum |
| 21 | +-- Error: tests/neg/i5525.scala:6:0 ------------------------------------------------------------------------------------ |
| 22 | +6 |override enum Foo7 { case C } // error: only access modifiers allowed |
| 23 | + |^^^^^^^^ |
| 24 | + |This modifier is not allowed on an enum |
| 25 | +-- Error: tests/neg/i5525.scala:7:0 ------------------------------------------------------------------------------------ |
| 26 | +7 |inline enum Foo8 { case C } // error: only access modifiers allowed |
| 27 | + |^^^^^^ |
| 28 | + |This modifier is not allowed on an enum |
| 29 | +-- Error: tests/neg/i5525.scala:8:0 ------------------------------------------------------------------------------------ |
| 30 | +8 |opaque enum Foo9 { case C } // error: only access modifiers allowed |
| 31 | + |^^^^^^ |
| 32 | + |This modifier is not allowed on an enum |
| 33 | +-- Error: tests/neg/i5525.scala:11:2 ----------------------------------------------------------------------------------- |
| 34 | +11 | abstract case C1() // error: only access modifiers allowed |
| 35 | + | ^^^^^^^^ |
| 36 | + | This modifier is not allowed on an enum case |
| 37 | +-- Error: tests/neg/i5525.scala:12:2 ----------------------------------------------------------------------------------- |
| 38 | +12 | final case C2() // error: only access modifiers allowed |
| 39 | + | ^^^^^ |
| 40 | + | This modifier is not allowed on an enum case |
| 41 | +-- Error: tests/neg/i5525.scala:13:2 ----------------------------------------------------------------------------------- |
| 42 | +13 | sealed case C3() // error: only access modifiers allowed |
| 43 | + | ^^^^^^ |
| 44 | + | This modifier is not allowed on an enum case |
| 45 | +-- Error: tests/neg/i5525.scala:14:2 ----------------------------------------------------------------------------------- |
| 46 | +14 | implicit case C4() // error: only access modifiers allowed |
| 47 | + | ^^^^^^^^ |
| 48 | + | This modifier is not allowed on an enum case |
| 49 | +-- Error: tests/neg/i5525.scala:15:2 ----------------------------------------------------------------------------------- |
| 50 | +15 | lazy case C5() // error: only access modifiers allowed |
| 51 | + | ^^^^ |
| 52 | + | This modifier is not allowed on an enum case |
| 53 | +-- Error: tests/neg/i5525.scala:16:2 ----------------------------------------------------------------------------------- |
| 54 | +16 | override case C7() // error: only access modifiers allowed |
| 55 | + | ^^^^^^^^ |
| 56 | + | This modifier is not allowed on an enum case |
| 57 | +-- Error: tests/neg/i5525.scala:22:2 ----------------------------------------------------------------------------------- |
| 58 | +22 | abstract case C1 // error: only access modifiers allowed |
| 59 | + | ^^^^^^^^ |
| 60 | + | This modifier is not allowed on an enum case |
| 61 | +-- Error: tests/neg/i5525.scala:23:2 ----------------------------------------------------------------------------------- |
| 62 | +23 | final case C2 // error: only access modifiers allowed |
| 63 | + | ^^^^^ |
| 64 | + | This modifier is not allowed on an enum case |
| 65 | +-- Error: tests/neg/i5525.scala:24:2 ----------------------------------------------------------------------------------- |
| 66 | +24 | sealed case C3 // error: only access modifiers allowed |
| 67 | + | ^^^^^^ |
| 68 | + | This modifier is not allowed on an enum case |
| 69 | +-- Error: tests/neg/i5525.scala:25:2 ----------------------------------------------------------------------------------- |
| 70 | +25 | implicit case C4 // error: only access modifiers allowed |
| 71 | + | ^^^^^^^^ |
| 72 | + | This modifier is not allowed on an enum case |
| 73 | +-- Error: tests/neg/i5525.scala:26:2 ----------------------------------------------------------------------------------- |
| 74 | +26 | lazy case C5 // error: only access modifiers allowed |
| 75 | + | ^^^^ |
| 76 | + | This modifier is not allowed on an enum case |
| 77 | +-- Error: tests/neg/i5525.scala:27:2 ----------------------------------------------------------------------------------- |
| 78 | +27 | override case C7 // error: only access modifiers allowed |
| 79 | + | ^^^^^^^^ |
| 80 | + | This modifier is not allowed on an enum case |
| 81 | +-- Error: tests/neg/i5525.scala:33:12 ---------------------------------------------------------------------------------- |
| 82 | +33 | inline case C10() // error: only access modifiers allowed |
| 83 | + | ^^^^ |
| 84 | + | end of statement expected but 'case' found |
| 85 | +-- Error: tests/neg/i5525.scala:36:0 ----------------------------------------------------------------------------------- |
| 86 | +36 |final enum Foo13 { // error: only access modifiers and `into` allowed |
| 87 | + |^^^^^ |
| 88 | + |This modifier is not allowed on an enum |
| 89 | +-- Error: tests/neg/i5525.scala:42:8 ----------------------------------------------------------------------------------- |
| 90 | +42 | infix case C2 extends Foo14[Int, Int] // error // error |
| 91 | + | ^^^^ |
| 92 | + | end of statement expected but 'case' found |
| 93 | +-- Error: tests/neg/i5525.scala:49:7 ----------------------------------------------------------------------------------- |
| 94 | +49 | into case C1 // error |
| 95 | + | ^^^^ |
| 96 | + | end of statement expected but 'case' found |
| 97 | +-- [E145] Syntax Error: tests/neg/i5525.scala:32:5 --------------------------------------------------------------------- |
| 98 | +32 |enum Foo12 { // error: Enumerations must contain at least one case |
| 99 | + | ^^^^^ |
| 100 | + | Enumerations must contain at least one case |
| 101 | + | |
| 102 | + | longer explanation available when compiling with `-explain` |
| 103 | +-- [E006] Not Found Error: tests/neg/i5525.scala:42:2 ------------------------------------------------------------------ |
| 104 | +42 | infix case C2 extends Foo14[Int, Int] // error // error |
| 105 | + | ^^^^^ |
| 106 | + | Not found: infix |
| 107 | + | |
| 108 | + | longer explanation available when compiling with `-explain` |
| 109 | +-- [E129] Potential Issue Warning: tests/neg/i5525.scala:49:2 ---------------------------------------------------------- |
| 110 | +49 | into case C1 // error |
| 111 | + | ^^^^ |
| 112 | + | A pure expression does nothing in statement position |
| 113 | + | |
| 114 | + | longer explanation available when compiling with `-explain` |
0 commit comments