Added delegates and interfaces, bug fixes in compiler