Add Lean 4 Lang - #2714
Add Lean 4 Lang#2714Bubbler-4 wants to merge 17 commits into
Conversation
Copied and slightly adjusted (viewBox and stroke color) from lean-lang.org source code
Commented out because `codemirror-lean4-lsp` should be added as dependency
- lean/Dockerfile: need to copy some .so files - lean/leanwrapper.c: fix off by one error which chopped off first arg - a-schema.sql: add lean as a possible lang key
- Avoid segfault from strcmp when argv[1] is null - Compile and run in three steps to isolate warnings being printed to stdout, and move compilation warnings to stderr
|
Progress so far:
Questions / Help wanted:
|
|
Note to future self: consider using https://leanprover.zulipchat.com/user_uploads/3121/_bE64eFQJ78Xlwhopqc_IH9A/Lean-stacked.svg as an alternative logo (source: https://leanprover.zulipchat.com/#narrow/channel/113488-general/topic/Square-friendly.20Lean.20logo.3F/near/585982317) |
Implements #2702
Notes:
Lean/usr/local/lean/leanbinary can detect Lean libraries; putting the contents oflib/to/usr/lib/may conflict with existing system librariescode.leanand runslean --run code.leaninclude_strcan include the source code as string. But interestingly, I can't find a way to abuse it to write a quine, aslean --run code.leansomehow rejectsinclude_str "code.lean"or any other variation.Todos:
codemirror-lean4-lspas dependency and uncomment codemirror imports