Fix generateExpressions