Question

Sometimes when i try to run a command in the Erlang shell (for example calling a function from a module etc) the shell doesn't give any output or error message and just returns. I am sure that i give the command in the right shape (with a dot at the end etc). To solve this i have to give the following commands in the shell:

'. or ".

And then the shell prints a long atom or what ever and then after that i can run my original command correctly. Does anyone have seen a same issue? And what is the reason for this?

Was it helpful?

Solution

This looks like there were an initial ' or " in the command line. So the shell is waiting for the second ' or " which closes the atom or string declaration. It prints the evaluation result and is now ready for the next command.

Look at this example in the console (started with erl):

Eshell V10.6.2  (abort with ^G)
1> io:format("Hello world!").
Hello world!ok
2> io:format("Hello world!             ).
2> ".
* 2: syntax error before: '.'
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top