Function matching w/ "abc" ++ Rest

dizzyd dizzyd@REDACTED
Fri Dec 9 07:01:04 CET 2005

A general Erlang theory/performance question...

If I define a series of functions like so:

f1("abc" ++ Rest) ->
f1("def" ++ Rest) ->

Is that ++ operator creating a new list and appending to it for the match? Are there scary amounts of list comparisons and overhead happening here? There doesn't seem to be anything about this form in the Erlang docs, yet it works. What's going on? 

Sent using Mail2Forum (

More information about the erlang-questions mailing list