1
0
mirror of https://github.com/danog/strum.git synced 2024-12-04 02:17:56 +01:00
strum/strum_tests/tests
Andrew Burkett aeaa19ad86
EnumIndex implementation (#185)
* Add EnumConstIndex

* Get working with discriminants

* Remove unused/(unneeded?) features

* Rename to EnumIndex and index(..). Make const_index conditional

* Get repr(..) working

* Fix issue to support rust 1.32

* Switch from VARIANT# to {ENUM}_{VARIANT} for variant constant names

* Expose constants as part of implementation

* Add discriminant error messages. Cargo fmt my code

* Add rustversion to make compilation conditional on 1.46

* Handle expr discriminants

* Fix generics handling

* Make constants always available. No need to only expose them when const_index is defined

* Change to FromDiscriminant. Only output a single function

* Don't make constants accessible

* Make rustversion a dev dependency in strum-tests due to upstream change

* Cleanup doc tests for const

* Rename to FromRepr/from_repr
2021-11-06 09:30:09 -07:00
..
as_ref_no_strum.rs Update strum to Rust edition 2018 (#110) 2020-09-17 11:21:21 -07:00
as_ref_str.rs Update strum to Rust edition 2018 (#110) 2020-09-17 11:21:21 -07:00
display.rs Update strum to Rust edition 2018 (#110) 2020-09-17 11:21:21 -07:00
enum_count.rs Re-export macros (#170) 2021-07-16 20:40:19 -07:00
enum_discriminants.rs Re-export macros (#170) 2021-07-16 20:40:19 -07:00
enum_iter.rs Re-export macros (#170) 2021-07-16 20:40:19 -07:00
enum_message.rs Re-export macros (#170) 2021-07-16 20:40:19 -07:00
enum_props.rs Re-export macros (#170) 2021-07-16 20:40:19 -07:00
enum_variant_names.rs Re-export macros (#170) 2021-07-16 20:40:19 -07:00
from_repr.rs EnumIndex implementation (#185) 2021-11-06 09:30:09 -07:00
from_str.rs Add TryFrom<&str> to EnumString (#186) 2021-10-26 12:16:57 -07:00
serialize_all.rs Update strum to Rust edition 2018 (#110) 2020-09-17 11:21:21 -07:00
to_string.rs Update strum to Rust edition 2018 (#110) 2020-09-17 11:21:21 -07:00