Basic support of inner classes

All in the title.
Maybe not the cleanest and best way to do that, but it works