utf-8 characters in file make Save operation fail
<--cut-->
UTF-8 chars into comments. Save with ERROR!
!MESSAGE Unable to create editor ID org.erlide.ui.editors.erl.ErlangEditor: Editor could not be initialized.
!STACK 0
org.eclipse.core.runtime.AssertionFailedException: null argument:
at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:86)
at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:74)
at org.erlide.core.erlang.internal.ErlElement.<init>(ErlElement.java:113)
at org.erlide.core.erlang.internal.SourceRefElement.<init>(SourceRefElement.java:38)
at org.erlide.core.erlang.internal.ErlComment.<init>(ErlComment.java:27)
at org.erlide.core.erlang.internal.ErlParser.createComment(ErlParser.java:154)
at org.erlide.core.erlang.internal.ErlParser.parse(ErlParser.java:110)
- тестирование
UTF-8 chars into comments. Save with ERROR!
!MESSAGE Unable to create editor ID org.erlide.ui.editors.erl.ErlangEditor: Editor could not be initialized.
!STACK 0
org.eclipse.core.runtime.AssertionFailedException: null argument:
at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:86)
at org.eclipse.core.runtime.Assert.isNotNull(Assert.java:74)
at org.erlide.core.erlang.internal.ErlElement.<init>(ErlElement.java:113)
at org.erlide.core.erlang.internal.SourceRefElement.<init>(SourceRefElement.java:38)
at org.erlide.core.erlang.internal.ErlComment.<init>(ErlComment.java:27)
at org.erlide.core.erlang.internal.ErlParser.createComment(ErlParser.java:154)
at org.erlide.core.erlang.internal.ErlParser.parse(ErlParser.java:110)
Leave a comment
on 2009-07-10 19:03 *
By Vlad Dumitrescu
I think that changing the content type in Eclipse would be enough to address this.
Updating tickets (#384, #389, #396, #64, #291, #352, #358, #393, #398, #399, #41, #46, #52, #57, #61, #83, #93, #100, #111, #115, #135, #145, #148, #149, #152, #155, #159, #163, #181, #182, #194, #200, #208, #217, #218, #220, #221, #224, #229, #261, #265, #274, #280, #281, #283, #285, #294, #298, #307, #316, #318, #331, #332, #335, #336, #338, #348)
on 2009-07-17 13:38 *
By Vlad Dumitrescu
We can't change the encoding in Eclipse, because older files are ISO-8859-1, which is an incompatible format (if there are characters outside the ASCII range). Whatever we choose, something will be wrong: either a file can't be saved, or it shows "weird" characters....
on 2009-07-17 13:45 *
By Vlad Dumitrescu
Status changed from New to Invalid
Status changed from New to Invalid
From Erlang docs (http://erlang.org/doc/apps/stdlib/unicode_usage.html)
2.3 Basic language support for Unicode
First of all, Erlang is still defined to be written in the ISO-latin-1 character set. Functions have to be named in that character set, atoms are restricted to ISO-latin-1 and regular strings are still lists of characters 0..255 in the ISO-latin-1 encoding. This has not (yet) changed, but the language has been slightly extended to cope with Unicode characters and encodings.
....
Also the source code is (for now) still expected to be written using the ISO-latin-1 character set, why Unicode characters beyond that range cannot be entered in string literals.
2.3 Basic language support for Unicode
First of all, Erlang is still defined to be written in the ISO-latin-1 character set. Functions have to be named in that character set, atoms are restricted to ISO-latin-1 and regular strings are still lists of characters 0..255 in the ISO-latin-1 encoding. This has not (yet) changed, but the language has been slightly extended to cope with Unicode characters and encodings.
....
Also the source code is (for now) still expected to be written using the ISO-latin-1 character set, why Unicode characters beyond that range cannot be entered in string literals.