Tue, 15 Feb 2011 11:51:04 +0000
7017104: improve error reporting for uncaught/undeclared exceptions from try-with-resources
Summary: twr should generate better error message when uncaught exceptions are thrown by implicit call of close() method
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 compiler.err.finally.without.try=\
306 ''finally'' without ''try''
308 # 0: type, 1: message segment
309 compiler.err.foreach.not.applicable.to.type=\
310 for-each not applicable to expression type\n\
311 required: {1}\n\
312 found: {0}
314 compiler.err.fp.number.too.large=\
315 floating point number too large
317 compiler.err.fp.number.too.small=\
318 floating point number too small
320 compiler.err.generic.array.creation=\
321 generic array creation
323 compiler.err.generic.throwable=\
324 a generic class may not extend java.lang.Throwable
326 # 0: symbol
327 compiler.err.icls.cant.have.static.decl=\
328 Illegal static declaration in inner class {0}\n\
329 modifier \''static\'' is only allowed in constant variable declarations
331 # 0: string
332 compiler.err.illegal.char=\
333 illegal character: \\{0}
335 compiler.err.illegal.char.for.encoding=\
336 unmappable character for encoding {0}
338 # 0: set of modifier, 1: set of modifier
339 compiler.err.illegal.combination.of.modifiers=\
340 illegal combination of modifiers: {0} and {1}
342 compiler.err.illegal.enum.static.ref=\
343 illegal reference to static field from initializer
345 compiler.err.illegal.esc.char=\
346 illegal escape character
348 compiler.err.illegal.forward.ref=\
349 illegal forward reference
351 # 0: symbol
352 compiler.warn.forward.ref=\
353 reference to variable ''{0}'' before it has been initialized
355 compiler.err.illegal.self.ref=\
356 self-reference in initializer
358 # 0: symbol
359 compiler.warn.self.ref=\
360 self-reference in initializer of variable ''{0}''
362 compiler.err.illegal.generic.type.for.instof=\
363 illegal generic type for instanceof
365 # 0: type
366 compiler.err.illegal.initializer.for.type=\
367 illegal initializer for {0}
369 compiler.err.illegal.line.end.in.char.lit=\
370 illegal line end in character literal
372 compiler.err.illegal.nonascii.digit=\
373 illegal non-ASCII digit
375 compiler.err.illegal.underscore=\
376 illegal underscore
378 # 0: symbol
379 compiler.err.illegal.qual.not.icls=\
380 illegal qualifier; {0} is not an inner class
382 compiler.err.illegal.start.of.expr=\
383 illegal start of expression
385 compiler.err.illegal.start.of.type=\
386 illegal start of type
388 compiler.err.illegal.unicode.esc=\
389 illegal unicode escape
391 # 0: symbol
392 compiler.err.import.requires.canonical=\
393 import requires canonical name for {0}
395 compiler.err.improperly.formed.type.param.missing=\
396 improperly formed type, some parameters are missing
398 compiler.err.improperly.formed.type.inner.raw.param=\
399 improperly formed type, type arguments given on a raw type
401 # 0: type, 1: type
402 compiler.err.incomparable.types=\
403 incomparable types: {0} and {1}
405 # 0: number
406 compiler.err.int.number.too.large=\
407 integer number too large: {0}
409 compiler.err.internal.error.cant.instantiate=\
410 internal error; cannot instantiate {0} at {1} to ({2})
412 compiler.err.intf.annotation.members.cant.have.params=\
413 @interface members may not have parameters
415 compiler.err.intf.annotation.cant.have.type.params=\
416 @interface may not have type parameters
418 compiler.err.intf.annotation.members.cant.have.type.params=\
419 @interface members may not have type parameters
421 # 0: symbol, 1: type
422 compiler.err.intf.annotation.member.clash=\
423 @interface member clashes with method ''{0}'' in {1}
425 compiler.err.intf.expected.here=\
426 interface expected here
428 compiler.err.intf.meth.cant.have.body=\
429 interface methods cannot have body
431 compiler.err.invalid.annotation.member.type=\
432 invalid type for annotation member
434 compiler.err.invalid.binary.number=\
435 binary numbers must contain at least one binary digit
437 compiler.err.invalid.hex.number=\
438 hexadecimal numbers must contain at least one hexadecimal digit
440 compiler.err.invalid.meth.decl.ret.type.req=\
441 invalid method declaration; return type required
443 compiler.err.varargs.and.old.array.syntax=\
444 legacy array notation not allowed on variable-arity parameter
446 # 0: name
447 compiler.err.label.already.in.use=\
448 label {0} already in use
450 # 0: symbol
451 compiler.err.local.var.accessed.from.icls.needs.final=\
452 local variable {0} is accessed from within inner class; needs to be declared final
454 compiler.err.local.enum=\
455 enum types must not be local
457 compiler.err.cannot.create.array.with.type.arguments=\
458 cannot create array with type arguments
460 #
461 # limits. We don't give the limits in the diagnostic because we expect
462 # them to change, yet we want to use the same diagnostic. These are all
463 # detected during code generation.
464 #
465 compiler.err.limit.code=\
466 code too large
468 compiler.err.limit.code.too.large.for.try.stmt=\
469 code too large for try statement
471 compiler.err.limit.dimensions=\
472 array type has too many dimensions
474 compiler.err.limit.locals=\
475 too many local variables
477 compiler.err.limit.parameters=\
478 too many parameters
480 compiler.err.limit.pool=\
481 too many constants
483 compiler.err.limit.pool.in.class=\
484 too many constants in class {0}
486 compiler.err.limit.stack=\
487 code requires too much stack
489 compiler.err.limit.string=\
490 constant string too long
492 compiler.err.limit.string.overflow=\
493 UTF8 representation for string \"{0}...\" is too long for the constant pool
495 compiler.err.malformed.fp.lit=\
496 malformed floating point literal
498 compiler.err.method.does.not.override.superclass=\
499 method does not override or implement a method from a supertype
501 compiler.err.missing.meth.body.or.decl.abstract=\
502 missing method body, or declare abstract
504 compiler.err.missing.ret.stmt=\
505 missing return statement
507 compiler.err.missing.ret.val=\
508 missing return value
510 # 0: set of modifier
511 compiler.err.mod.not.allowed.here=\
512 modifier {0} not allowed here
514 compiler.err.intf.not.allowed.here=\
515 interface not allowed here
517 compiler.err.enums.must.be.static=\
518 enum declarations allowed only in static contexts
520 # 0: symbol, 1: symbol
521 compiler.err.name.clash.same.erasure=\
522 name clash: {0} and {1} have the same erasure
524 # 0: symbol, 1: symbol, 2: symbol, 3: symbol, 4: unused, 5: unused
525 compiler.err.name.clash.same.erasure.no.override=\
526 name clash: {0} in {1} and {2} in {3} have the same erasure, yet neither overrides the other
528 # 0: symbol, 1: symbol, 2: symbol, 3: symbol, 4: symbol, 5: symbol
529 compiler.err.name.clash.same.erasure.no.override.1=\
530 name clash: {0} in {1} overrides a method whose erasure is the same as another method, yet neither overrides the other\n\
531 first method: {2} in {3}\n\
532 second method: {4} in {5}
534 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
535 compiler.err.name.clash.same.erasure.no.hide=\
536 name clash: {0} in {1} and {2} in {3} have the same erasure, yet neither hides the other
538 compiler.err.name.reserved.for.internal.use=\
539 {0} is reserved for internal use
541 compiler.err.native.meth.cant.have.body=\
542 native methods cannot have a body
544 # 0: type, 1: type
545 compiler.err.neither.conditional.subtype=\
546 incompatible types for ?: neither is a subtype of the other\n\
547 second operand: {0}\n\
548 third operand : {1}
550 compiler.err.new.not.allowed.in.annotation=\
551 ''new'' not allowed in an annotation
553 compiler.err.no.annotation.member=\
554 no annotation member {0} in {1}
556 compiler.err.no.encl.instance.of.type.in.scope=\
557 no enclosing instance of type {0} is in scope
559 compiler.err.no.intf.expected.here=\
560 no interface expected here
562 compiler.err.no.match.entry=\
563 {0} has no match in entry in {1}; required {2}
565 compiler.err.not.annotation.type=\
566 {0} is not an annotation type
568 # 0: symbol, 1: symbol
569 compiler.err.not.def.access.class.intf.cant.access=\
570 {0} in {1} is defined in an inaccessible class or interface
572 # 0: symbol, 1: symbol
573 compiler.err.not.def.public.cant.access=\
574 {0} is not public in {1}; cannot be accessed from outside package
576 # 0: name
577 compiler.err.not.loop.label=\
578 not a loop label: {0}
580 compiler.err.not.stmt=\
581 not a statement
583 # 0: symbol
584 compiler.err.not.encl.class=\
585 not an enclosing class: {0}
587 # 0: name, 1: type, 2: unused
588 compiler.err.operator.cant.be.applied=\
589 bad operand type {1} for unary operator ''{0}''
591 # 0: name, 1: type, 2: type
592 compiler.err.operator.cant.be.applied.1=\
593 bad operand types for binary operator ''{0}''\n\
594 first type: {1}\n\
595 second type: {2}
597 compiler.err.pkg.annotations.sb.in.package-info.java=\
598 package annotations should be in file package-info.java
600 # 0: symbol
601 compiler.err.pkg.clashes.with.class.of.same.name=\
602 package {0} clashes with class of same name
604 compiler.err.warnings.and.werror=\
605 warnings found and -Werror specified
607 # Errors related to annotation processing
609 compiler.err.proc.cant.access=\
610 cannot access {0}\n\
611 {1}\n\
612 Consult the following stack trace for details.\n\
613 {2}
615 # 0: string
616 compiler.err.proc.cant.find.class=\
617 Could not find class file for ''{0}''.
619 # Print a client-generated error message; assumed to be localized, no translation required
620 # 0: string
621 compiler.err.proc.messager=\
622 {0}
624 # 0: list of string
625 compiler.err.proc.no.explicit.annotation.processing.requested=\
626 Class names, ''{0}'', are only accepted if annotation processing is explicitly requested
628 compiler.err.proc.no.service=\
629 A service loader class could not be found.\n\
630 Either java.util.ServiceLoader or sun.misc.Service must be available.
632 compiler.err.proc.processor.bad.option.name=\
633 Bad option name ''{0}'' provided by processor ''{1}''
635 # 0: string
636 compiler.err.proc.processor.cant.instantiate=\
637 Could not instantiate an instance of processor ''{0}''
639 compiler.err.proc.processor.constructor.error=\
640 Exception thrown while constructing Processor object: {0}
642 # 0: string
643 compiler.err.proc.processor.not.found=\
644 Annotation processor ''{0}'' not found
646 # 0: string
647 compiler.err.proc.processor.wrong.type=\
648 Annotation processor ''{0}'' does not implement javax.annotation.processing.Processor
650 compiler.err.proc.service.problem=\
651 Error creating a service loader to load Processors.
653 compiler.err.proc.bad.config.file=\
654 Bad service configuration file, or exception thrown while constructing Processor object: {0}
656 compiler.err.proc.cant.create.loader=\
657 Could not create class loader for annotation processors: {0}
659 # 0: unused
660 compiler.err.qualified.new.of.static.class=\
661 qualified new of static class
663 compiler.err.recursive.ctor.invocation=\
664 recursive constructor invocation
666 # 0: name, 1: symbol kind, 2: symbol, 3: symbol, 4: symbol kind, 5: symbol, 6: symbol
667 compiler.err.ref.ambiguous=\
668 reference to {0} is ambiguous, both {1} {2} in {3} and {4} {5} in {6} match
670 compiler.err.repeated.annotation.target=\
671 repeated annotation target
673 compiler.err.repeated.interface=\
674 repeated interface
676 compiler.err.repeated.modifier=\
677 repeated modifier
679 # 0: symbol, 1: set of modifier, 2: symbol
680 compiler.err.report.access=\
681 {0} has {1} access in {2}
683 compiler.err.ret.outside.meth=\
684 return outside method
686 compiler.err.signature.doesnt.match.supertype=\
687 signature does not match {0}; incompatible supertype
689 compiler.err.signature.doesnt.match.intf=\
690 signature does not match {0}; incompatible interfaces
692 # 0: symbol, 1: symbol, 2: symbol
693 compiler.err.does.not.override.abstract=\
694 {0} is not abstract and does not override abstract method {1} in {2}
696 compiler.err.source.cant.overwrite.input.file=\
697 error writing source; cannot overwrite input file {0}
699 compiler.err.stack.sim.error=\
700 Internal error: stack sim error on {0}
702 compiler.err.static.imp.only.classes.and.interfaces=\
703 static import only from classes and interfaces
705 compiler.err.string.const.req=\
706 constant string expression required
708 # 0: symbol, 1: symbol
709 compiler.err.synthetic.name.conflict=\
710 the symbol {0} conflicts with a compiler-synthesized symbol in {1}
712 # 0: symbol, 1: symbol
713 compiler.warn.synthetic.name.conflict=\
714 the symbol {0} conflicts with a compiler-synthesized symbol in {1}
716 compiler.err.throws.not.allowed.in.intf.annotation=\
717 throws clause not allowed in @interface members
719 compiler.err.try.without.catch.or.finally=\
720 ''try'' without ''catch'' or ''finally''
722 compiler.err.try.without.catch.finally.or.resource.decls=\
723 ''try'' without ''catch'', ''finally'' or resource declarations
725 # 0: symbol
726 compiler.err.type.doesnt.take.params=\
727 type {0} does not take parameters
729 compiler.err.type.var.cant.be.deref=\
730 cannot select from a type variable
732 compiler.err.type.var.may.not.be.followed.by.other.bounds=\
733 a type variable may not be followed by other bounds
735 compiler.err.type.var.more.than.once=\
736 type variable {0} occurs more than once in result type of {1}; cannot be left uninstantiated
738 compiler.err.type.var.more.than.once.in.result=\
739 type variable {0} occurs more than once in type of {1}; cannot be left uninstantiated
741 # 0: type, 1: type, 2: string
742 compiler.err.types.incompatible.diff.ret=\
743 types {0} and {1} are incompatible; both define {2}, but with unrelated return types
745 compiler.err.unclosed.char.lit=\
746 unclosed character literal
748 compiler.err.unclosed.comment=\
749 unclosed comment
751 compiler.err.unclosed.str.lit=\
752 unclosed string literal
754 compiler.err.unknown.enum.constant=\
755 in class file {0}: unknown enum constant {1}.{2}
757 # 0: name
758 compiler.err.unsupported.encoding=\
759 unsupported encoding: {0}
761 compiler.err.io.exception=\
762 error reading source file: {0}
764 # 0: name
765 compiler.err.undef.label=\
766 undefined label: {0}
768 compiler.err.undetermined.type=\
769 cannot infer type arguments for {0}
771 # 0: type, 1: message segment
772 compiler.err.undetermined.type.1=\
773 cannot infer type arguments for {0};\n\
774 reason: {1}
776 # 0: list of type, 1: message segment
777 compiler.err.invalid.inferred.types=\
778 invalid inferred types for {0}; {1}
780 # 0: message segment, 1: unused
781 compiler.err.cant.apply.diamond=\
782 cannot infer type arguments for {0}
784 # 0: message segment, 1: message segment
785 compiler.err.cant.apply.diamond.1=\
786 cannot infer type arguments for {0};\n\
787 reason: {1}
789 compiler.err.unreachable.stmt=\
790 unreachable statement
792 compiler.err.initializer.must.be.able.to.complete.normally=\
793 initializer must be able to complete normally
795 # 0: type
796 compiler.err.unreported.exception.need.to.catch.or.throw=\
797 unreported exception {0}; must be caught or declared to be thrown
799 # 0: type
800 compiler.err.unreported.exception.default.constructor=\
801 unreported exception {0} in default constructor
803 # 0: type, 1: name
804 compiler.err.unreported.exception.implicit.close=\
805 unreported exception {0}; must be caught or declared to be thrown\n\
806 exception thrown from implicit call to close() on resource variable ''{1}''
808 compiler.err.unsupported.cross.fp.lit=\
809 hexadecimal floating-point literals are not supported on this VM
811 compiler.err.void.not.allowed.here=\
812 ''void'' type not allowed here
814 # 0: string
815 compiler.err.wrong.number.type.args=\
816 wrong number of type arguments; required {0}
818 # 0: symbol
819 compiler.err.var.might.already.be.assigned=\
820 variable {0} might already have been assigned
822 # 0: symbol
823 compiler.err.var.might.not.have.been.initialized=\
824 variable {0} might not have been initialized
826 # 0: symbol
827 compiler.err.var.might.be.assigned.in.loop=\
828 variable {0} might be assigned in loop
830 # 0: symbol, 1: message segment
831 compiler.err.varargs.invalid.trustme.anno=\
832 Invalid {0} annotation. {1}
834 # 0: type
835 compiler.misc.varargs.trustme.on.reifiable.varargs=\
836 Varargs element type {0} is reifiable.
838 # 0: symbol
839 compiler.misc.varargs.trustme.on.non.varargs.meth=\
840 Method {0} is not a varargs method.
842 # 0: symbol
843 compiler.misc.varargs.trustme.on.virtual.varargs=\
844 Instance method {0} is not final.
846 # 0: type, 1: kind, 2: symbol
847 compiler.misc.inaccessible.varargs.type=\
848 formal varargs element type {0} is not accessible from {1} {2}
850 # In the following string, {1} will always be the detail message from
851 # java.io.IOException.
852 # 0: symbol, 1: string
853 compiler.err.class.cant.write=\
854 error while writing {0}: {1}
856 # In the following string, {0} is the name of the class in the Java source.
857 # It really should be used two times..
858 # 0: name
859 compiler.err.class.public.should.be.in.file=\
860 class {0} is public, should be declared in a file named {0}.java
862 ## All errors which do not refer to a particular line in the source code are
863 ## preceded by this string.
864 compiler.err.error=\
865 error:\u0020
867 # The following error messages do not refer to a line in the source code.
868 compiler.err.cant.read.file=\
869 cannot read: {0}
871 #####
873 # Fatal Errors
875 compiler.misc.fatal.err.no.java.lang=\
876 Fatal Error: Unable to find package java.lang in classpath or bootclasspath
878 compiler.misc.fatal.err.cant.locate.meth=\
879 Fatal Error: Unable to find method {0}
881 compiler.misc.fatal.err.cant.locate.field=\
882 Fatal Error: Unable to find field {0}
884 compiler.misc.fatal.err.cant.locate.ctor=\
885 Fatal Error: Unable to find constructor for {0}
887 compiler.misc.fatal.err.cant.close.loader=\
888 Fatal Error: Cannot close class loader for annotation processors
890 #####
892 ##
893 ## miscellaneous strings
894 ##
896 compiler.misc.source.unavailable=\
897 (source unavailable)
899 compiler.misc.base.membership=\
900 all your base class are belong to us
902 # 0: string, 1: string, 2: boolean
903 compiler.misc.x.print.processor.info=\
904 Processor {0} matches {1} and returns {2}.
906 # 0: number, 1: string, 2: set of symbol, 3: boolean
907 compiler.misc.x.print.rounds=\
908 Round {0}:\n\tinput files: {1}\n\tannotations: {2}\n\tlast round: {3}
910 #####
912 ## The following string will appear before all messages keyed as:
913 ## "compiler.note".
914 compiler.note.note=\
915 Note:\u0020
917 # 0: file name
918 compiler.note.deprecated.filename=\
919 {0} uses or overrides a deprecated API.
921 compiler.note.deprecated.plural=\
922 Some input files use or override a deprecated API.
924 # The following string may appear after one of the above deprecation
925 # messages.
926 compiler.note.deprecated.recompile=\
927 Recompile with -Xlint:deprecation for details.
929 # 0: file name
930 compiler.note.deprecated.filename.additional=\
931 {0} has additional uses or overrides of a deprecated API.
933 compiler.note.deprecated.plural.additional=\
934 Some input files additionally use or override a deprecated API.
936 # 0: file name
937 compiler.note.unchecked.filename=\
938 {0} uses unchecked or unsafe operations.
940 compiler.note.unchecked.plural=\
941 Some input files use unchecked or unsafe operations.
943 # The following string may appear after one of the above deprecation
944 # messages.
945 compiler.note.unchecked.recompile=\
946 Recompile with -Xlint:unchecked for details.
948 # 0: file name
949 compiler.note.unchecked.filename.additional=\
950 {0} has additional unchecked or unsafe operations.
952 compiler.note.unchecked.plural.additional=\
953 Some input files additionally use unchecked or unsafe operations.
955 # 0: file name
956 compiler.note.sunapi.filename=\
957 {0} uses internal proprietary API that may be removed in a future release.
959 compiler.note.sunapi.plural=\
960 Some input files use internal proprietary API that may be removed in a future release.
962 # The following string may appear after one of the above sunapi messages.
963 compiler.note.sunapi.recompile=\
964 Recompile with -Xlint:sunapi for details.
966 # 0: file name
967 compiler.note.sunapi.filename.additional=\
968 {0} uses additional internal proprietary API that may be removed in a future release.
970 compiler.note.sunapi.plural.additional=\
971 Some input files additionally use internal proprietary API that may be removed in a future release.
973 # Notes related to annotation processing
975 # Print a client-generated note; assumed to be localized, no translation required
976 # 0: string
977 compiler.note.proc.messager=\
978 {0}
980 #####
982 # 0: number
983 compiler.misc.count.error=\
984 {0} error
986 # 0: number
987 compiler.misc.count.error.plural=\
988 {0} errors
990 # 0: number
991 compiler.misc.count.warn=\
992 {0} warning
994 # 0: number
995 compiler.misc.count.warn.plural=\
996 {0} warnings
998 compiler.misc.version.not.available=\
999 (version info not available)
1001 ## extra output when using -verbose (JavaCompiler)
1003 # 0: symbol
1004 compiler.misc.verbose.checking.attribution=\
1005 [checking {0}]
1007 # 0: string
1008 compiler.misc.verbose.parsing.done=\
1009 [parsing completed {0}ms]
1011 # 0: file name
1012 compiler.misc.verbose.parsing.started=\
1013 [parsing started {0}]
1015 # 0: string
1016 compiler.misc.verbose.total=\
1017 [total {0}ms]
1019 # 0: file name
1020 compiler.misc.verbose.wrote.file=\
1021 [wrote {0}]
1023 ## extra output when using -verbose (Retro)
1024 compiler.misc.verbose.retro=\
1025 [retrofitting {0}]
1027 compiler.misc.verbose.retro.with=\
1028 \tretrofitting {0} with {1}
1030 compiler.misc.verbose.retro.with.list=\
1031 \tretrofitting {0} with type parameters {1}, supertype {2}, interfaces {3}
1033 ## extra output when using -verbose (code/ClassReader)
1034 # 0: string
1035 compiler.misc.verbose.loading=\
1036 [loading {0}]
1038 # 0: string
1039 compiler.misc.verbose.sourcepath=\
1040 [search path for source files: {0}]
1042 # 0: string
1043 compiler.misc.verbose.classpath=\
1044 [search path for class files: {0}]
1046 ## extra output when using -checkclassfile (code/ClassReader)
1047 compiler.misc.ccf.found.later.version=\
1048 class file has later version than expected: {0}
1050 compiler.misc.ccf.unrecognized.attribute=\
1051 unrecognized attribute: {0}
1053 ## extra output when using -prompt (util/Log)
1054 compiler.misc.resume.abort=\
1055 R)esume, A)bort>
1057 #####
1059 ##
1060 ## warnings
1061 ##
1063 ## All warning messages are preceded by the following string.
1064 compiler.warn.warning=\
1065 warning:\u0020
1067 ## Warning messages may also include the following prefix to identify a
1068 ## lint option
1069 # 0: option name
1070 compiler.warn.lintOption=\
1071 [{0}]\u0020
1073 # 0: symbol
1074 compiler.warn.constant.SVUID=\
1075 serialVersionUID must be constant in class {0}
1077 # 0: file name
1078 compiler.warn.dir.path.element.not.found=\
1079 bad path element "{0}": no such directory
1081 compiler.warn.finally.cannot.complete=\
1082 finally clause cannot complete normally
1084 # 0: symbol, 1: symbol
1085 compiler.warn.has.been.deprecated=\
1086 {0} in {1} has been deprecated
1088 # 0: symbol
1089 compiler.warn.sun.proprietary=\
1090 {0} is internal proprietary API and may be removed in a future release
1092 compiler.warn.illegal.char.for.encoding=\
1093 unmappable character for encoding {0}
1095 # 0: symbol
1096 compiler.warn.improper.SVUID=\
1097 serialVersionUID must be declared static final in class {0}
1099 # 0: type, 1: type
1100 compiler.warn.inexact.non-varargs.call=\
1101 non-varargs call of varargs method with inexact argument type for last parameter;\n\
1102 cast to {0} for a varargs call\n\
1103 cast to {1} for a non-varargs call and to suppress this warning
1105 # 0: symbol
1106 compiler.warn.long.SVUID=\
1107 serialVersionUID must be of type long in class {0}
1109 # 0: symbol
1110 compiler.warn.missing.SVUID=\
1111 serializable class {0} has no definition of serialVersionUID
1113 # 0: message segment
1114 compiler.warn.override.varargs.missing=\
1115 {0}; overridden method has no ''...''
1117 # 0: message segment
1118 compiler.warn.override.varargs.extra=\
1119 {0}; overriding method is missing ''...''
1121 compiler.warn.override.bridge=\
1122 {0}; overridden method is a bridge method
1124 # 0: symbol
1125 compiler.warn.pkg-info.already.seen=\
1126 a package-info.java file has already been seen for package {0}
1128 # 0: file name
1129 compiler.warn.path.element.not.found=\
1130 bad path element "{0}": no such file or directory
1132 compiler.warn.possible.fall-through.into.case=\
1133 possible fall-through into case
1135 # 0: type
1136 compiler.warn.redundant.cast=\
1137 redundant cast to {0}
1139 # 0: number
1140 compiler.warn.position.overflow=\
1141 Position encoding overflows at line {0}
1143 # 0: file name, 1: number, 2: number
1144 compiler.warn.big.major.version=\
1145 {0}: major version {1} is newer than {2}, the highest major version supported by this compiler.\n\
1146 It is recommended that the compiler be upgraded.
1148 # 0: symbol kind, 1: symbol
1149 compiler.warn.static.not.qualified.by.type=\
1150 static {0} should be qualified by type name, {1}, instead of by an expression
1152 # 0: string
1153 compiler.warn.source.no.bootclasspath=\
1154 bootstrap class path not set in conjunction with -source {0}
1156 # 0: name, 1: number, 2: number, 3: number, 4: number
1157 compiler.warn.future.attr=\
1158 {0} attribute introduced in version {1}.{2} class files is ignored in version {3}.{4} class files
1160 # Warnings related to annotation processing
1161 # 0: name
1162 compiler.warn.proc.package.does.not.exist=\
1163 package {0} does not exist
1165 # 0: name
1166 compiler.warn.proc.file.reopening=\
1167 Attempt to create a file for ''{0}'' multiple times
1169 # 0: name
1170 compiler.warn.proc.type.already.exists=\
1171 A file for type ''{0}'' already exists on the sourcepath or classpath
1173 # 0: name
1174 compiler.warn.proc.type.recreate=\
1175 Attempt to create a file for type ''{0}'' multiple times
1177 # 0: string
1178 compiler.warn.proc.illegal.file.name=\
1179 Cannot create file for illegal name ''{0}''.
1181 # 0: string, 1: string
1182 compiler.warn.proc.suspicious.class.name=\
1183 Creating file for a type whose name ends in {1}: ''{0}''
1185 # 0: name
1186 compiler.warn.proc.file.create.last.round=\
1187 File for type ''{0}'' created in the last round will not be subject to annotation processing.
1189 # 0: string, 1: string
1190 compiler.warn.proc.malformed.supported.string=\
1191 Malformed string ''{0}'' for a supported annotation type returned by processor ''{1}''
1193 # 0: set of string
1194 compiler.warn.proc.annotations.without.processors=\
1195 No processor claimed any of these annotations: {0}
1197 # 0: source version, 1: string, 2: string
1198 compiler.warn.proc.processor.incompatible.source.version=\
1199 Supported source version ''{0}'' from annotation processor ''{1}'' less than -source ''{2}''
1201 compiler.warn.proc.proc-only.requested.no.procs=\
1202 Annotation processing without compilation requested but no processors were found.
1204 compiler.warn.proc.use.implicit=\
1205 Implicitly compiled files were not subject to annotation processing.\n\
1206 Use -implicit to specify a policy for implicit compilation.
1208 compiler.warn.proc.use.proc.or.implicit=\
1209 Implicitly compiled files were not subject to annotation processing.\n\
1210 Use -proc:none to disable annotation processing or -implicit to specify a policy for implicit compilation.
1212 # Print a client-generated warning; assumed to be localized, no translation required
1213 # 0: string
1214 compiler.warn.proc.messager=\
1215 {0}
1217 # 0: set of name
1218 compiler.warn.proc.unclosed.type.files=\
1219 Unclosed files for the types ''{0}''; these types will not undergo annotation processing
1221 # 0: string
1222 compiler.warn.proc.unmatched.processor.options=\
1223 The following options were not recognized by any processor: ''{0}''
1225 compiler.warn.try.explicit.close.call=\
1226 explicit call to close() on an auto-closeable resource
1228 # 0: symbol
1229 compiler.warn.try.resource.not.referenced=\
1230 auto-closeable resource {0} is never referenced in body of corresponding try statement
1232 compiler.warn.unchecked.assign=\
1233 unchecked assignment: {0} to {1}
1235 # 0: symbol, 1: type
1236 compiler.warn.unchecked.assign.to.var=\
1237 unchecked assignment to variable {0} as member of raw type {1}
1239 # 0: symbol, 1: type
1240 compiler.warn.unchecked.call.mbr.of.raw.type=\
1241 unchecked call to {0} as a member of the raw type {1}
1243 compiler.warn.unchecked.cast.to.type=\
1244 unchecked cast to type {0}
1246 # 0: symbol kind, 1: name, 2: list of type, 3: list of type, 4: symbol kind, 5: symbol
1247 compiler.warn.unchecked.meth.invocation.applied=\
1248 unchecked method invocation: {0} {1} in {4} {5} is applied to given types\n\
1249 required: {2}\n\
1250 found: {3}
1252 # 0: type
1253 compiler.warn.unchecked.generic.array.creation=\
1254 unchecked generic array creation for varargs parameter of type {0}
1256 # 0: type
1257 compiler.warn.unchecked.varargs.non.reifiable.type=\
1258 Possible heap pollution from parameterized vararg type {0}
1260 # 0: symbol
1261 compiler.warn.varargs.unsafe.use.varargs.param=\
1262 Varargs method could cause heap pollution from non-reifiable varargs parameter {0}
1264 compiler.warn.missing.deprecated.annotation=\
1265 deprecated item is not annotated with @Deprecated
1267 compiler.warn.invalid.archive.file=\
1268 Unexpected file on path: {0}
1270 compiler.warn.unexpected.archive.file=\
1271 Unexpected extension for archive file: {0}
1273 compiler.warn.div.zero=\
1274 division by zero
1276 compiler.warn.empty.if=\
1277 empty statement after if
1279 compiler.warn.annotation.method.not.found=\
1280 Cannot find annotation method ''{1}()'' in type ''{0}''
1282 compiler.warn.annotation.method.not.found.reason=\
1283 Cannot find annotation method ''{1}()'' in type ''{0}'': {2}
1285 # 0: type, 1: type
1286 compiler.warn.raw.class.use=\
1287 found raw type: {0}\n\
1288 missing type arguments for generic class {1}
1290 # 0: unused, 1: unused
1291 compiler.warn.diamond.redundant.args=\
1292 redundant type arguments in new expression (use diamond operator instead).
1294 # 0: type, 1: type
1295 compiler.warn.diamond.redundant.args.1=\
1296 redundant type arguments in new expression (use diamond operator instead).\n\
1297 explicit: {0}\n\
1298 inferred: {1}
1300 # 0: symbol, 1: message segment
1301 compiler.warn.varargs.redundant.trustme.anno=\
1302 Redundant {0} annotation. {1}
1304 #####
1306 ## The following are tokens which are non-terminals in the language. They should
1307 ## be named as JLS3 calls them when translated to the appropriate language.
1308 compiler.misc.token.identifier=\
1309 <identifier>
1311 compiler.misc.token.character=\
1312 <character>
1314 compiler.misc.token.string=\
1315 <string>
1317 compiler.misc.token.integer=\
1318 <integer>
1320 compiler.misc.token.long-integer=\
1321 <long integer>
1323 compiler.misc.token.float=\
1324 <float>
1326 compiler.misc.token.double=\
1327 <double>
1329 compiler.misc.token.bad-symbol=\
1330 <bad symbol>
1332 compiler.misc.token.end-of-input=\
1333 <end of input>
1335 ## The argument to the following string will always be one of the following:
1336 ## 1. one of the above non-terminals
1337 ## 2. a keyword (JLS1.8)
1338 ## 3. a boolean literal (JLS3.10.3)
1339 ## 4. the null literal (JLS3.10.7)
1340 ## 5. a Java separator (JLS3.11)
1341 ## 6. an operator (JLS3.12)
1342 ##
1343 ## This is the only place these tokens will be used.
1344 # 0: token
1345 compiler.err.expected=\
1346 {0} expected
1348 # 0: token, 1: token
1349 compiler.err.expected2=\
1350 {0} or {1} expected
1352 # 0: token, 1: token, 2: token
1353 compiler.err.expected3=\
1354 {0}, {1}, or {2} expected
1356 compiler.err.premature.eof=\
1357 reached end of file while parsing
1359 ## The following are related in form, but do not easily fit the above paradigm.
1360 compiler.err.dot.class.expected=\
1361 ''.class'' expected
1363 ## The argument to this string will always be either 'case' or 'default'.
1364 # 0: token
1365 compiler.err.orphaned=\
1366 orphaned {0}
1368 # 0: name
1369 compiler.misc.anonymous.class=\
1370 <anonymous {0}>
1372 # 0: name, 1: type
1373 compiler.misc.type.captureof=\
1374 capture#{0} of {1}
1376 compiler.misc.type.captureof.1=\
1377 capture#{0}
1379 compiler.misc.type.none=\
1380 <none>
1382 compiler.misc.unnamed.package=\
1383 unnamed package
1385 #####
1387 # 0: symbol, 1: message segment
1388 compiler.err.cant.access=\
1389 cannot access {0}\n\
1390 {1}
1392 compiler.misc.bad.class.file.header=\
1393 bad class file: {0}\n\
1394 {1}\n\
1395 Please remove or make sure it appears in the correct subdirectory of the classpath.
1397 # 0: file name, 1: message segment
1398 compiler.misc.bad.source.file.header=\
1399 bad source file: {0}\n\
1400 {1}\n\
1401 Please remove or make sure it appears in the correct subdirectory of the sourcepath.
1403 ## The following are all possible strings for the second argument ({1}) of the
1404 ## above strings.
1405 compiler.misc.bad.class.signature=\
1406 bad class signature: {0}
1408 compiler.misc.bad.enclosing.method=\
1409 bad enclosing method attribute: {0}
1411 compiler.misc.bad.runtime.invisible.param.annotations=\
1412 bad RuntimeInvisibleParameterAnnotations attribute: {0}
1414 compiler.misc.bad.const.pool.tag=\
1415 bad constant pool tag: {0}
1417 compiler.misc.bad.const.pool.tag.at=\
1418 bad constant pool tag: {0} at {1}
1420 compiler.misc.bad.signature=\
1421 bad signature: {0}
1423 compiler.misc.class.file.wrong.class=\
1424 class file contains wrong class: {0}
1426 compiler.misc.class.file.not.found=\
1427 class file for {0} not found
1429 # 0: name
1430 compiler.misc.file.doesnt.contain.class=\
1431 file does not contain class {0}
1433 compiler.misc.file.does.not.contain.package=\
1434 file does not contain package {0}
1436 compiler.misc.illegal.start.of.class.file=\
1437 illegal start of class file
1439 compiler.misc.unable.to.access.file=\
1440 unable to access file: {0}
1442 compiler.misc.unicode.str.not.supported=\
1443 unicode string in class file not supported
1445 compiler.misc.undecl.type.var=\
1446 undeclared type variable: {0}
1448 compiler.misc.wrong.version=\
1449 class file has wrong version {0}.{1}, should be {2}.{3}
1451 #####
1453 # 0: type, 1: type or symbol
1454 compiler.err.not.within.bounds=\
1455 type argument {0} is not within bounds of type-variable {1}
1457 ## The following are all possible strings for the second argument ({1}) of the
1458 ## above string.
1460 ## none yet...
1462 #####
1464 # 0: message segment, 1: type, 2: type
1465 compiler.err.prob.found.req=\
1466 {0}\n\
1467 required: {2}\n\
1468 found: {1}
1470 # 0: message segment, 1: type, 2: type
1471 compiler.warn.prob.found.req=\
1472 {0}\n\
1473 required: {2}\n\
1474 found: {1}
1476 compiler.err.prob.found.req.1=\
1477 {0} {3}\n\
1478 required: {2}\n\
1479 found: {1}
1481 ## The following are all possible strings for the first argument ({0}) of the
1482 ## above strings.
1483 compiler.misc.incompatible.types=\
1484 incompatible types
1486 # 0: message segment
1487 compiler.misc.incompatible.types.1=\
1488 incompatible types; {0}
1490 compiler.misc.inconvertible.types=\
1491 inconvertible types
1493 compiler.misc.possible.loss.of.precision=\
1494 possible loss of precision
1496 compiler.misc.unchecked.assign=\
1497 unchecked conversion
1499 # compiler.misc.storecheck=\
1500 # assignment might cause later store checks to fail
1501 # compiler.misc.unchecked=\
1502 # assigned array cannot dynamically check its stores
1503 compiler.misc.unchecked.cast.to.type=\
1504 unchecked cast
1506 compiler.misc.assignment.from.super-bound=\
1507 assignment from super-bound type {0}
1509 compiler.misc.assignment.to.extends-bound=\
1510 assignment to extends-bound type {0}
1512 # compiler.err.star.expected=\
1513 # ''*'' expected
1514 # compiler.err.no.elem.type=\
1515 # \[\*\] cannot have a type
1517 compiler.misc.try.not.applicable.to.type=\
1518 try-with-resources not applicable to variable type
1520 #####
1522 # 0: message segment or type, 1: message segment
1523 compiler.err.type.found.req=\
1524 unexpected type\n\
1525 required: {1}\n\
1526 found: {0}
1528 ## The following are all possible strings for the first argument ({0}) of the
1529 ## above string.
1530 compiler.misc.type.req.class=\
1531 class
1533 compiler.misc.type.req.class.array=\
1534 class or array
1536 compiler.misc.type.req.array.or.iterable=\
1537 array or java.lang.Iterable
1539 compiler.misc.type.req.ref=\
1540 reference
1542 compiler.misc.type.req.exact=\
1543 class or interface without bounds
1545 # 0: type
1546 compiler.misc.type.parameter=\
1547 type parameter {0}
1549 #####
1551 ## The following are all possible strings for the last argument of all those
1552 ## diagnostics whose key ends in ".1"
1553 compiler.misc.undetermined.type=\
1554 undetermined type
1556 compiler.misc.type.variable.has.undetermined.type=\
1557 type variable {0} has undetermined type
1559 # 0: type, 1: list of type
1560 compiler.misc.no.unique.maximal.instance.exists=\
1561 no unique maximal instance exists for type variable {0} with upper bounds {1}
1563 compiler.misc.no.unique.minimal.instance.exists=\
1564 no unique minimal instance exists for type variable {0} with lower bounds {1}
1566 # 0: list of type, 1: type, 2: type
1567 compiler.misc.infer.no.conforming.instance.exists=\
1568 no instance(s) of type variable(s) {0} exist so that {1} conforms to {2}
1570 # 0: list of type, 1: type, 2: type
1571 compiler.misc.infer.no.conforming.assignment.exists=\
1572 no instance(s) of type variable(s) {0} exist so that argument type {1} conforms to formal parameter type {2}
1574 compiler.misc.infer.arg.length.mismatch=\
1575 cannot instantiate from arguments because actual and formal argument lists differ in length
1577 # 0: type, 1: list of type
1578 compiler.misc.inferred.do.not.conform.to.bounds=\
1579 inferred type does not conform to declared bound(s)\n\
1580 inferred: {0}\n\
1581 bound(s): {1}
1583 # 0: symbol
1584 compiler.misc.diamond=\
1585 {0}<>
1587 # 0: list of type, 1: message segment
1588 compiler.misc.diamond.invalid.arg=\
1589 type argument {0} inferred for {1} is not allowed in this context
1591 # 0: list of type, 1: message segment
1592 compiler.misc.diamond.invalid.args=\
1593 type arguments {0} inferred for {1} are not allowed in this context
1595 # 0: type, 1: list of type
1596 compiler.misc.explicit.param.do.not.conform.to.bounds=\
1597 explicit type argument {0} does not conform to declared bound(s) {1}
1599 compiler.misc.arg.length.mismatch=\
1600 actual and formal argument lists differ in length
1602 # 0: type, 1: type
1603 compiler.misc.no.conforming.assignment.exists=\
1604 actual argument {0} cannot be converted to {1} by method invocation conversion
1606 # 0: type, 1: type
1607 compiler.misc.varargs.argument.mismatch=\
1608 argument type {0} does not conform to vararg element type {1}
1610 #####
1612 ## The first argument ({0}) is a "kindname".
1613 # 0: symbol kind, 1: symbol, 2: symbol
1614 compiler.err.abstract.cant.be.accessed.directly=\
1615 abstract {0} {1} in {2} cannot be accessed directly
1617 ## The first argument ({0}) is a "kindname".
1618 # 0: symbol kind, 1: symbol
1619 compiler.err.non-static.cant.be.ref=\
1620 non-static {0} {1} cannot be referenced from a static context
1622 ## Both arguments ({0}, {1}) are "kindname"s. {0} is a comma-separated list
1623 ## of kindnames (the list should be identical to that provided in source.
1624 compiler.err.unexpected.type=\
1625 unexpected type\n\
1626 required: {0}\n\
1627 found: {1}
1629 ## The first argument {0} is a "kindname" (e.g. 'constructor', 'field', etc.)
1630 ## The second argument {1} is the non-resolved symbol
1631 ## The third argument {2} is a list of type parameters (non-empty if {1} is a method)
1632 ## The fourth argument {3} is a list of argument types (non-empty if {1} is a method)
1633 # 0: symbol kind, 1: name, 2: unused, 3: unused
1634 compiler.err.cant.resolve=\
1635 cannot find symbol\n\
1636 symbol: {0} {1}
1638 # 0: symbol kind, 1: name, 2: unused, 3: list of type
1639 compiler.err.cant.resolve.args=\
1640 cannot find symbol\n\
1641 symbol: {0} {1}({3})
1643 # 0: symbol kind, 1: name, 2: list of type, 3: list of type
1644 compiler.err.cant.resolve.args.params=\
1645 cannot find symbol\n\
1646 symbol: {0} <{2}>{1}({3})
1648 ## arguments from {0} to {3} have the same meaning as above
1649 ## The fifth argument {4} is a location subdiagnostic (see below)
1650 # 0: symbol kind, 1: name, 2: unused, 3: unused, 4: message segment
1651 compiler.err.cant.resolve.location=\
1652 cannot find symbol\n\
1653 symbol: {0} {1}\n\
1654 location: {4}
1656 # 0: symbol kind, 1: name, 2: unused, 3: list of type, 4: message segment
1657 compiler.err.cant.resolve.location.args=\
1658 cannot find symbol\n\
1659 symbol: {0} {1}({3})\n\
1660 location: {4}
1662 # 0: symbol kind, 1: name, 2: list of type, 3: list, 4: message segment
1663 compiler.err.cant.resolve.location.args.params=\
1664 cannot find symbol\n\
1665 symbol: {0} <{2}>{1}({3})\n\
1666 location: {4}
1668 ##a location subdiagnostic is composed as follows:
1669 ## The first argument {0} is the location "kindname" (e.g. 'constructor', 'field', etc.)
1670 ## The second argument {1} is the location name
1671 ## The third argument {2} is the location type (only when {1} is a variable name)
1673 # 0: symbol kind, 1: symbol, 2: unused
1674 compiler.misc.location=\
1675 {0} {1}
1677 # 0: symbol kind, 1: symbol, 2: type
1678 compiler.misc.location.1=\
1679 {0} {1} of type {2}
1681 ## The following are all possible string for "kindname".
1682 ## They should be called whatever the JLS calls them after it been translated
1683 ## to the appropriate language.
1684 # compiler.misc.kindname.constructor=\
1685 # static member
1686 compiler.misc.kindname.annotation=\
1687 @interface
1689 compiler.misc.kindname.constructor=\
1690 constructor
1692 compiler.misc.kindname.enum=\
1693 enum
1695 compiler.misc.kindname.interface=\
1696 interface
1698 compiler.misc.kindname.static=\
1699 static
1701 compiler.misc.kindname.type.variable=\
1702 type variable
1704 compiler.misc.kindname.type.variable.bound=\
1705 bound of type variable
1707 compiler.misc.kindname.variable=\
1708 variable
1710 compiler.misc.kindname.value=\
1711 value
1713 compiler.misc.kindname.method=\
1714 method
1716 compiler.misc.kindname.class=\
1717 class
1719 compiler.misc.kindname.package=\
1720 package
1722 #####
1724 compiler.misc.no.args=\
1725 no arguments
1727 # 0: message segment
1728 compiler.err.override.static=\
1729 {0}\n\
1730 overriding method is static
1732 # 0: message segment, 1: set of modifier
1733 compiler.err.override.meth=\
1734 {0}\n\
1735 overridden method is {1}
1737 # 0: message segment, 1: type
1738 compiler.err.override.meth.doesnt.throw=\
1739 {0}\n\
1740 overridden method does not throw {1}
1742 # In the following string {1} is a space separated list of Java Keywords, as
1743 # they would have been declared in the source code
1744 # 0: message segment, 1: set of modifier
1745 compiler.err.override.weaker.access=\
1746 {0}\n\
1747 attempting to assign weaker access privileges; was {1}
1749 # 0: message segment, 1: type, 2: type
1750 compiler.err.override.incompatible.ret=\
1751 {0}\n\
1752 return type {1} is not compatible with {2}
1754 # 0: message segment, 1: type, 2: type
1755 compiler.warn.override.unchecked.ret=\
1756 {0}\n\
1757 return type requires unchecked conversion from {1} to {2}
1759 # 0: message segment, 1: type
1760 compiler.warn.override.unchecked.thrown=\
1761 {0}\n\
1762 overridden method does not throw {1}
1764 ## The following are all possible strings for the first argument ({0}) of the
1765 ## above strings.
1766 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1767 compiler.misc.cant.override=\
1768 {0} in {1} cannot override {2} in {3}
1770 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1771 compiler.misc.cant.implement=\
1772 {0} in {1} cannot implement {2} in {3}
1774 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1775 compiler.misc.clashes.with=\
1776 {0} in {1} clashes with {2} in {3}
1778 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1779 compiler.misc.unchecked.override=\
1780 {0} in {1} overrides {2} in {3}
1782 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1783 compiler.misc.unchecked.implement=\
1784 {0} in {1} implements {2} in {3}
1786 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1787 compiler.misc.unchecked.clash.with=\
1788 {0} in {1} overrides {2} in {3}
1790 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1791 compiler.misc.varargs.override=\
1792 {0} in {1} overrides {2} in {3}
1794 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1795 compiler.misc.varargs.implement=\
1796 {0} in {1} implements {2} in {3}
1798 # 0: symbol, 1: symbol, 2: symbol, 3: symbol
1799 compiler.misc.varargs.clash.with=\
1800 {0} in {1} overrides {2} in {3}
1802 compiler.misc.non.denotable.type=\
1803 Non-denotable type {0} not allowed here
1805 # 0: symbol kind, 1: symbol, 2: symbol, 3: message segment
1806 compiler.misc.inapplicable.method=\
1807 {0} {1}.{2} is not applicable\n\
1808 ({3})
1810 ########################################
1811 # Diagnostics for language feature changes
1812 ########################################
1813 # 0: string
1814 compiler.err.unsupported.fp.lit=\
1815 hexadecimal floating point literals are not supported in -source {0}\n\
1816 (use -source 5 or higher to enable hexadecimal floating point literals)
1818 # 0: string
1819 compiler.err.unsupported.binary.lit=\
1820 binary literals are not supported in -source {0}\n\
1821 (use -source 7 or higher to enable binary literals)
1823 # 0: string
1824 compiler.err.unsupported.underscore.lit=\
1825 underscores in literals are not supported in -source {0}\n\
1826 (use -source 7 or higher to enable underscores in literals)
1828 # 0: string
1829 compiler.err.try.with.resources.not.supported.in.source=\
1830 try-with-resources is not supported in -source {0}\n\
1831 (use -source 7 or higher to enable try-with-resources)
1833 compiler.warn.enum.as.identifier=\
1834 as of release 5, ''enum'' is a keyword, and may not be used as an identifier\n\
1835 (use -source 5 or higher to use ''enum'' as a keyword)
1837 compiler.warn.assert.as.identifier=\
1838 as of release 1.4, ''assert'' is a keyword, and may not be used as an identifier\n\
1839 (use -source 1.4 or higher to use ''assert'' as a keyword)
1841 compiler.err.enum.as.identifier=\
1842 as of release 5, ''enum'' is a keyword, and may not be used as an identifier\n\
1843 (use -source 1.4 or lower to use ''enum'' as an identifier)
1845 compiler.err.assert.as.identifier=\
1846 as of release 1.4, ''assert'' is a keyword, and may not be used as an identifier\n\
1847 (use -source 1.3 or lower to use ''assert'' as an identifier)
1849 # 0: string
1850 compiler.err.generics.not.supported.in.source=\
1851 generics are not supported in -source {0}\n\
1852 (use -source 5 or higher to enable generics)
1854 # 0: string
1855 compiler.err.varargs.not.supported.in.source=\
1856 variable-arity methods are not supported in -source {0}\n\
1857 (use -source 5 or higher to enable variable-arity methods)
1859 # 0: string
1860 compiler.err.annotations.not.supported.in.source=\
1861 annotations are not supported in -source {0}\n\
1862 (use -source 5 or higher to enable annotations)
1864 #308 compiler.err.type.annotations.not.supported.in.source=\
1865 #308 type annotations are not supported in -source {0}\n\
1866 #308 (use -source 7 or higher to enable type annotations)
1868 # 0: string
1869 compiler.err.foreach.not.supported.in.source=\
1870 for-each loops are not supported in -source {0}\n\
1871 (use -source 5 or higher to enable for-each loops)
1873 # 0: string
1874 compiler.err.static.import.not.supported.in.source=\
1875 static import declarations are not supported in -source {0}\n\
1876 (use -source 5 or higher to enable static import declarations)
1878 # 0: string
1879 compiler.err.enums.not.supported.in.source=\
1880 enums are not supported in -source {0}\n\
1881 (use -source 5 or higher to enable enums)
1883 # 0: string
1884 compiler.err.diamond.not.supported.in.source=\
1885 diamond operator is not supported in -source {0}\n\
1886 (use -source 7 or higher to enable diamond operator)
1888 # 0: string
1889 compiler.err.multicatch.not.supported.in.source=\
1890 multi-catch statement is not supported in -source {0}\n\
1891 (use -source 7 or higher to enable multi-catch statement)
1893 # 0: string
1894 compiler.err.string.switch.not.supported.in.source=\
1895 strings in switch are not supported in -source {0}\n\
1896 (use -source 7 or higher to enable strings in switch)
1898 ########################################
1899 # Diagnostics for where clause implementation
1900 # used by the RichDiagnosticFormatter.
1901 ########################################
1903 compiler.misc.type.null=\
1904 <null>
1906 # X#n (where n is an int id) is disambiguated tvar name
1907 # 0: name, 1: number
1908 compiler.misc.type.var=\
1909 {0}#{1}
1911 # CAP#n (where n is an int id) is an abbreviation for 'captured type'
1912 # 0: number
1913 compiler.misc.captured.type=\
1914 CAP#{0}
1916 # <INT#n> (where n is an int id) is an abbreviation for 'intersection type'
1917 # 0: number
1918 compiler.misc.intersection.type=\
1919 INT#{0}
1921 # where clause for captured type: contains upper ('extends {1}') and lower
1922 # ('super {2}') bound along with the wildcard that generated this captured type ({3})
1923 # 0: type, 1: type, 2: type, 3: type
1924 compiler.misc.where.captured=\
1925 {0} extends {1} super: {2} from capture of {3}
1927 # compact where clause for captured type: contains upper ('extends {1}') along
1928 # with the wildcard that generated this captured type ({3})
1929 # 0: type, 1: type, 2: unused, 3: type
1930 compiler.misc.where.captured.1=\
1931 {0} extends {1} from capture of {3}
1933 # where clause for type variable: contains upper bound(s) ('extends {1}') along with
1934 # the kindname ({2}) and location ({3}) in which the typevar has been declared
1935 # 0: type, 1: list of type, 2: symbol kind, 3: symbol
1936 compiler.misc.where.typevar=\
1937 {0} extends {1} declared in {2} {3}
1939 # compact where clause for type variable: contains the kindname ({2}) and location ({3})
1940 # in which the typevar has been declared
1941 compiler.misc.where.typevar.1=\
1942 {0} declared in {2} {3}
1944 # where clause for type variable: contains all the upper bound(s) ('extends {1}')
1945 # of this intersection type
1946 # 0: type, 1: list of type
1947 compiler.misc.where.intersection=\
1948 {0} extends {1}
1950 ### Where clause headers ###
1951 compiler.misc.where.description.captured=\
1952 where {0} is a fresh type-variable:
1954 # 0: set of type
1955 compiler.misc.where.description.typevar=\
1956 where {0} is a type-variable:
1958 # 0: set of type
1959 compiler.misc.where.description.intersection=\
1960 where {0} is an intersection type:
1962 # 0: set of type
1963 compiler.misc.where.description.captured.1=\
1964 where {0} are fresh type-variables:
1966 # 0: set of type
1967 compiler.misc.where.description.typevar.1=\
1968 where {0} are type-variables:
1970 compiler.misc.where.description.intersection.1=\
1971 where {0} are intersection types: