First part of parser rewrites