Basic inheritance functionality

Python inheritance is remarkably complicated... this commit implements the basics.
There are still a fair number of things that are unimplemented, and some things
like inheriting from all the basic types haven't been added yet.