Skip to content

Editing F* compiler sources

Clément Pit--Claudel edited this page Oct 15, 2017 · 1 revision

Using Emacs

The compiler's sources contain a .dir-locals.el configuration file that sets fstar-mode up for editing the compiler's sources.

You'll need to run make boot before you can step through the compiler's sources with fstar-mode. This is because not all of our files are valid F*: most are written in F* ∩ F#, but some (found in boot/ subfolders) are written in F# and transformed into F* using sed. make boot generates the F* files and stores them in src/boot/ (which is then passed to F* by fstar-mode using --include). You can read more about the structure of src/ if needed.

Using VS

Use the VS 2015 community edition, available here https://www.visualstudio.com/vs/community/

Open an .fs file in the installed editor and it should prompt you to install the F# language support

Once you install that, it will probably restart and then you can open your .fs file again.

It's a good idea to then install the Visual F# PowerTools, which you can do by going to the "Tools", "Extensions and Updates", "Online" and searching there for "Visual F# Power Tools": https://visualstudiogallery.msdn.microsoft.com/136b942e-9f2c-4c0b-8bac-86d774189cff

Thereafter, you should have what you need for editing F# in Visual Studio.

Open src/VS/FStar.sln to start working on the compiler sources.

See also https://github.com/FStarLang/FStar/blob/master/INSTALL.md#on-windows-7810

Clone this wiki locally