如何在 Windows 中更改默认系统 java 编码形式? [英] How to change the defaults system java encode form in windows?

查看:34
本文介绍了如何在 Windows 中更改默认系统 java 编码形式?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试编译(使用 javac)某些 Java 源文件时,其中包含一个注释行,其中包含一些无法识别的字符,例如 ascii 代码 129 (~A),出现错误.

When I tried to compile (use javac)some java sources files include a comment line which has some unrecognized char like ascii code 129 (~A), error got.

源代码如下所示:

 // ascii 129 is ? (Acutally it show ~A in VIM but show ? when I directly copy it here)

上面的代码行是注释,应该不会引起任何错误,但是如果发生了,我认为应该是jave编码形式的问题,我该如何解决这个问题?

The above code line is a comment, it should not cause any error, but if it did, I think it should be a problem about the jave encode form, how can I solve this problem?

谢谢.

推荐答案

看看这个答案.它对我有用,我不必再担心了:) https://stackoverflow.com/a/623036/971592

Take a look at this answer. It worked for me, and I don't have to worry about it anymore :) https://stackoverflow.com/a/623036/971592

这篇关于如何在 Windows 中更改默认系统 java 编码形式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆