Skip to content

Cleanups following introduction of Pexp_struct_item/Texp_struct_item#14028

Merged
nojb merged 3 commits intoocaml:trunkfrom
nojb:cleanup_let_struct_item
May 13, 2025
Merged

Cleanups following introduction of Pexp_struct_item/Texp_struct_item#14028
nojb merged 3 commits intoocaml:trunkfrom
nojb:cleanup_let_struct_item

Conversation

@nojb
Copy link
Copy Markdown
Contributor

@nojb nojb commented May 12, 2025

Some cleanups related to #13839.

  • Remove some comments which referenced Pexp_letmodule and that no longer make sense (I did not see how to adapt them and still make sense).

  • Remove an "error" constructor Scoping_let_module; this error was not exercised in the testsuite and so I had not noticed that it had become dead code (supposedly the same error now reports a more general "out of scope" error message).

  • Remove tools/eqparsetree.ml: this code is not compiled and seems to be out of date.

Lastly, it was indicated to me offline that the new construct Pexp_struct_item would be better named Pexp_let_struct_item (and same for Texp_struct_item). Since we still have the possibility of doing this kind of renaming, I am putting this up for consideration here. (I could do the renaming in this PR if there is a decision to do so.)

Fixes #13839 (comment)

@nojb nojb force-pushed the cleanup_let_struct_item branch from 916c24b to 30d10f3 Compare May 12, 2025 06:36
@Octachron
Copy link
Copy Markdown
Member

The Scoping_let_module error has been dead code for a long time (from memory, starting with OCaml 4.00). I had left an error in place previously to keep in mind that this is one of the point where scope error should be improved. It is probably still to remove it however, since you removed the comment mentioning it.

Copy link
Copy Markdown
Member

@gasche gasche left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me, we should merge it if the CI passes.

@nojb nojb merged commit a086c20 into ocaml:trunk May 13, 2025
33 checks passed
@nojb
Copy link
Copy Markdown
Contributor Author

nojb commented May 13, 2025

Thanks for the comments/review!

MisterDA pushed a commit to MisterDA/ocaml that referenced this pull request May 16, 2025
…em` (ocaml#14028)

* Remove stale comments

* Remove dead constructor: Scoping_let_module

* Remove eqparsetree.ml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants