Changed API of compile functions