[clean-list] Update head of the list in-place?

Edsko de Vries devriese at cs.tcd.ie
Thu Apr 24 12:51:19 MEST 2008


Would it be easy to write a function

  update_head :: *[.a] .a -> *[.a]
  update_head = code inline { .. }

which updates the head of a list in-place (given a spine-unique list, of
course)? I feel it should be straightforward to someone who knows ABC
code inside-out, but unfortunately I am not such a person.

Any help would be appreciated :)


More information about the clean-list mailing list