@Test public void shouldThrow_whenBindIsLastLineInDoNotation() { exception.expectMessage(containsString("Unexpected bind in do-notation")); transform( "module scotch.test", "pingpong = do", " ping <- readln", " println (\"ponging back! \" ++ ping)", " pong <- readln" ); fail(); }
public DefinitionGraph transform(Map<String, List<ModuleContext>> moduleMap) { definition(null, RootDefinition.builder(), builder -> moduleMap.keySet().forEach( moduleName -> builder.withModule(transformModules(moduleName, moduleMap.get(moduleName))))); return createGraph(definitions).build(); }
SyntaxTransformer { public DefinitionGraph transform(Map<String, List<ModuleContext>> moduleMap) { definition(null, RootDefinition.builder(), builder -> moduleMap.keySet().forEach( moduleName -> builder.withModule(transformModules(moduleName, moduleMap.get(moduleName))))); return createGraph(definitions).build(); } }
SyntaxTransformer { public DefinitionGraph transform(Map<String, List<ModuleContext>> moduleMap) { definition(null, RootDefinition.builder(), builder -> moduleMap.keySet().forEach( moduleName -> builder.withModule(transformModules(moduleName, moduleMap.get(moduleName))))); return createGraph(definitions).build(); } SyntaxTransformer(SymbolResolver resolver, SymbolGenerator symbolGenerator); }
SyntaxTransformer { public DefinitionGraph transform(Map<String, List<ModuleContext>> moduleMap) { definition(null, RootDefinition.builder(), builder -> moduleMap.keySet().forEach( moduleName -> builder.withModule(transformModules(moduleName, moduleMap.get(moduleName))))); return createGraph(definitions).build(); } SyntaxTransformer(SymbolResolver resolver, SymbolGenerator symbolGenerator); DefinitionGraph transform(Map<String, List<ModuleContext>> moduleMap); }
SyntaxTransformer { public DefinitionGraph transform(Map<String, List<ModuleContext>> moduleMap) { definition(null, RootDefinition.builder(), builder -> moduleMap.keySet().forEach( moduleName -> builder.withModule(transformModules(moduleName, moduleMap.get(moduleName))))); return createGraph(definitions).build(); } SyntaxTransformer(SymbolResolver resolver, SymbolGenerator symbolGenerator); DefinitionGraph transform(Map<String, List<ModuleContext>> moduleMap);  }