Split up parse_str.rs file #236
Labels
No labels
breaking
bug
dependencies
good first issue
help wanted
unstable
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-uuid-rs/uuid#236
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
The benchmarks file has grown to not just
parse_strfunction. As with thelib.rs, this is important to be split.Other
#124
@Dylan-DPC You'd pointed me to this issue as a starter Rust project a while ago on IRC. Sorry for the delay but I thought it worthwhile to prepare by taking another tour through the Rust Book. ;-)
I'm having trouble understanding this issue: It does not parse (if you'll excuse the pun) — the English description above, that is. I suspect it should rather read as follows:
Grammar aside, I still don't get what is needed. Can you please clarify or elaborate? What is meant here by split?
Hi @murrayjbrown,
Welcome back!!
I just reread my own issue report and indeed it could worded better.
Currently we have 2 files in benches/ folder, which until recently was one file. The number of various bench tests are growing in this one file. What we want is group of associated tests be moved into their own file, so that parse_str.rs just contains the benchmarks for parsing strings to uuid's.
I hope this clears things up. I am currently on my phone so can't really write an essay here but I will check on this :)
Hi @kinggoesgaming, thanks! That's much clearer. However, it appears to me that all the bench tests in benches/parse_str.rs are related to parsing strings to uuids; it's just that some appear to be valid normal cases, while others are abnormal, both error cases and valid edge cases. So, that's how I propose to split them (normal/abnormal), unless I hear differently.
Ok so just had proper look at the file and I think we can split the file into 3:
valid_parse_str.rsinvalid_parse_str.rsslog_support/parse_str.rsThe last one is in accordance with the
src/folder structure, where dependencies have a separate module to handle, here we just use a file instead.As this will may alter the benchmark results, please paste before/after results here or in a comment of the PR that you do create (for keeping track).
And thanks for picking up on this issue :)
Yes, that's better. Upon closer inspection, some of those I'd surmised as valid cases are, in fact, not such, so this makes more sense.