You have to create a list with a one in it either way. The tail of the tail of the tail of [1,2,3,1]
is [1]
. So if you have [1,2,3,1]
in memory, you also have [1]
somewhere in memory.
So even if there were operator like [1,2,3] @:: 1
, it wouldn't make a difference since it still needs to create a list with a one in it.
PS: The real issue with xs @ [x]
isn't the creation of the list, but the fact that its runtime is in O(n) (as opposed to x :: xs
, which is in O(1)). This is also an issue inherent in the nature of immutable singly linked lists and thus can't be helped, but it's why you generally should avoid appending to the end of a list like that.