------- Additional Comments From tromey at gcc dot gnu dot org 2005-06-21 18:36 ------- The bug here is that the semantic analysis for a case expression, in parse.y:java_complete_lhs(), just does this:
/* First, the case expression must be constant. Values of final fields are accepted. */ cn = fold (cn); However, fold() does not know about final fields and the like. fold_constant_for_init doesn't seem to be factored properly to be useful here, either. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21540