I have no idea what I was smoking in that period of my life or how I ever got the bootstrap functioning?
namespace bind ( using system using position using ast using transform def find_constructor_name: ast -> ast = [ type_universal p t0 t1 -> find_constructor_name t1 | type_abstraction p t0 t1 -> find_constructor_name t1 | type_constrain p t0 t1 t2 -> find_constructor_name t2 | type_instance p t0 t1 ee -> find_constructor_name t1 | type_application p t0 t1 -> find_constructor_name t0 | t -> t ] def reshape_bind: reshape ast = [ i0, type_record p i t _e -> type_record p i (set_pos p i0) _e | i0, decl_method p c id aa i t _e -> decl_method p c id aa (set_pos p i0) t _e | i0, decl_bind p c id aa i t _e -> decl_bind p c id aa (set_pos p i0) t _e | i0, e -> reshape_child reshape_bind i0 e ] def reshape_bind_search: reshape unit = [ u, e -> [ decl_space p c id aa dd -> reshape_child reshape_bind_search u e | part p c id im dd -> reshape_child reshape_bind_search u e | decl_interface p c id aa t k -> reshape_child reshape_bind id e | decl_type p c id aa t k -> reshape_child reshape_bind id e | decl_instance p c aa t -> reshape_child reshape_bind (find_constructor_name t) e | e -> e ] e ] def ast_bind: ast -> ast = [ e -> reshape_bind_search nop e ] )
No comments:
Post a Comment