Adds basic support for trees