mpl/examples/05_module_definition.mpl
developtheweb acb98ae145 Fix examples so all ten parse
- 03: handler clause uses the canonical arrow (↯e ⟹ …, was ↯e ⇒ …)
- 05: give sin/cos a real placeholder body (⊥) — a comment-only body is
  empty and cannot parse
- Run parseExamples on the test runtime classpath; ParseExamples lives in
  the test source set and was never found on main.runtimeClasspath

./gradlew parseExamples now reports 10/10 PASS
2026-07-09 02:54:10 -04:00

9 lines
No EOL
281 B
Text
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

-- Module definition example
𝓜 Mathematics ⇒ {
π ≜ 3.14159;
sin ≜ λx∈: ⊥ {- implementation deferred until MPL executes -};
cos ≜ λx∈: ⊥ {- implementation deferred until MPL executes -}
};
angle ← π/4;
result ← Mathematics‧sin(angle);