cs3110 / textbook

The CS 3110 Textbook, "OCaml Programming: Correct + Efficient + Beautiful"
Other
720 stars 132 forks source link

Issue on page /chapters/interp/substitution.html #96

Closed Luv2C0d3 closed 2 years ago

Luv2C0d3 commented 2 years ago

I love this entire chapter. The only thing is that as a NOOB I find it hard to follow because for example having a subst stub, creates warnings, which in turn prevents dune from completing the build. I found somewhere that you can disable warnings and that does the trick to be able to follow with you the videos and being able to open utop via make utop.

A possible fix would be to add to the Makefile some note that in the build target, the call to dune build should be changed temporarily to dune build --profile release, which allows the build to succeed with warnings, and enables step by step follow along.

Luv2C0d3 commented 2 years ago

BTW, I went back to the beginning of the chapter and put together a small document, starting from dune init project, that allowed me to follow you step by step. I did put at some point the ugly --profile release which allowed me to follow even when the subst stub was generating warnings, thus failing the build. I removed the build hack as soon as the subst function was completed.

clarksmr commented 2 years ago

Hm, do you mean this version of subst that raises an exception?https://github.com/cs3110/textbook/blame/main/src/chapters/interp/substitution.md#L326

I'm not understanding what the warnings are that prevent you from building. Could you clarify? Thanks!

clarksmr commented 2 years ago

Ah nvm I see in #93 what you mean. Closing this issue as a duplicate.