Erlang/OTP Forums

Author Message

<  Erlang questions mailing list  ~  Possible bug?

svg at ptt.chel.su
Posted: Tue Feb 02, 1999 9:07 pm Reply with quote
Guest
Good day.

I installed and now use Open source Erlang, but then I am trying to compile
code this letters others than ASCII(I'm a russian man) in atoms or
strings I get compilation error.

In interpreter the same code works fine without errors.

My current environment is :

Red Hat Linux 5.2(Intel).
Erlang-47.4.0 .

Regards.
---
Vladimir Sekissov svg_at_ptt.chel.su


Post generated using Mail2Forum (http://m2f.sourceforge.net)
klacke at erix.ericsson.s
Posted: Wed Feb 03, 1999 8:25 am Reply with quote
Guest
Vladimir Sekissov writes:
> Good day.
>
> I installed and now use Open source Erlang, but then I am trying to compile
> code this letters others than ASCII(I'm a russian man) in atoms or
> strings I get compilation error.
>
> In interpreter the same code works fine without errors.
>

Basically Erlang doesn't really support anything but plain ascii
today. However the usage of non-ascii characters should not
lead to compile time errors, only to ugly printouts.

-module(a).
-compile(export_all).

a() ->
"
per at erix.ericsson.se
Posted: Wed Feb 03, 1999 8:50 am Reply with quote
Guest
Klacke wrote:
>Basically Erlang doesn't really support anything but plain ascii
>today. However the usage of non-ascii characters should not
>lead to compile time errors, only to ugly printouts.

Actually, if you (on Solaris) set environment LANG=sv, or
LC_CTYPE=iso_8859_1, your example produces a perfectly beautiful
printout:

1> a:a().
"
klacke at erix.ericsson.s
Posted: Wed Feb 03, 1999 9:11 am Reply with quote
Guest
Per Hedeland writes:
> Klacke wrote:
> >Basically Erlang doesn't really support anything but plain ascii
> >today. However the usage of non-ascii characters should not
> >lead to compile time errors, only to ugly printouts.
>
> Actually, if you (on Solaris) set environment LANG=sv, or
> LC_CTYPE=iso_8859_1, your example produces a perfectly beautiful
> printout:
>
> 1> a:a().
> "
ulf.wiger at etxb.ericsso
Posted: Wed Feb 03, 1999 10:16 am Reply with quote
Guest
Per Hedeland wrote:
>
> Klacke wrote:
> >Basically Erlang doesn't really support anything but plain ascii
> >today. However the usage of non-ascii characters should not
> >lead to compile time errors, only to ugly printouts.
>
> Actually, if you (on Solaris) set environment LANG=sv, or
> LC_CTYPE=iso_8859_1, your example produces a perfectly beautiful
> printout:
>
> 1> a:a().
> "
ulf.wiger at etxb.ericsso
Posted: Wed Feb 03, 1999 10:16 am Reply with quote
Guest
Per Hedeland wrote:
>
> PS Other things (outside Erlang) may "break" in particular if you set
> LANG, e.g. floating point numbers, dates, error messages, etc may start
> to get printed in funny ways that the standardization bodies think you
> want - I guess some would call this a "feature" - oh well...:-)

You should be able to avoid that by setting the desired environment
variable in Erlang only:

gandalf 10> erl -boot start_clean
Erlang (JAM) emulator version 4.7.3.4

Eshell V4.7.3.4 (abort with ^G)
1> a:a().
"345344366"



gandalf 11> erl -boot start_clean -env LANG sv
Erlang (JAM) emulator version 4.7.3.4

Eshell V4.7.3.4 (abort with ^G)
1> a:a().
"
rv at erix.ericsson.se
Posted: Wed Feb 03, 1999 10:56 am Reply with quote
Guest
Claes Wikstrom <klacke_at_erix.ericsson.se> writes:
>On the other hand, if we try to use non-ascii chracters in
>i.e function names, it still doesn't work as expected.
>
>-module(a).
>
>

Display posts from previous:  

All times are GMT
Page 1 of 1
This forum is locked: you cannot post, reply to, or edit topics.

Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum