|
RE: the beginner: msg#00425lang.erlang.general
> From: wicaksono [mailto:wicak.noeg@xxxxxxxxxx] > > hi all, i'am just starting this erlang. I try to make > first aplication using windows as my os. I create a file > at c>Program Files\erl5.2\math1.erl as user guide. > but while I compile it always show > > ./math1.erl:8: premature end > ./math1.erl:8: no module definition > error > > what is that mean ? > Hi, What have you put in your math1.erl file? Did you forget the full stop ('.') at the end of the program? Here is the program from the tutorial: -module(math1). -export([factorial/1]). factorial(0) -> 1; factorial(N) -> N * factorial(N-1). ^^^ This compiles fine, but if you forget the full stop at the end, like this: -module(math1). -export([factorial/1]). factorial(0) -> 1; factorial(N) -> N * factorial(N-1) ^^^ the compiler gives the "premature end" error. Regards, Dominic. |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: the beginner: 00425, Bengt Kleberg |
|---|---|
| Next by Date: | Re: the beginner: 00425, Taavi Talvik |
| Previous by Thread: | Re: the beginneri: 00425, Bengt Kleberg |
| Next by Thread: | Re: the beginner: 00425, wicaksono |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |