Moved everything useful into main_expr