Wed, 27 Jul 2011 19:01:33 +0100
7057297: Project Coin: diamond erroneously accepts in array initializer expressions
Summary: Diamond in array initializer expressions should be rejected
Reviewed-by: jjg
1 #
2 # Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved.
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 #
5 # This code is free software; you can redistribute it and/or modify it
6 # under the terms of the GNU General Public License version 2 only, as
7 # published by the Free Software Foundation. Oracle designates this
8 # particular file as subject to the "Classpath" exception as provided
9 # by Oracle in the LICENSE file that accompanied this code.
10 #
11 # This code is distributed in the hope that it will be useful, but WITHOUT
12 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 # version 2 for more details (a copy is included in the LICENSE file that
15 # accompanied this code).
16 #
17 # You should have received a copy of the GNU General Public License version
18 # 2 along with this work; if not, write to the Free Software Foundation,
19 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20 #
21 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22 # or visit www.oracle.com if you need additional information or have any
23 # questions.
24 #
26 # Messages in this file which use "placeholders" for values (e.g. {0}, {1})
27 # are preceded by a stylized comment describing the type of the corresponding
28 # values.
29 # The types currently in use are
30 #
31 # boolean true or false
32 # file name the name of an input file; e.g. MyFile.java
33 # message segment a sub-message; see compiler.misc.*
34 # modifier a Java modifier; e.g. public, private, protected
35 # name a name, typically a Java identifier
36 # number an integer
37 # option name the name of a command line option
38 # source version a source version number, such as 1.5, 1.6, 1.7
39 # string a general string
40 # symbol the name of a declared type
41 # symbol kind a description of the kind of a declaration; see compiler.misc.kindname.*
42 # token the name of a non-terminal in source code; see compiler.misc.token.*
43 # type a Java type; e.g. int, X, X<T>
44 # unused the value is not used in this message
45 #
46 # list of X a comma-separated list of items; e.g. list of type
47 # X or Y alternation; e.g. message segment or type
48 # set of X a comma-separated collection of items; e.g. set of modifier
49 #
50 # These may be composed: e.g. list of type or message segment
51 #
52 # These comments are verified by the jtreg test test/tools/javac/diags/MessageInfo,
53 # using info derived from the collected set of examples in test/tools/javac/diags/examples.
54 # MessageInfo can also be run as a standalone utility providing more facilities
55 # for manipulating this file. For more details, see MessageInfo.java.
57 ##
58 ## errors
59 ##
61 # 0: symbol
62 compiler.err.abstract.cant.be.instantiated=\
63 {0} is abstract; cannot be instantiated
65 compiler.err.abstract.meth.cant.have.body=\
66 abstract methods cannot have a body
68 compiler.err.already.annotated=\
69 {0} {1} has already been annotated
71 # 0: symbol, 1: symbol
72 compiler.err.already.defined=\
73 {0} is already defined in {1}
75 # 0: string
76 compiler.err.already.defined.single.import=\
77 {0} is already defined in a single-type import
79 # 0: string
80 compiler.err.already.defined.static.single.import=\
81 {0} is already defined in a static single-type import
83 compiler.err.already.defined.this.unit=\
84 {0} is already defined in this compilation unit
86 # 0: type, 1: list of name
87 compiler.err.annotation.missing.default.value=\
88 annotation {0} is missing value for the attribute {1}
90 # 0: type, 1: list of name
91 compiler.err.annotation.missing.default.value.1=\
92 annotation {0} is missing values for attributes {1}
94 # 0: type
95 compiler.err.annotation.not.valid.for.type=\
96 annotation not valid for a value of type {0}
98 compiler.err.annotation.type.not.applicable=\
99 annotation type not applicable to this kind of declaration
101 compiler.err.annotation.value.must.be.annotation=\
102 annotation value must be an annotation
104 compiler.err.annotation.value.must.be.class.literal=\
105 annotation value must be a class literal
107 compiler.err.annotation.value.must.be.name.value=\
108 annotation values must be of the form ''name=value''
110 compiler.err.annotation.value.not.allowable.type=\
111 annotation value not of an allowable type
113 compiler.err.anon.class.impl.intf.no.args=\
114 anonymous class implements interface; cannot have arguments
116 compiler.err.anon.class.impl.intf.no.typeargs=\
117 anonymous class implements interface; cannot have type arguments
119 compiler.err.anon.class.impl.intf.no.qual.for.new=\
120 anonymous class implements interface; cannot have qualifier for new
122 # 0: symbol, 1: symbol, 2: symbol
123 compiler.err.array.and.varargs=\
124 cannot declare both {0} and {1} in {2}
126 compiler.err.array.dimension.missing=\
127 array dimension missing
129 # 0: type
130 compiler.err.array.req.but.found=\
131 array required, but {0} found
133 compiler.err.assignment.from.super-bound=\
134 assigning from wildcard {0}
136 compiler.err.assignment.to.extends-bound=\
137 assigning to wildcard {0}
139 compiler.err.attribute.value.must.be.constant=\
140 attribute value must be constant
142 compiler.err.break.outside.switch.loop=\
143 break outside switch or loop
145 # 0: name
146 compiler.err.call.must.be.first.stmt.in.ctor=\
147 call to {0} must be first statement in constructor
149 compiler.err.cant.apply.symbol=\
150 {0} {1} in {4} {5} cannot be applied to given types\n\
151 required: {2}\n\
152 found: {3}
154 # 0: symbol kind, 1: name, 2: list of type or message segment, 3: list of type or message segment, 4: symbol kind, 5: type, 6: message segment
155 compiler.err.cant.apply.symbol.1=\
156 {0} {1} in {4} {5} cannot be applied to given types;\n\
157 required: {2}\n\
158 found: {3}\n\
159 reason: {6}
161 # 0: symbol kind, 1: name, 2: list of type
162 compiler.err.cant.apply.symbols=\
163 no suitable {0} found for {1}({2})
165 # 0: symbol
166 compiler.err.cant.assign.val.to.final.var=\
167 cannot assign a value to final variable {0}
169 # 0: type
170 compiler.err.cant.deref=\
171 {0} cannot be dereferenced
173 compiler.err.cant.extend.intf.annotation=\
174 ''extends'' not allowed for @interfaces
176 # 0: symbol
177 compiler.err.cant.inherit.from.final=\
178 cannot inherit from final {0}
180 # 0: symbol
181 compiler.err.cant.ref.before.ctor.called=\
182 cannot reference {0} before supertype constructor has been called
184 compiler.err.cant.ret.val.from.meth.decl.void=\
185 cannot return a value from method whose result type is void
187 compiler.err.cant.select.static.class.from.param.type=\
188 cannot select a static class from a parameterized type
190 # 0: symbol, 1: string, 2: string
191 compiler.err.cant.inherit.diff.arg=\
192 {0} cannot be inherited with different arguments: <{1}> and <{2}>
194 compiler.err.catch.without.try=\
195 ''catch'' without ''try''
197 # 0: symbol kind, 1: symbol
198 compiler.err.clash.with.pkg.of.same.name=\
199 {0} {1} clashes with package of same name
201 compiler.err.const.expr.req=\
202 constant expression required
204 compiler.err.cont.outside.loop=\
205 continue outside of loop
207 # 0: symbol
208 compiler.err.cyclic.inheritance=\
209 cyclic inheritance involving {0}
211 compiler.err.cyclic.annotation.element=\
212 cyclic annotation element type
214 # 0: unused
215 compiler.err.call.to.super.not.allowed.in.enum.ctor=\
216 call to super not allowed in enum constructor
218 # 0: type
219 compiler.err.no.superclass=\
220 {0} has no superclass
222 compiler.err.wrong.target.for.polymorphic.signature.definition=\
223 MethodHandle API building requires -target 7 runtimes or better; current is -target {0}
225 # 0: symbol, 1: type, 2: symbol, 3: type, 4: unused
226 compiler.err.concrete.inheritance.conflict=\
227 methods {0} from {1} and {2} from {3} are inherited with the same signature
229 compiler.err.default.allowed.in.intf.annotation.member=\
230 default value only allowed in an @interface member
232 # 0: symbol
233 compiler.err.doesnt.exist=\
234 package {0} does not exist
236 compiler.err.duplicate.annotation=\
237 duplicate annotation
239 # 0: name, 1: type
240 compiler.err.duplicate.annotation.member.value=\
241 duplicate annotation member value {0} in {1}
243 # 0: name
244 compiler.err.duplicate.class=\
245 duplicate class: {0}
247 compiler.err.duplicate.case.label=\
248 duplicate case label
250 compiler.err.duplicate.default.label=\
251 duplicate default label
253 compiler.err.else.without.if=\
254 ''else'' without ''if''
256 compiler.err.empty.char.lit=\
257 empty character literal
259 # 0: symbol
260 compiler.err.encl.class.required=\
261 an enclosing instance that contains {0} is required
263 compiler.err.enum.annotation.must.be.enum.constant=\
264 an enum annotation value must be an enum constant
266 compiler.err.enum.cant.be.instantiated=\
267 enum types may not be instantiated
269 compiler.err.enum.label.must.be.unqualified.enum=\
270 an enum switch case label must be the unqualified name of an enumeration constant
272 compiler.err.enum.no.subclassing=\
273 classes cannot directly extend java.lang.Enum
275 compiler.err.enum.types.not.extensible=\
276 enum types are not extensible
278 compiler.err.enum.no.finalize=\
279 enums cannot have finalize methods
281 # 0: file name, 1: string
282 compiler.err.error.reading.file=\
283 error reading {0}; {1}
285 # 0: type
286 compiler.err.except.already.caught=\
287 exception {0} has already been caught
289 # 0: type
290 compiler.err.except.never.thrown.in.try=\
291 exception {0} is never thrown in body of corresponding try statement
293 # 0: symbol
294 compiler.err.final.parameter.may.not.be.assigned=\
295 final parameter {0} may not be assigned
297 # 0: symbol
298 compiler.err.try.resource.may.not.be.assigned=\
299 auto-closeable resource {0} may not be assigned
301 # 0: symbol
302 compiler.err.multicatch.parameter.may.not.be.assigned=\
303 multi-catch parameter {0} may not be assigned
305 # 0: type, 1: type
306 compiler.err.multicatch.types.must.be.disjoint=\
307 Alternatives in a multi-catch statement cannot be related by subclassing\n\
308 Alternative {0} is a subclass of alternative {1}
310 compiler.err.finally.without.try=\
311 ''finally'' without ''try''
313 # 0: type, 1: message segment
314 compiler.err.foreach.not.applicable.to.type=\
315 for-each not applicable to expression type\n\
316 required: {1}\n\
317 found: {0}
319 compiler.err.fp.number.too.large=\
320 floating point number too large
322 compiler.err.fp.number.too.small=\
323 floating point number too small
325 compiler.err.generic.array.creation=\
326 generic array creation
328 compiler.err.generic.throwable=\
329 a generic class may not extend java.lang.Throwable
331 # 0: symbol
332 compiler.err.icls.cant.have.static.decl=\
333 Illegal static declaration in inner class {0}\n\
334 modifier \''static\'' is only allowed in constant variable declarations
336 # 0: string
337 compiler.err.illegal.char=\
338 illegal character: \\{0}
340 compiler.err.illegal.char.for.encoding=\
341 unmappable character for encoding {0}
343 # 0: set of modifier, 1: set of modifier
344 compiler.err.illegal.combination.of.modifiers=\
345 illegal combination of modifiers: {0} and {1}
347 compiler.err.illegal.enum.static.ref=\
348 illegal reference to static field from initializer
350 compiler.err.illegal.esc.char=\
351 illegal escape character
353 compiler.err.illegal.forward.ref=\
354 illegal forward reference
356 # 0: symbol
357 compiler.warn.forward.ref=\
358 reference to variable ''{0}'' before it has been initialized
360 compiler.err.illegal.self.ref=\
361 self-reference in initializer
363 # 0: symbol
364 compiler.warn.self.ref=\
365 self-reference in initializer of variable ''{0}''
367 compiler.err.illegal.generic.type.for.instof=\
368 illegal generic type for instanceof
370 # 0: type
371 compiler.err.illegal.initializer.for.type=\
372 illegal initializer for {0}
374 compiler.err.illegal.line.end.in.char.lit=\
375 illegal line end in character literal
377 compiler.err.illegal.nonascii.digit=\
378 illegal non-ASCII digit
380 compiler.err.illegal.underscore=\
381 illegal underscore
383 # 0: symbol
384 compiler.err.illegal.qual.not.icls=\
385 illegal qualifier; {0} is not an inner class
387 compiler.err.illegal.start.of.expr=\
388 illegal start of expression
390 compiler.err.illegal.start.of.type=\
391 illegal start of type
393 compiler.err.illegal.unicode.esc=\
394 illegal unicode escape
396 # 0: symbol
397 compiler.err.import.requires.canonical=\
398 import requires canonical name for {0}
400 compiler.err.improperly.formed.type.param.missing=\
401 improperly formed type, some parameters are missing
403 compiler.err.improperly.formed.type.inner.raw.param=\
404 improperly formed type, type arguments given on a raw type
406 # 0: type, 1: type
407 compiler.err.incomparable.types=\
408 incomparable types: {0} and {1}
410 # 0: number
411 compiler.err.int.number.too.large=\
412 integer number too large: {0}
414 compiler.err.internal.error.cant.instantiate=\
415 internal error; cannot instantiate {0} at {1} to ({2})
417 compiler.err.intf.annotation.members.cant.have.params=\
418 @interface members may not have parameters
420 compiler.err.intf.annotation.cant.have.type.params=\
421 @interface may not have type parameters
423 compiler.err.intf.annotation.members.cant.have.type.params=\
424 @interface members may not have type parameters
426 # 0: symbol, 1: type
427 compiler.err.intf.annotation.member.clash=\
428 @interface member clashes with method ''{0}'' in {1}
430 compiler.err.intf.expected.here=\
431 interface expected here
433 compiler.err.intf.meth.cant.have.body=\
434 interface methods cannot have body
436 compiler.err.invalid.annotation.member.type=\
437 invalid type for annotation member
439 compiler.err.invalid.binary.number=\
440 binary numbers must contain at least one binary digit
442 compiler.err.invalid.hex.number=\
443 hexadecimal numbers must contain at least one hexadecimal digit
445 compiler.err.invalid.meth.decl.ret.type.req=\
446 invalid method declaration; return type required
448 compiler.err.varargs.and.old.array.syntax=\
449 legacy array notation not allowed on variable-arity parameter
451 # 0: name
452 compiler.err.label.already.in.use=\
453 label {0} already in use
455 # 0: symbol
456 compiler.err.local.var.accessed.from.icls.needs.final=\
457 local variable {0} is accessed from within inner class; needs to be declared final
459 compiler.err.local.enum=\
460 enum types must not be local
462 compiler.err.cannot.create.array.with.type.arguments=\
463 cannot create array with type arguments
465 compiler.err.cannot.create.array.with.diamond=\
466 cannot create array with ''<>''
468 #
469 # limits. We don't give the limits in the diagnostic because we expect
470 # them to change, yet we want to use the same diagnostic. These are all
471 # detected during code generation.
472 #
473 compiler.err.limit.code=\
474 code too large
476 compiler.err.limit.code.too.large.for.try.stmt=\
477 code too large for try statement
479 compiler.err.limit.dimensions=\
480 array type has too many dimensions
482 compiler.err.limit.locals=\
483 too many local variables
485 compiler.err.limit.parameters=\
486 too many parameters
488 compiler.err.limit.pool=\
489 too many constants
491 compiler.err.limit.pool.in.class=\
492 too many constants in class {0}
494 compiler.err.limit.stack=\
495 code requires too much stack
497 compiler.err.limit.string=\
498 constant string too long
500 compiler.err.limit.string.overflow=\
501 UTF8 representation for string \"{0}...\" is too long for the constant pool
503 compiler.err.malformed.fp.lit=\
504 malformed floating point literal
506 compiler.err.method.does.not.override.superclass=\
507 method does not override or implement a method from a supertype
509 compiler.err.missing.meth.body.or.decl.abstract=\
510 missing method body, or declare abstract
512 compiler.err.missing.ret.stmt=\
513 missing return statement
515 compiler.err.missing.ret.val=\
516 missing return value
518 # 0: set of modifier
519 compiler.err.mod.not.allowed.here=\
520 modifier {0} not allowed here
522 compiler.err.intf.not.allowed.here=\
523 interface not allowed here
525 compiler.err.enums.must.be.static=\
526 enum declarations allowed only in static contexts
528 # 0: symbol, 1: symbol
529 compiler.err.name.clash.same.erasure=\
530 name clash: {0} and {1} have the same erasure
532 # 0: symbol, 1: symbol, 2: symbol, 3: symbol, 4: unused, 5: unused
533 compiler.err.name.clash.same.erasure.no.override=\
534 name clash: {0} in {1} and {2} in {3} have the same erasure, yet neither overrides the other
536 # 0: symbol, 1: symbol, 2: symbol, 3: symbol, 4: symbol, 5: symbol
537 compiler.err.name.clash.same.erasure.no.override.1=\
538 name clash: {0} in {1} overrides a method whose erasure is the same as another method, yet neither overrides the other\n\
539 first method: {2} in {3}\n\
540 second method: {4} in {5}
542 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
543 compiler.err.name.clash.same.erasure.no.hide=\
544 name clash: {0} in {1} and {2} in {3} have the same erasure, yet neither hides the other
546 compiler.err.name.reserved.for.internal.use=\
547 {0} is reserved for internal use
549 compiler.err.native.meth.cant.have.body=\
550 native methods cannot have a body
552 # 0: type, 1: type
553 compiler.err.neither.conditional.subtype=\
554 incompatible types for ?: neither is a subtype of the other\n\
555 second operand: {0}\n\
556 third operand : {1}
558 compiler.err.new.not.allowed.in.annotation=\
559 ''new'' not allowed in an annotation
561 compiler.err.no.annotation.member=\
562 no annotation member {0} in {1}
564 compiler.err.no.encl.instance.of.type.in.scope=\
565 no enclosing instance of type {0} is in scope
567 compiler.err.no.intf.expected.here=\
568 no interface expected here
570 compiler.err.no.match.entry=\
571 {0} has no match in entry in {1}; required {2}
573 compiler.err.not.annotation.type=\
574 {0} is not an annotation type
576 # 0: symbol, 1: symbol
577 compiler.err.not.def.access.class.intf.cant.access=\
578 {0} in {1} is defined in an inaccessible class or interface
580 # 0: symbol, 1: symbol
581 compiler.err.not.def.public.cant.access=\
582 {0} is not public in {1}; cannot be accessed from outside package
584 # 0: name
585 compiler.err.not.loop.label=\
586 not a loop label: {0}
588 compiler.err.not.stmt=\
589 not a statement
591 # 0: symbol
592 compiler.err.not.encl.class=\
593 not an enclosing class: {0}
595 # 0: name, 1: type, 2: unused
596 compiler.err.operator.cant.be.applied=\
597 bad operand type {1} for unary operator ''{0}''
599 # 0: name, 1: type, 2: type
600 compiler.err.operator.cant.be.applied.1=\
601 bad operand types for binary operator ''{0}''\n\
602 first type: {1}\n\
603 second type: {2}
605 compiler.err.pkg.annotations.sb.in.package-info.java=\
606 package annotations should be in file package-info.java
608 # 0: symbol
609 compiler.err.pkg.clashes.with.class.of.same.name=\
610 package {0} clashes with class of same name
612 compiler.err.warnings.and.werror=\
613 warnings found and -Werror specified
615 # Errors related to annotation processing
617 # 0: symbol, 1: string, 2: stack-trace
618 compiler.err.proc.cant.access=\
619 cannot access {0}\n\
620 {1}\n\
621 Consult the following stack trace for details.\n\
622 {2}
624 # 0: symbol, 1: string
625 compiler.err.proc.cant.access.1=\
626 cannot access {0}\n\
627 {1}
629 # 0: string
630 compiler.err.proc.cant.find.class=\
631 Could not find class file for ''{0}''.
633 # Print a client-generated error message; assumed to be localized, no translation required
634 # 0: string
635 compiler.err.proc.messager=\
636 {0}
638 # 0: list of string
639 compiler.err.proc.no.explicit.annotation.processing.requested=\
640 Class names, ''{0}'', are only accepted if annotation processing is explicitly requested
642 compiler.err.proc.no.service=\
643 A ServiceLoader was not usable and is required for annotation processing.
645 compiler.err.proc.processor.bad.option.name=\
646 Bad option name ''{0}'' provided by processor ''{1}''
648 # 0: string
649 compiler.err.proc.processor.cant.instantiate=\
650 Could not instantiate an instance of processor ''{0}''
652 # 0: string
653 compiler.err.proc.processor.not.found=\
654 Annotation processor ''{0}'' not found
656 # 0: string
657 compiler.err.proc.processor.wrong.type=\
658 Annotation processor ''{0}'' does not implement javax.annotation.processing.Processor
660 compiler.err.proc.service.problem=\
661 Error creating a service loader to load Processors.
663 compiler.err.proc.bad.config.file=\
664 Bad service configuration file, or exception thrown while constructing Processor object: {0}
666 compiler.err.proc.cant.create.loader=\
667 Could not create class loader for annotation processors: {0}
669 # 0: unused
670 compiler.err.qualified.new.of.static.class=\
671 qualified new of static class
673 compiler.err.recursive.ctor.invocation=\
674 recursive constructor invocation
676 # 0: name, 1: symbol kind, 2: symbol, 3: symbol, 4: symbol kind, 5: symbol, 6: symbol
677 compiler.err.ref.ambiguous=\
678 reference to {0} is ambiguous, both {1} {2} in {3} and {4} {5} in {6} match
680 compiler.err.repeated.annotation.target=\
681 repeated annotation target
683 compiler.err.repeated.interface=\
684 repeated interface
686 compiler.err.repeated.modifier=\
687 repeated modifier
689 # 0: symbol, 1: set of modifier, 2: symbol
690 compiler.err.report.access=\
691 {0} has {1} access in {2}
693 compiler.err.ret.outside.meth=\
694 return outside method
696 compiler.err.signature.doesnt.match.supertype=\
697 signature does not match {0}; incompatible supertype
699 compiler.err.signature.doesnt.match.intf=\
700 signature does not match {0}; incompatible interfaces
702 # 0: symbol, 1: symbol, 2: symbol
703 compiler.err.does.not.override.abstract=\
704 {0} is not abstract and does not override abstract method {1} in {2}
706 compiler.err.source.cant.overwrite.input.file=\
707 error writing source; cannot overwrite input file {0}
709 compiler.err.stack.sim.error=\
710 Internal error: stack sim error on {0}
712 compiler.err.static.imp.only.classes.and.interfaces=\
713 static import only from classes and interfaces
715 compiler.err.string.const.req=\
716 constant string expression required
718 # 0: symbol, 1: symbol
719 compiler.err.synthetic.name.conflict=\
720 the symbol {0} conflicts with a compiler-synthesized symbol in {1}
722 # 0: symbol, 1: symbol
723 compiler.warn.synthetic.name.conflict=\
724 the symbol {0} conflicts with a compiler-synthesized symbol in {1}
726 compiler.err.throws.not.allowed.in.intf.annotation=\
727 throws clause not allowed in @interface members
729 compiler.err.try.without.catch.or.finally=\
730 ''try'' without ''catch'' or ''finally''
732 compiler.err.try.without.catch.finally.or.resource.decls=\
733 ''try'' without ''catch'', ''finally'' or resource declarations
735 # 0: symbol
736 compiler.err.type.doesnt.take.params=\
737 type {0} does not take parameters
739 compiler.err.type.var.cant.be.deref=\
740 cannot select from a type variable
742 compiler.err.type.var.may.not.be.followed.by.other.bounds=\
743 a type variable may not be followed by other bounds
745 compiler.err.type.var.more.than.once=\
746 type variable {0} occurs more than once in result type of {1}; cannot be left uninstantiated
748 compiler.err.type.var.more.than.once.in.result=\
749 type variable {0} occurs more than once in type of {1}; cannot be left uninstantiated
751 # 0: type, 1: type, 2: string
752 compiler.err.types.incompatible.diff.ret=\
753 types {0} and {1} are incompatible; both define {2}, but with unrelated return types
755 compiler.err.unclosed.char.lit=\
756 unclosed character literal
758 compiler.err.unclosed.comment=\
759 unclosed comment
761 compiler.err.unclosed.str.lit=\
762 unclosed string literal
764 # 0: name
765 compiler.err.unsupported.encoding=\
766 unsupported encoding: {0}
768 compiler.err.io.exception=\
769 error reading source file: {0}
771 # 0: name
772 compiler.err.undef.label=\
773 undefined label: {0}
775 compiler.err.undetermined.type=\
776 cannot infer type arguments for {0}
778 # 0: type, 1: message segment
779 compiler.err.undetermined.type.1=\
780 cannot infer type arguments for {0};\n\
781 reason: {1}
783 # 0: list of type, 1: message segment
784 compiler.err.invalid.inferred.types=\
785 invalid inferred types for {0}; {1}
787 # 0: message segment, 1: unused
788 compiler.err.cant.apply.diamond=\
789 cannot infer type arguments for {0}
791 # 0: message segment, 1: message segment
792 compiler.err.cant.apply.diamond.1=\
793 cannot infer type arguments for {0};\n\
794 reason: {1}
796 compiler.err.unreachable.stmt=\
797 unreachable statement
799 compiler.err.initializer.must.be.able.to.complete.normally=\
800 initializer must be able to complete normally
802 # 0: type
803 compiler.err.unreported.exception.need.to.catch.or.throw=\
804 unreported exception {0}; must be caught or declared to be thrown
806 # 0: type
807 compiler.err.unreported.exception.default.constructor=\
808 unreported exception {0} in default constructor
810 # 0: type, 1: name
811 compiler.err.unreported.exception.implicit.close=\
812 unreported exception {0}; must be caught or declared to be thrown\n\
813 exception thrown from implicit call to close() on resource variable ''{1}''
815 compiler.err.unsupported.cross.fp.lit=\
816 hexadecimal floating-point literals are not supported on this VM
818 compiler.err.void.not.allowed.here=\
819 ''void'' type not allowed here
821 # 0: string
822 compiler.err.wrong.number.type.args=\
823 wrong number of type arguments; required {0}
825 # 0: symbol
826 compiler.err.var.might.already.be.assigned=\
827 variable {0} might already have been assigned
829 # 0: symbol
830 compiler.err.var.might.not.have.been.initialized=\
831 variable {0} might not have been initialized
833 # 0: symbol
834 compiler.err.var.might.be.assigned.in.loop=\
835 variable {0} might be assigned in loop
837 # 0: symbol, 1: message segment
838 compiler.err.varargs.invalid.trustme.anno=\
839 Invalid {0} annotation. {1}
841 # 0: type
842 compiler.misc.varargs.trustme.on.reifiable.varargs=\
843 Varargs element type {0} is reifiable.
845 # 0: symbol
846 compiler.misc.varargs.trustme.on.non.varargs.meth=\
847 Method {0} is not a varargs method.
849 # 0: symbol
850 compiler.misc.varargs.trustme.on.virtual.varargs=\
851 Instance method {0} is not final.
853 # 0: type, 1: kind, 2: symbol
854 compiler.misc.inaccessible.varargs.type=\
855 formal varargs element type {0} is not accessible from {1} {2}
857 # In the following string, {1} will always be the detail message from
858 # java.io.IOException.
859 # 0: symbol, 1: string
860 compiler.err.class.cant.write=\
861 error while writing {0}: {1}
863 # In the following string, {0} is the name of the class in the Java source.
864 # It really should be used two times..
865 # 0: name
866 compiler.err.class.public.should.be.in.file=\
867 class {0} is public, should be declared in a file named {0}.java
869 ## All errors which do not refer to a particular line in the source code are
870 ## preceded by this string.
871 compiler.err.error=\
872 error:\u0020
874 # The following error messages do not refer to a line in the source code.
875 compiler.err.cant.read.file=\
876 cannot read: {0}
878 #####
880 # Fatal Errors
882 compiler.misc.fatal.err.no.java.lang=\
883 Fatal Error: Unable to find package java.lang in classpath or bootclasspath
885 compiler.misc.fatal.err.cant.locate.meth=\
886 Fatal Error: Unable to find method {0}
888 compiler.misc.fatal.err.cant.locate.field=\
889 Fatal Error: Unable to find field {0}
891 compiler.misc.fatal.err.cant.locate.ctor=\
892 Fatal Error: Unable to find constructor for {0}
894 compiler.misc.fatal.err.cant.close.loader=\
895 Fatal Error: Cannot close class loader for annotation processors
897 #####
899 ##
900 ## miscellaneous strings
901 ##
903 compiler.misc.source.unavailable=\
904 (source unavailable)
906 compiler.misc.base.membership=\
907 all your base class are belong to us
909 # 0: string, 1: string, 2: boolean
910 compiler.misc.x.print.processor.info=\
911 Processor {0} matches {1} and returns {2}.
913 # 0: number, 1: string, 2: set of symbol, 3: boolean
914 compiler.misc.x.print.rounds=\
915 Round {0}:\n\tinput files: {1}\n\tannotations: {2}\n\tlast round: {3}
917 #####
919 ## The following string will appear before all messages keyed as:
920 ## "compiler.note".
921 compiler.note.note=\
922 Note:\u0020
924 # 0: file name
925 compiler.note.deprecated.filename=\
926 {0} uses or overrides a deprecated API.
928 compiler.note.deprecated.plural=\
929 Some input files use or override a deprecated API.
931 # The following string may appear after one of the above deprecation
932 # messages.
933 compiler.note.deprecated.recompile=\
934 Recompile with -Xlint:deprecation for details.
936 # 0: file name
937 compiler.note.deprecated.filename.additional=\
938 {0} has additional uses or overrides of a deprecated API.
940 compiler.note.deprecated.plural.additional=\
941 Some input files additionally use or override a deprecated API.
943 # 0: file name
944 compiler.note.unchecked.filename=\
945 {0} uses unchecked or unsafe operations.
947 compiler.note.unchecked.plural=\
948 Some input files use unchecked or unsafe operations.
950 # The following string may appear after one of the above deprecation
951 # messages.
952 compiler.note.unchecked.recompile=\
953 Recompile with -Xlint:unchecked for details.
955 # 0: file name
956 compiler.note.unchecked.filename.additional=\
957 {0} has additional unchecked or unsafe operations.
959 compiler.note.unchecked.plural.additional=\
960 Some input files additionally use unchecked or unsafe operations.
962 # 0: file name
963 compiler.note.sunapi.filename=\
964 {0} uses internal proprietary API that may be removed in a future release.
966 compiler.note.sunapi.plural=\
967 Some input files use internal proprietary API that may be removed in a future release.
969 # The following string may appear after one of the above sunapi messages.
970 compiler.note.sunapi.recompile=\
971 Recompile with -Xlint:sunapi for details.
973 # 0: file name
974 compiler.note.sunapi.filename.additional=\
975 {0} uses additional internal proprietary API that may be removed in a future release.
977 compiler.note.sunapi.plural.additional=\
978 Some input files additionally use internal proprietary API that may be removed in a future release.
980 # Notes related to annotation processing
982 # Print a client-generated note; assumed to be localized, no translation required
983 # 0: string
984 compiler.note.proc.messager=\
985 {0}
987 #####
989 # 0: number
990 compiler.misc.count.error=\
991 {0} error
993 # 0: number
994 compiler.misc.count.error.plural=\
995 {0} errors
997 # 0: number
998 compiler.misc.count.warn=\
999 {0} warning
1001 # 0: number
1002 compiler.misc.count.warn.plural=\
1003 {0} warnings
1005 compiler.misc.version.not.available=\
1006 (version info not available)
1008 ## extra output when using -verbose (JavaCompiler)
1010 # 0: symbol
1011 compiler.misc.verbose.checking.attribution=\
1012 [checking {0}]
1014 # 0: string
1015 compiler.misc.verbose.parsing.done=\
1016 [parsing completed {0}ms]
1018 # 0: file name
1019 compiler.misc.verbose.parsing.started=\
1020 [parsing started {0}]
1022 # 0: string
1023 compiler.misc.verbose.total=\
1024 [total {0}ms]
1026 # 0: file name
1027 compiler.misc.verbose.wrote.file=\
1028 [wrote {0}]
1030 ## extra output when using -verbose (Retro)
1031 compiler.misc.verbose.retro=\
1032 [retrofitting {0}]
1034 compiler.misc.verbose.retro.with=\
1035 \tretrofitting {0} with {1}
1037 compiler.misc.verbose.retro.with.list=\
1038 \tretrofitting {0} with type parameters {1}, supertype {2}, interfaces {3}
1040 ## extra output when using -verbose (code/ClassReader)
1041 # 0: string
1042 compiler.misc.verbose.loading=\
1043 [loading {0}]
1045 # 0: string
1046 compiler.misc.verbose.sourcepath=\
1047 [search path for source files: {0}]
1049 # 0: string
1050 compiler.misc.verbose.classpath=\
1051 [search path for class files: {0}]
1053 ## extra output when using -checkclassfile (code/ClassReader)
1054 compiler.misc.ccf.found.later.version=\
1055 class file has later version than expected: {0}
1057 compiler.misc.ccf.unrecognized.attribute=\
1058 unrecognized attribute: {0}
1060 ## extra output when using -prompt (util/Log)
1061 compiler.misc.resume.abort=\
1062 R)esume, A)bort>
1064 #####
1066 ##
1067 ## warnings
1068 ##
1070 ## All warning messages are preceded by the following string.
1071 compiler.warn.warning=\
1072 warning:\u0020
1074 ## Warning messages may also include the following prefix to identify a
1075 ## lint option
1076 # 0: option name
1077 compiler.warn.lintOption=\
1078 [{0}]\u0020
1080 # 0: symbol
1081 compiler.warn.constant.SVUID=\
1082 serialVersionUID must be constant in class {0}
1084 # 0: file name
1085 compiler.warn.dir.path.element.not.found=\
1086 bad path element "{0}": no such directory
1088 compiler.warn.finally.cannot.complete=\
1089 finally clause cannot complete normally
1091 # 0: symbol, 1: symbol
1092 compiler.warn.has.been.deprecated=\
1093 {0} in {1} has been deprecated
1095 # 0: symbol
1096 compiler.warn.sun.proprietary=\
1097 {0} is internal proprietary API and may be removed in a future release
1099 compiler.warn.illegal.char.for.encoding=\
1100 unmappable character for encoding {0}
1102 # 0: symbol
1103 compiler.warn.improper.SVUID=\
1104 serialVersionUID must be declared static final in class {0}
1106 # 0: type, 1: type
1107 compiler.warn.inexact.non-varargs.call=\
1108 non-varargs call of varargs method with inexact argument type for last parameter;\n\
1109 cast to {0} for a varargs call\n\
1110 cast to {1} for a non-varargs call and to suppress this warning
1112 # 0: list of type
1113 compiler.warn.unreachable.catch=\
1114 unreachable catch clause\n\
1115 thrown type {0} has already been caught
1117 # 0: list of type
1118 compiler.warn.unreachable.catch.1=\
1119 unreachable catch clause\n\
1120 thrown types {0} have already been caught
1122 # 0: symbol
1123 compiler.warn.long.SVUID=\
1124 serialVersionUID must be of type long in class {0}
1126 # 0: symbol
1127 compiler.warn.missing.SVUID=\
1128 serializable class {0} has no definition of serialVersionUID
1130 # 0: message segment
1131 compiler.warn.override.varargs.missing=\
1132 {0}; overridden method has no ''...''
1134 # 0: message segment
1135 compiler.warn.override.varargs.extra=\
1136 {0}; overriding method is missing ''...''
1138 compiler.warn.override.bridge=\
1139 {0}; overridden method is a bridge method
1141 # 0: symbol
1142 compiler.warn.pkg-info.already.seen=\
1143 a package-info.java file has already been seen for package {0}
1145 # 0: file name
1146 compiler.warn.path.element.not.found=\
1147 bad path element "{0}": no such file or directory
1149 compiler.warn.possible.fall-through.into.case=\
1150 possible fall-through into case
1152 # 0: type
1153 compiler.warn.redundant.cast=\
1154 redundant cast to {0}
1156 # 0: number
1157 compiler.warn.position.overflow=\
1158 Position encoding overflows at line {0}
1160 # 0: file name, 1: number, 2: number
1161 compiler.warn.big.major.version=\
1162 {0}: major version {1} is newer than {2}, the highest major version supported by this compiler.\n\
1163 It is recommended that the compiler be upgraded.
1165 # 0: symbol kind, 1: symbol
1166 compiler.warn.static.not.qualified.by.type=\
1167 static {0} should be qualified by type name, {1}, instead of by an expression
1169 # 0: string
1170 compiler.warn.source.no.bootclasspath=\
1171 bootstrap class path not set in conjunction with -source {0}
1173 # 0: name, 1: number, 2: number, 3: number, 4: number
1174 compiler.warn.future.attr=\
1175 {0} attribute introduced in version {1}.{2} class files is ignored in version {3}.{4} class files
1177 # Warnings related to annotation processing
1178 # 0: name
1179 compiler.warn.proc.package.does.not.exist=\
1180 package {0} does not exist
1182 # 0: name
1183 compiler.warn.proc.file.reopening=\
1184 Attempt to create a file for ''{0}'' multiple times
1186 # 0: name
1187 compiler.warn.proc.type.already.exists=\
1188 A file for type ''{0}'' already exists on the sourcepath or classpath
1190 # 0: name
1191 compiler.warn.proc.type.recreate=\
1192 Attempt to create a file for type ''{0}'' multiple times
1194 # 0: string
1195 compiler.warn.proc.illegal.file.name=\
1196 Cannot create file for illegal name ''{0}''.
1198 # 0: string, 1: string
1199 compiler.warn.proc.suspicious.class.name=\
1200 Creating file for a type whose name ends in {1}: ''{0}''
1202 # 0: name
1203 compiler.warn.proc.file.create.last.round=\
1204 File for type ''{0}'' created in the last round will not be subject to annotation processing.
1206 # 0: string, 1: string
1207 compiler.warn.proc.malformed.supported.string=\
1208 Malformed string ''{0}'' for a supported annotation type returned by processor ''{1}''
1210 # 0: set of string
1211 compiler.warn.proc.annotations.without.processors=\
1212 No processor claimed any of these annotations: {0}
1214 # 0: source version, 1: string, 2: string
1215 compiler.warn.proc.processor.incompatible.source.version=\
1216 Supported source version ''{0}'' from annotation processor ''{1}'' less than -source ''{2}''
1218 compiler.warn.proc.proc-only.requested.no.procs=\
1219 Annotation processing without compilation requested but no processors were found.
1221 compiler.warn.proc.use.implicit=\
1222 Implicitly compiled files were not subject to annotation processing.\n\
1223 Use -implicit to specify a policy for implicit compilation.
1225 compiler.warn.proc.use.proc.or.implicit=\
1226 Implicitly compiled files were not subject to annotation processing.\n\
1227 Use -proc:none to disable annotation processing or -implicit to specify a policy for implicit compilation.
1229 # Print a client-generated warning; assumed to be localized, no translation required
1230 # 0: string
1231 compiler.warn.proc.messager=\
1232 {0}
1234 # 0: set of name
1235 compiler.warn.proc.unclosed.type.files=\
1236 Unclosed files for the types ''{0}''; these types will not undergo annotation processing
1238 # 0: string
1239 compiler.warn.proc.unmatched.processor.options=\
1240 The following options were not recognized by any processor: ''{0}''
1242 compiler.warn.try.explicit.close.call=\
1243 explicit call to close() on an auto-closeable resource
1245 # 0: symbol
1246 compiler.warn.try.resource.not.referenced=\
1247 auto-closeable resource {0} is never referenced in body of corresponding try statement
1249 # 0: type
1250 compiler.warn.try.resource.throws.interrupted.exc=\
1251 auto-closeable resource {0} has a member method close() that could throw InterruptedException
1253 compiler.warn.unchecked.assign=\
1254 unchecked assignment: {0} to {1}
1256 # 0: symbol, 1: type
1257 compiler.warn.unchecked.assign.to.var=\
1258 unchecked assignment to variable {0} as member of raw type {1}
1260 # 0: symbol, 1: type
1261 compiler.warn.unchecked.call.mbr.of.raw.type=\
1262 unchecked call to {0} as a member of the raw type {1}
1264 compiler.warn.unchecked.cast.to.type=\
1265 unchecked cast to type {0}
1267 # 0: symbol kind, 1: name, 2: list of type, 3: list of type, 4: symbol kind, 5: symbol
1268 compiler.warn.unchecked.meth.invocation.applied=\
1269 unchecked method invocation: {0} {1} in {4} {5} is applied to given types\n\
1270 required: {2}\n\
1271 found: {3}
1273 # 0: type
1274 compiler.warn.unchecked.generic.array.creation=\
1275 unchecked generic array creation for varargs parameter of type {0}
1277 # 0: type
1278 compiler.warn.unchecked.varargs.non.reifiable.type=\
1279 Possible heap pollution from parameterized vararg type {0}
1281 # 0: symbol
1282 compiler.warn.varargs.unsafe.use.varargs.param=\
1283 Varargs method could cause heap pollution from non-reifiable varargs parameter {0}
1285 compiler.warn.missing.deprecated.annotation=\
1286 deprecated item is not annotated with @Deprecated
1288 compiler.warn.invalid.archive.file=\
1289 Unexpected file on path: {0}
1291 compiler.warn.unexpected.archive.file=\
1292 Unexpected extension for archive file: {0}
1294 compiler.warn.div.zero=\
1295 division by zero
1297 compiler.warn.empty.if=\
1298 empty statement after if
1300 compiler.warn.annotation.method.not.found=\
1301 Cannot find annotation method ''{1}()'' in type ''{0}''
1303 compiler.warn.annotation.method.not.found.reason=\
1304 Cannot find annotation method ''{1}()'' in type ''{0}'': {2}
1306 # 0: symbol, 1: name
1307 compiler.warn.unknown.enum.constant=\
1308 unknown enum constant {1}.{2}
1310 # 0: symbol, 1: name, 2: message segment
1311 compiler.warn.unknown.enum.constant.reason=\
1312 unknown enum constant {1}.{2}\n\
1313 reason: {3}
1315 # 0: type, 1: type
1316 compiler.warn.raw.class.use=\
1317 found raw type: {0}\n\
1318 missing type arguments for generic class {1}
1320 # 0: unused, 1: unused
1321 compiler.warn.diamond.redundant.args=\
1322 redundant type arguments in new expression (use diamond operator instead).
1324 # 0: type, 1: type
1325 compiler.warn.diamond.redundant.args.1=\
1326 redundant type arguments in new expression (use diamond operator instead).\n\
1327 explicit: {0}\n\
1328 inferred: {1}
1330 # 0: symbol, 1: message segment
1331 compiler.warn.varargs.redundant.trustme.anno=\
1332 Redundant {0} annotation. {1}
1334 #####
1336 ## The following are tokens which are non-terminals in the language. They should
1337 ## be named as JLS3 calls them when translated to the appropriate language.
1338 compiler.misc.token.identifier=\
1339 <identifier>
1341 compiler.misc.token.character=\
1342 <character>
1344 compiler.misc.token.string=\
1345 <string>
1347 compiler.misc.token.integer=\
1348 <integer>
1350 compiler.misc.token.long-integer=\
1351 <long integer>
1353 compiler.misc.token.float=\
1354 <float>
1356 compiler.misc.token.double=\
1357 <double>
1359 compiler.misc.token.bad-symbol=\
1360 <bad symbol>
1362 compiler.misc.token.end-of-input=\
1363 <end of input>
1365 ## The argument to the following string will always be one of the following:
1366 ## 1. one of the above non-terminals
1367 ## 2. a keyword (JLS1.8)
1368 ## 3. a boolean literal (JLS3.10.3)
1369 ## 4. the null literal (JLS3.10.7)
1370 ## 5. a Java separator (JLS3.11)
1371 ## 6. an operator (JLS3.12)
1372 ##
1373 ## This is the only place these tokens will be used.
1374 # 0: token
1375 compiler.err.expected=\
1376 {0} expected
1378 # 0: token, 1: token
1379 compiler.err.expected2=\
1380 {0} or {1} expected
1382 # 0: token, 1: token, 2: token
1383 compiler.err.expected3=\
1384 {0}, {1}, or {2} expected
1386 compiler.err.premature.eof=\
1387 reached end of file while parsing
1389 ## The following are related in form, but do not easily fit the above paradigm.
1390 compiler.err.dot.class.expected=\
1391 ''.class'' expected
1393 ## The argument to this string will always be either 'case' or 'default'.
1394 # 0: token
1395 compiler.err.orphaned=\
1396 orphaned {0}
1398 # 0: name
1399 compiler.misc.anonymous.class=\
1400 <anonymous {0}>
1402 # 0: name, 1: type
1403 compiler.misc.type.captureof=\
1404 capture#{0} of {1}
1406 compiler.misc.type.captureof.1=\
1407 capture#{0}
1409 compiler.misc.type.none=\
1410 <none>
1412 compiler.misc.unnamed.package=\
1413 unnamed package
1415 #####
1417 # 0: symbol, 1: message segment
1418 compiler.err.cant.access=\
1419 cannot access {0}\n\
1420 {1}
1422 compiler.misc.bad.class.file.header=\
1423 bad class file: {0}\n\
1424 {1}\n\
1425 Please remove or make sure it appears in the correct subdirectory of the classpath.
1427 # 0: file name, 1: message segment
1428 compiler.misc.bad.source.file.header=\
1429 bad source file: {0}\n\
1430 {1}\n\
1431 Please remove or make sure it appears in the correct subdirectory of the sourcepath.
1433 ## The following are all possible strings for the second argument ({1}) of the
1434 ## above strings.
1435 compiler.misc.bad.class.signature=\
1436 bad class signature: {0}
1438 #0: symbol, 1: symbol
1439 compiler.misc.bad.enclosing.class=\
1440 bad enclosing class for {0}: {1}
1442 # 0: symbol
1443 compiler.misc.bad.enclosing.method=\
1444 bad enclosing method attribute for class {0}
1446 compiler.misc.bad.runtime.invisible.param.annotations=\
1447 bad RuntimeInvisibleParameterAnnotations attribute: {0}
1449 compiler.misc.bad.const.pool.tag=\
1450 bad constant pool tag: {0}
1452 compiler.misc.bad.const.pool.tag.at=\
1453 bad constant pool tag: {0} at {1}
1455 compiler.misc.bad.signature=\
1456 bad signature: {0}
1458 compiler.misc.class.file.wrong.class=\
1459 class file contains wrong class: {0}
1461 compiler.misc.class.file.not.found=\
1462 class file for {0} not found
1464 # 0: name
1465 compiler.misc.file.doesnt.contain.class=\
1466 file does not contain class {0}
1468 compiler.misc.file.does.not.contain.package=\
1469 file does not contain package {0}
1471 compiler.misc.illegal.start.of.class.file=\
1472 illegal start of class file
1474 compiler.misc.unable.to.access.file=\
1475 unable to access file: {0}
1477 compiler.misc.unicode.str.not.supported=\
1478 unicode string in class file not supported
1480 compiler.misc.undecl.type.var=\
1481 undeclared type variable: {0}
1483 compiler.misc.wrong.version=\
1484 class file has wrong version {0}.{1}, should be {2}.{3}
1486 #####
1488 # 0: type, 1: type or symbol
1489 compiler.err.not.within.bounds=\
1490 type argument {0} is not within bounds of type-variable {1}
1492 ## The following are all possible strings for the second argument ({1}) of the
1493 ## above string.
1495 ## none yet...
1497 #####
1499 # 0: message segment, 1: type, 2: type
1500 compiler.err.prob.found.req=\
1501 {0}\n\
1502 required: {2}\n\
1503 found: {1}
1505 # 0: message segment, 1: type, 2: type
1506 compiler.warn.prob.found.req=\
1507 {0}\n\
1508 required: {2}\n\
1509 found: {1}
1511 compiler.err.prob.found.req.1=\
1512 {0} {3}\n\
1513 required: {2}\n\
1514 found: {1}
1516 ## The following are all possible strings for the first argument ({0}) of the
1517 ## above strings.
1518 compiler.misc.incompatible.types=\
1519 incompatible types
1521 # 0: message segment
1522 compiler.misc.incompatible.types.1=\
1523 incompatible types; {0}
1525 compiler.misc.inconvertible.types=\
1526 inconvertible types
1528 compiler.misc.possible.loss.of.precision=\
1529 possible loss of precision
1531 compiler.misc.unchecked.assign=\
1532 unchecked conversion
1534 # compiler.misc.storecheck=\
1535 # assignment might cause later store checks to fail
1536 # compiler.misc.unchecked=\
1537 # assigned array cannot dynamically check its stores
1538 compiler.misc.unchecked.cast.to.type=\
1539 unchecked cast
1541 compiler.misc.assignment.from.super-bound=\
1542 assignment from super-bound type {0}
1544 compiler.misc.assignment.to.extends-bound=\
1545 assignment to extends-bound type {0}
1547 # compiler.err.star.expected=\
1548 # ''*'' expected
1549 # compiler.err.no.elem.type=\
1550 # \[\*\] cannot have a type
1552 compiler.misc.try.not.applicable.to.type=\
1553 try-with-resources not applicable to variable type
1555 #####
1557 # 0: message segment or type, 1: message segment
1558 compiler.err.type.found.req=\
1559 unexpected type\n\
1560 required: {1}\n\
1561 found: {0}
1563 ## The following are all possible strings for the first argument ({0}) of the
1564 ## above string.
1565 compiler.misc.type.req.class=\
1566 class
1568 compiler.misc.type.req.class.array=\
1569 class or array
1571 compiler.misc.type.req.array.or.iterable=\
1572 array or java.lang.Iterable
1574 compiler.misc.type.req.ref=\
1575 reference
1577 compiler.misc.type.req.exact=\
1578 class or interface without bounds
1580 # 0: type
1581 compiler.misc.type.parameter=\
1582 type parameter {0}
1584 #####
1586 ## The following are all possible strings for the last argument of all those
1587 ## diagnostics whose key ends in ".1"
1588 compiler.misc.undetermined.type=\
1589 undetermined type
1591 compiler.misc.type.variable.has.undetermined.type=\
1592 type variable {0} has undetermined type
1594 # 0: type, 1: list of type
1595 compiler.misc.no.unique.maximal.instance.exists=\
1596 no unique maximal instance exists for type variable {0} with upper bounds {1}
1598 compiler.misc.no.unique.minimal.instance.exists=\
1599 no unique minimal instance exists for type variable {0} with lower bounds {1}
1601 # 0: list of type, 1: type, 2: type
1602 compiler.misc.infer.no.conforming.instance.exists=\
1603 no instance(s) of type variable(s) {0} exist so that {1} conforms to {2}
1605 # 0: list of type, 1: type, 2: type
1606 compiler.misc.infer.no.conforming.assignment.exists=\
1607 no instance(s) of type variable(s) {0} exist so that argument type {1} conforms to formal parameter type {2}
1609 compiler.misc.infer.arg.length.mismatch=\
1610 cannot instantiate from arguments because actual and formal argument lists differ in length
1612 # 0: type, 1: list of type
1613 compiler.misc.inferred.do.not.conform.to.bounds=\
1614 inferred type does not conform to declared bound(s)\n\
1615 inferred: {0}\n\
1616 bound(s): {1}
1618 # 0: symbol
1619 compiler.misc.diamond=\
1620 {0}<>
1622 # 0: type
1623 compiler.misc.diamond.non.generic=\
1624 cannot use ''<>'' with non-generic class {0}
1626 compiler.misc.diamond.and.explicit.params=\
1627 cannot use ''<>'' with explicit type parameters for constructor
1629 # 0: type, 1: list of type
1630 compiler.misc.explicit.param.do.not.conform.to.bounds=\
1631 explicit type argument {0} does not conform to declared bound(s) {1}
1633 compiler.misc.arg.length.mismatch=\
1634 actual and formal argument lists differ in length
1636 # 0: type, 1: type
1637 compiler.misc.no.conforming.assignment.exists=\
1638 actual argument {0} cannot be converted to {1} by method invocation conversion
1640 # 0: type, 1: type
1641 compiler.misc.varargs.argument.mismatch=\
1642 argument type {0} does not conform to vararg element type {1}
1644 #####
1646 ## The first argument ({0}) is a "kindname".
1647 # 0: symbol kind, 1: symbol, 2: symbol
1648 compiler.err.abstract.cant.be.accessed.directly=\
1649 abstract {0} {1} in {2} cannot be accessed directly
1651 ## The first argument ({0}) is a "kindname".
1652 # 0: symbol kind, 1: symbol
1653 compiler.err.non-static.cant.be.ref=\
1654 non-static {0} {1} cannot be referenced from a static context
1656 ## Both arguments ({0}, {1}) are "kindname"s. {0} is a comma-separated list
1657 ## of kindnames (the list should be identical to that provided in source.
1658 compiler.err.unexpected.type=\
1659 unexpected type\n\
1660 required: {0}\n\
1661 found: {1}
1663 ## The first argument {0} is a "kindname" (e.g. 'constructor', 'field', etc.)
1664 ## The second argument {1} is the non-resolved symbol
1665 ## The third argument {2} is a list of type parameters (non-empty if {1} is a method)
1666 ## The fourth argument {3} is a list of argument types (non-empty if {1} is a method)
1667 # 0: symbol kind, 1: name, 2: unused, 3: unused
1668 compiler.err.cant.resolve=\
1669 cannot find symbol\n\
1670 symbol: {0} {1}
1672 # 0: symbol kind, 1: name, 2: unused, 3: list of type
1673 compiler.err.cant.resolve.args=\
1674 cannot find symbol\n\
1675 symbol: {0} {1}({3})
1677 # 0: symbol kind, 1: name, 2: list of type, 3: list of type
1678 compiler.err.cant.resolve.args.params=\
1679 cannot find symbol\n\
1680 symbol: {0} <{2}>{1}({3})
1682 ## arguments from {0} to {3} have the same meaning as above
1683 ## The fifth argument {4} is a location subdiagnostic (see below)
1684 # 0: symbol kind, 1: name, 2: unused, 3: unused, 4: message segment
1685 compiler.err.cant.resolve.location=\
1686 cannot find symbol\n\
1687 symbol: {0} {1}\n\
1688 location: {4}
1690 # 0: symbol kind, 1: name, 2: unused, 3: list of type, 4: message segment
1691 compiler.err.cant.resolve.location.args=\
1692 cannot find symbol\n\
1693 symbol: {0} {1}({3})\n\
1694 location: {4}
1696 # 0: symbol kind, 1: name, 2: list of type, 3: list, 4: message segment
1697 compiler.err.cant.resolve.location.args.params=\
1698 cannot find symbol\n\
1699 symbol: {0} <{2}>{1}({3})\n\
1700 location: {4}
1702 ##a location subdiagnostic is composed as follows:
1703 ## The first argument {0} is the location "kindname" (e.g. 'constructor', 'field', etc.)
1704 ## The second argument {1} is the location name
1705 ## The third argument {2} is the location type (only when {1} is a variable name)
1707 # 0: symbol kind, 1: symbol, 2: unused
1708 compiler.misc.location=\
1709 {0} {1}
1711 # 0: symbol kind, 1: symbol, 2: type
1712 compiler.misc.location.1=\
1713 {0} {1} of type {2}
1715 ## The following are all possible string for "kindname".
1716 ## They should be called whatever the JLS calls them after it been translated
1717 ## to the appropriate language.
1718 # compiler.misc.kindname.constructor=\
1719 # static member
1720 compiler.misc.kindname.annotation=\
1721 @interface
1723 compiler.misc.kindname.constructor=\
1724 constructor
1726 compiler.misc.kindname.enum=\
1727 enum
1729 compiler.misc.kindname.interface=\
1730 interface
1732 compiler.misc.kindname.static=\
1733 static
1735 compiler.misc.kindname.type.variable=\
1736 type variable
1738 compiler.misc.kindname.type.variable.bound=\
1739 bound of type variable
1741 compiler.misc.kindname.variable=\
1742 variable
1744 compiler.misc.kindname.value=\
1745 value
1747 compiler.misc.kindname.method=\
1748 method
1750 compiler.misc.kindname.class=\
1751 class
1753 compiler.misc.kindname.package=\
1754 package
1756 #####
1758 compiler.misc.no.args=\
1759 no arguments
1761 # 0: message segment
1762 compiler.err.override.static=\
1763 {0}\n\
1764 overriding method is static
1766 # 0: message segment, 1: set of modifier
1767 compiler.err.override.meth=\
1768 {0}\n\
1769 overridden method is {1}
1771 # 0: message segment, 1: type
1772 compiler.err.override.meth.doesnt.throw=\
1773 {0}\n\
1774 overridden method does not throw {1}
1776 # In the following string {1} is a space separated list of Java Keywords, as
1777 # they would have been declared in the source code
1778 # 0: message segment, 1: set of modifier
1779 compiler.err.override.weaker.access=\
1780 {0}\n\
1781 attempting to assign weaker access privileges; was {1}
1783 # 0: message segment, 1: type, 2: type
1784 compiler.err.override.incompatible.ret=\
1785 {0}\n\
1786 return type {1} is not compatible with {2}
1788 # 0: message segment, 1: type, 2: type
1789 compiler.warn.override.unchecked.ret=\
1790 {0}\n\
1791 return type requires unchecked conversion from {1} to {2}
1793 # 0: message segment, 1: type
1794 compiler.warn.override.unchecked.thrown=\
1795 {0}\n\
1796 overridden method does not throw {1}
1798 ## The following are all possible strings for the first argument ({0}) of the
1799 ## above strings.
1800 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1801 compiler.misc.cant.override=\
1802 {0} in {1} cannot override {2} in {3}
1804 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1805 compiler.misc.cant.implement=\
1806 {0} in {1} cannot implement {2} in {3}
1808 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1809 compiler.misc.clashes.with=\
1810 {0} in {1} clashes with {2} in {3}
1812 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1813 compiler.misc.unchecked.override=\
1814 {0} in {1} overrides {2} in {3}
1816 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1817 compiler.misc.unchecked.implement=\
1818 {0} in {1} implements {2} in {3}
1820 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1821 compiler.misc.unchecked.clash.with=\
1822 {0} in {1} overrides {2} in {3}
1824 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1825 compiler.misc.varargs.override=\
1826 {0} in {1} overrides {2} in {3}
1828 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1829 compiler.misc.varargs.implement=\
1830 {0} in {1} implements {2} in {3}
1832 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1833 compiler.misc.varargs.clash.with=\
1834 {0} in {1} overrides {2} in {3}
1836 compiler.misc.diamond.and.anon.class=\
1837 cannot use ''<>'' with anonymous inner classes
1839 # 0: symbol kind, 1: symbol, 2: symbol, 3: message segment
1840 compiler.misc.inapplicable.method=\
1841 {0} {1}.{2} is not applicable\n\
1842 ({3})
1844 ########################################
1845 # Diagnostics for language feature changes
1846 ########################################
1847 # 0: string
1848 compiler.err.unsupported.fp.lit=\
1849 hexadecimal floating point literals are not supported in -source {0}\n\
1850 (use -source 5 or higher to enable hexadecimal floating point literals)
1852 # 0: string
1853 compiler.err.unsupported.binary.lit=\
1854 binary literals are not supported in -source {0}\n\
1855 (use -source 7 or higher to enable binary literals)
1857 # 0: string
1858 compiler.err.unsupported.underscore.lit=\
1859 underscores in literals are not supported in -source {0}\n\
1860 (use -source 7 or higher to enable underscores in literals)
1862 # 0: string
1863 compiler.err.try.with.resources.not.supported.in.source=\
1864 try-with-resources is not supported in -source {0}\n\
1865 (use -source 7 or higher to enable try-with-resources)
1867 compiler.warn.enum.as.identifier=\
1868 as of release 5, ''enum'' is a keyword, and may not be used as an identifier\n\
1869 (use -source 5 or higher to use ''enum'' as a keyword)
1871 compiler.warn.assert.as.identifier=\
1872 as of release 1.4, ''assert'' is a keyword, and may not be used as an identifier\n\
1873 (use -source 1.4 or higher to use ''assert'' as a keyword)
1875 compiler.err.enum.as.identifier=\
1876 as of release 5, ''enum'' is a keyword, and may not be used as an identifier\n\
1877 (use -source 1.4 or lower to use ''enum'' as an identifier)
1879 compiler.err.assert.as.identifier=\
1880 as of release 1.4, ''assert'' is a keyword, and may not be used as an identifier\n\
1881 (use -source 1.3 or lower to use ''assert'' as an identifier)
1883 # 0: string
1884 compiler.err.generics.not.supported.in.source=\
1885 generics are not supported in -source {0}\n\
1886 (use -source 5 or higher to enable generics)
1888 # 0: string
1889 compiler.err.varargs.not.supported.in.source=\
1890 variable-arity methods are not supported in -source {0}\n\
1891 (use -source 5 or higher to enable variable-arity methods)
1893 # 0: string
1894 compiler.err.annotations.not.supported.in.source=\
1895 annotations are not supported in -source {0}\n\
1896 (use -source 5 or higher to enable annotations)
1898 #308 compiler.err.type.annotations.not.supported.in.source=\
1899 #308 type annotations are not supported in -source {0}\n\
1900 #308 (use -source 7 or higher to enable type annotations)
1902 # 0: string
1903 compiler.err.foreach.not.supported.in.source=\
1904 for-each loops are not supported in -source {0}\n\
1905 (use -source 5 or higher to enable for-each loops)
1907 # 0: string
1908 compiler.err.static.import.not.supported.in.source=\
1909 static import declarations are not supported in -source {0}\n\
1910 (use -source 5 or higher to enable static import declarations)
1912 # 0: string
1913 compiler.err.enums.not.supported.in.source=\
1914 enums are not supported in -source {0}\n\
1915 (use -source 5 or higher to enable enums)
1917 # 0: string
1918 compiler.err.diamond.not.supported.in.source=\
1919 diamond operator is not supported in -source {0}\n\
1920 (use -source 7 or higher to enable diamond operator)
1922 # 0: string
1923 compiler.err.multicatch.not.supported.in.source=\
1924 multi-catch statement is not supported in -source {0}\n\
1925 (use -source 7 or higher to enable multi-catch statement)
1927 # 0: string
1928 compiler.err.string.switch.not.supported.in.source=\
1929 strings in switch are not supported in -source {0}\n\
1930 (use -source 7 or higher to enable strings in switch)
1932 ########################################
1933 # Diagnostics for where clause implementation
1934 # used by the RichDiagnosticFormatter.
1935 ########################################
1937 compiler.misc.type.null=\
1938 <null>
1940 # X#n (where n is an int id) is disambiguated tvar name
1941 # 0: name, 1: number
1942 compiler.misc.type.var=\
1943 {0}#{1}
1945 # CAP#n (where n is an int id) is an abbreviation for 'captured type'
1946 # 0: number
1947 compiler.misc.captured.type=\
1948 CAP#{0}
1950 # <INT#n> (where n is an int id) is an abbreviation for 'intersection type'
1951 # 0: number
1952 compiler.misc.intersection.type=\
1953 INT#{0}
1955 # where clause for captured type: contains upper ('extends {1}') and lower
1956 # ('super {2}') bound along with the wildcard that generated this captured type ({3})
1957 # 0: type, 1: type, 2: type, 3: type
1958 compiler.misc.where.captured=\
1959 {0} extends {1} super: {2} from capture of {3}
1961 # compact where clause for captured type: contains upper ('extends {1}') along
1962 # with the wildcard that generated this captured type ({3})
1963 # 0: type, 1: type, 2: unused, 3: type
1964 compiler.misc.where.captured.1=\
1965 {0} extends {1} from capture of {3}
1967 # where clause for type variable: contains upper bound(s) ('extends {1}') along with
1968 # the kindname ({2}) and location ({3}) in which the typevar has been declared
1969 # 0: type, 1: list of type, 2: symbol kind, 3: symbol
1970 compiler.misc.where.typevar=\
1971 {0} extends {1} declared in {2} {3}
1973 # compact where clause for type variable: contains the kindname ({2}) and location ({3})
1974 # in which the typevar has been declared
1975 compiler.misc.where.typevar.1=\
1976 {0} declared in {2} {3}
1978 # where clause for type variable: contains all the upper bound(s) ('extends {1}')
1979 # of this intersection type
1980 # 0: type, 1: list of type
1981 compiler.misc.where.intersection=\
1982 {0} extends {1}
1984 ### Where clause headers ###
1985 compiler.misc.where.description.captured=\
1986 where {0} is a fresh type-variable:
1988 # 0: set of type
1989 compiler.misc.where.description.typevar=\
1990 where {0} is a type-variable:
1992 # 0: set of type
1993 compiler.misc.where.description.intersection=\
1994 where {0} is an intersection type:
1996 # 0: set of type
1997 compiler.misc.where.description.captured.1=\
1998 where {0} are fresh type-variables:
2000 # 0: set of type
2001 compiler.misc.where.description.typevar.1=\
2002 where {0} are type-variables:
2004 compiler.misc.where.description.intersection.1=\
2005 where {0} are intersection types: