src/share/classes/com/sun/tools/javac/comp/Check.java

changeset 1555
762d0af062f5
parent 1550
1df20330f6bd
child 1571
af8417e590f4
child 1579
0baaae675b19
equal deleted inserted replaced
1554:5125b9854d07 1555:762d0af062f5
1021 return visit(t.type); 1021 return visit(t.type);
1022 } 1022 }
1023 }; 1023 };
1024 1024
1025 /** Check that given modifiers are legal for given symbol and 1025 /** Check that given modifiers are legal for given symbol and
1026 * return modifiers together with any implicit modififiers for that symbol. 1026 * return modifiers together with any implicit modifiers for that symbol.
1027 * Warning: we can't use flags() here since this method 1027 * Warning: we can't use flags() here since this method
1028 * is called during class enter, when flags() would cause a premature 1028 * is called during class enter, when flags() would cause a premature
1029 * completion. 1029 * completion.
1030 * @param pos Position to be used for error reporting. 1030 * @param pos Position to be used for error reporting.
1031 * @param flags The set of modifiers given in a definition. 1031 * @param flags The set of modifiers given in a definition.
1067 else { 1067 else {
1068 mask = MethodFlags; 1068 mask = MethodFlags;
1069 } 1069 }
1070 // Imply STRICTFP if owner has STRICTFP set. 1070 // Imply STRICTFP if owner has STRICTFP set.
1071 if (((flags|implicit) & Flags.ABSTRACT) == 0) 1071 if (((flags|implicit) & Flags.ABSTRACT) == 0)
1072 implicit |= sym.owner.flags_field & STRICTFP; 1072 implicit |= sym.owner.flags_field & STRICTFP;
1073 break; 1073 break;
1074 case TYP: 1074 case TYP:
1075 if (sym.isLocal()) { 1075 if (sym.isLocal()) {
1076 mask = LocalClassFlags; 1076 mask = LocalClassFlags;
1077 if (sym.name.isEmpty()) { // Anonymous class 1077 if (sym.name.isEmpty()) { // Anonymous class

mercurial