Merged
Conversation
Alizter
approved these changes
Oct 25, 2022
Collaborator
Alizter
left a comment
There was a problem hiding this comment.
Do you know where we use this mostly?
Collaborator
Author
|
Looks like it's mostly used to remove file extensions from filenames. |
Member
|
Could you add a unit test in stdune/string_tests.ml? I'm convinced the change is correct, but we should make sure there are no regressions as well. |
0a97082 to
ca51ba6
Compare
Previously if the suffix was the entire string, drop_suffix would return the original string. This changes its behaviour to return the empty string instead in this case. Signed-off-by: Stephen Sherratt <stephen@sherra.tt>
ca51ba6 to
e8f3a88
Compare
Collaborator
Author
Added! |
Alizter
approved these changes
Oct 26, 2022
Closed
jchavarri
added a commit
to jchavarri/dune
that referenced
this pull request
Oct 27, 2022
* main: makefile: bind on 0.0.0.0 for livedoc (ocaml#6336) ci: rewrite fmt job (ocaml#6334) refactor(ci): cleanup names (ocaml#6335) fix: create fake socket rpc file on windows (ocaml#6329) refactor(doc): improvements to hacking.rst (ocaml#6324) ci: Add documentation job (ocaml#6333) Fix bug in drop_suffix (ocaml#6321) fix: public binaries with absolute build path test: public binaries in a cram test chore: update dune-project to 3.5 (ocaml#6328) chore(nix): add `devShells.slim` (ocaml#6327) test: remove obsolete bisect tests (ocaml#6318) refactor: clarify matching for path comparison and add a docstring (ocaml#6322)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previously if the suffix was the entire string, drop_suffix would return the original string. This changes its behaviour to return the empty string instead in this case.
Signed-off-by: Stephen Sherratt stephen@sherra.tt