Eclipse3.1.x调试程序时为何出现“-Unmatched braces in the pattern”?

2008年11月11日  | 标签: , ,

以下两种情况均出现:Unmatched braces in the pattern 异常,
1、tomcat运行时出现错误转入调试时
2、Eclipse 3.1.x 中文在代码编辑器中按 Ctrl 点代码链接 查看源代码时

原因分析:
由错误报告出现问题的org.eclipse.jdt.internal.core.util.Messages 类, disassembler_opentypedeclaration 字段,对应于语言包插件 plugins 目录下的 org.eclipse.jdt.core.nl1_3.1.1.jar 包,该包 org\eclipse\jdt\internal\core\util 目录下的 messages_zh.properties 文件,有段代码为 disassembler_opentypedeclaration=\ \u201C{\u201D,有的可能为
disassembler_opentypedeclaration=\ “{”,
同目录下的其它语言文件这段代码为 disassembler_opentypedeclaration=\ ‘{’,
这可能是 Eclipse 在语言转换时产生的错误. 修改代码 \u201C{\u201D (或“{”) 为 ‘{’.
解压 org.eclipse.jdt.core.nl1_3.1.1.jar, 修改 messages_zh.properties 文件,
再压缩成 .zip 文件, 改扩展名为 .jar (或 jar 命令打包), 在Eclipse 关闭时替换原来的 jar 包 即可.

点击这里下载修改好的org.eclipse.jdt.core.nl1_3.1.1.jar文件。

类别(j2ee) | 浏览(701) | 发表评论 | Trackback
目前还没有任何评论.