A slice seems overkill to refer to just one object, but is thatthe best way ?struct Tree { Tree[] children; } Is one way to do it.
You can add some nice sugar for this as well: struct Tree { this(string data, Tree[] children...) { this.data = data; this.children = children; } string data; Tree[] children; } http://dpaste.dzfl.pl/76a8a4c44345