Frontend implementation for a compiler