bug or feature?

Serge Aleynikov <>
Tue Apr 18 13:15:17 CEST 2006


Could anyone explain why matches #5 and #6 below fail?  I didn't find in 
documentation a limitation of not being able to specify a variable as 
the first argument of the '++' transform.

Eshell V5.4.13  (abort with ^G)
()1> Prefix = "200".
"200"
()2> Suffix = "100".
"100"
()3> "200" ++ "100" = "200100".
"200100"
()4> "200" ++ Suffix = "200100".
"200100"
()5> Prefix ++ "100" = "200100".
** 1: illegal pattern **
()6> Prefix ++ Suffix = "200100".
** 1: illegal pattern **
()7> Prefix ++ Suffix.
"200100"
()9> "200" ++ Suffix = v(7).
"200100"

Regards,

Serge



More information about the erlang-questions mailing list