An old implementation of Ukkonen's Algorithm that I wrote a while ago