Formatting adapter cfg(feature = "const_fn")] fns aren't const fn's #309

Closed
opened 2018-09-04 19:08:16 -05:00 by huonw · 1 comment
huonw commented 2018-09-04 19:08:16 -05:00 (Migrated from github.com)

Describe the bug

There's a variety of duplication for #[cfg(feature = "const_fn")] and #[cfg(not(feature = "const_fn"))] in https://github.com/uuid-rs/uuid/blob/master/src/adapter/mod.rs, but none of the former are actually const fns, e.g. github.com/uuid-rs/uuid@c61efa4aac/src/adapter/mod.rs (L83-L85)

To Reproduce
Steps to reproduce the behavior:

  1. Look at https://github.com/uuid-rs/uuid/blob/master/src/adapter/mod.rs
  2. Search for const fn (0 matches) and cfg(feature = "const_fn") (12 matches)

Expected behavior

The #[cfg(feature = "const_fn")] functions to be pub const fn

Specifications:

  • master branch (but also true on breaking)
**Describe the bug** There's a variety of duplication for `#[cfg(feature = "const_fn")]` and `#[cfg(not(feature = "const_fn"))]` in https://github.com/uuid-rs/uuid/blob/master/src/adapter/mod.rs, but none of the former are actually `const fn`s, e.g. https://github.com/uuid-rs/uuid/blob/c61efa4aac132296d968fdd9225f9cba89b8e0ac/src/adapter/mod.rs#L83-L85 **To Reproduce** Steps to reproduce the behavior: 1. Look at https://github.com/uuid-rs/uuid/blob/master/src/adapter/mod.rs 2. Search for `const fn` (0 matches) and `cfg(feature = "const_fn")` (12 matches) **Expected behavior** The `#[cfg(feature = "const_fn")]` functions to be `pub const fn` **Specifications:** - `master` branch (but also true on `breaking`)
kinggoesgaming commented 2018-09-04 20:36:07 -05:00 (Migrated from github.com)

oh boy you caught a failed copy-pasta!! 😳

I will get this fixed today...

Edit: currently breaking branch is no longer active as its changes were merged back into master

oh boy you caught a failed copy-pasta!! :flushed: I will get this fixed today... Edit: currently `breaking` branch is no longer active as its changes were merged back into `master`
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-uuid-rs/uuid#309
No description provided.