Changed to use inherit instead of explicit prototype, see #1.