diff --git a/build.gradle b/build.gradle index 7885431..bb19da8 100644 --- a/build.gradle +++ b/build.gradle @@ -47,8 +47,10 @@ test { } } -task parseExamples(type: JavaExec, dependsOn: classes) { +// ParseExamples lives in the test source set, so the task needs the test +// runtime classpath (with main.runtimeClasspath the class was never found). +task parseExamples(type: JavaExec, dependsOn: testClasses) { mainClass = 'com.mpl.test.ParseExamples' - classpath = sourceSets.main.runtimeClasspath + classpath = sourceSets.test.runtimeClasspath args = ['examples'] } \ No newline at end of file diff --git a/examples/03_file_processing.mpl b/examples/03_file_processing.mpl index 87fdb4b..890c0c9 100644 --- a/examples/03_file_processing.mpl +++ b/examples/03_file_processing.mpl @@ -4,4 +4,4 @@ processFile β‰œ Ξ»path: { result ← transform(data); writeFile(result, πŸ–«"output.txt"); ⟨"success"|"failed"⟩ -} ↴ {β†―e β‡’ ⟨βŠ₯|e⟩}; \ No newline at end of file +} ↴ {β†―e ⟹ ⟨βŠ₯|e⟩}; \ No newline at end of file diff --git a/examples/05_module_definition.mpl b/examples/05_module_definition.mpl index 8d1063d..d0e2762 100644 --- a/examples/05_module_definition.mpl +++ b/examples/05_module_definition.mpl @@ -1,8 +1,8 @@ -- Module definition example π“œ Mathematics β‡’ { Ο€ β‰œ 3.14159; - sin β‰œ Ξ»xβˆˆβ„: {- implementation -}; - cos β‰œ Ξ»xβˆˆβ„: {- implementation -} + sin β‰œ Ξ»xβˆˆβ„: βŠ₯ {- implementation deferred until MPL executes -}; + cos β‰œ Ξ»xβˆˆβ„: βŠ₯ {- implementation deferred until MPL executes -} }; angle ← Ο€/4;