Zulip Chat Archive

Stream: lean4

Topic: use standard library in alternative location


Locria Cyber (Feb 15 2023 at 16:42):

I'm developing the Lean standard library (not std4). However, the lean LSP does not recognize changes to the standard library.

Locria Cyber (Feb 15 2023 at 16:43):

Is there a way to let Lean use Lean.xxx source files from another directory?

Mario Carneiro (Feb 16 2023 at 05:30):

I don't know what you mean by "the Lean standard library (not std4)". Is this a project of your own? What kind of LSP changes are you noticing?

Mario Carneiro (Feb 16 2023 at 05:31):

@Locria Cyber

Mario Carneiro (Feb 16 2023 at 05:32):

By Lean.xxx are you talking about the Lean package, i.e. the lean compiler itself? (We usually call that the lean core library for disambiguation)

Mario Carneiro (Feb 16 2023 at 05:33):

You should be able to refer to it via import Lean from any lean file, assuming you are using lake to build the project. It is bundled with the compiler itself so you should always be able to access it even if your project has no dependencies

Locria Cyber (Feb 16 2023 at 05:45):

Mario Carneiro said:

By Lean.xxx are you talking about the Lean package, i.e. the lean compiler itself? (We usually call that the lean core library for disambiguation)

yes

Locria Cyber (Feb 16 2023 at 05:46):

I'm modifying the Lean package. I want the LSP to pick up on the change.

Mario Carneiro (Feb 16 2023 at 05:52):

Several things in lean core dev are weird compared to regular lean projects, this is one of them. The equivalent of "Refresh File Dependencies" in lean core is make


Last updated: Dec 20 2023 at 11:08 UTC