Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
A new function is added:
val chop_suffix_opt: suffix:string -> string -> string option (** [chop_suffix_opt ~suffix filename] removes the suffix from the [filename] if possible, or returns [None] if the filename does not end with the suffix.
The goal is to deprecate
Following the "modern" style in the stdlib, the new function returns an option instead of raising an exception in case of mismatch. This could avoid bugs such as MPR#1858.
The function uses a labelled argument to avoid the possible confusion between the two arguments.
This PR does not rewrite the uses of chop_suffix in the core distribution to use the new function. This can be done as a follow-up PR.
Also, this PR does not mark
referenced this pull request
Oct 29, 2018
nojb left a comment
I wonder if we should document in the doc for
Also, don't forget to update Changes with GPR number.
Windows supports case-sensitive and case-insensitive directories: https://blogs.msdn.microsoft.com/commandline/2018/02/28/per-directory-case-sensitivity-and-wsl/