Skip to content

Conversation

florianbecker
Copy link

I'm not done in any case because there are too many issues and questions!

I have done a lot of things:

  • Merge neargy/master
  • Code quality for enclosing brackets
  • Remove std::tuple_size, element
  • Some small issues and code beautifier things
  • Good start for magic_enum::array unit test.

So, as mentioned here:
Neargye#187 (comment)
Please provide me with all your known use cases.

Known Bugs:
Sorting the magic_enum::array will break the integrity - so we need to make the sort unworkable or make the kind useable.
std::get will become ambiguous on msvc2019 if you use the same index and an enum_value in the same scope.

For my current work, there is an error with set.insert and emplace on msvc - others will work.

And for me, I missed some operator or function to return the std::container for comparing in that case.

We need to discuss how useful is set, bitset, and flat_set, because I do not find them helpful yet... but hopefully, with your provided cases or intention.

@florianbecker
Copy link
Author

Okay, I have fixed that std::get issue, so the current status is a working test case for magic_enum::containers::array, and I'll go on with set and others.

Known issues of the array:

  • Array will not persist on std::sort
  • There is no operator similar to std::array

@florianbecker
Copy link
Author

Okay, the bitset test is done. set also, but will not compile on Visual Studio 2019 and 2022, because he cannot create an Iterator to insert. I'll try to fix that but also writing some documentation now. Maybe you have a tip for a solution for that build: https://github.com/florianbecker/magic_enum/actions/runs/3536735226

@schaumb
Copy link
Owner

schaumb commented Nov 25, 2022

So, I think this self code-review comment must be solved.
Neargye#187 (comment)

@florianbecker
Copy link
Author

I have fixed the containers::set issue, but I do not have the time to fix Neargye#187 (comment).

So the status is a working containers::set test.

For containers::flat_set there are more issues for me. Constexpr will tell me something like: This will not end in a constant result. Also, begin and end may have a few issues as well - but here is also the issue with my time. I do not have an idea to fix that, nor how a flat_set is working, so this task is the earliest inspection from me in 2023.

Missing tasks are documentation work now. Maybe I have some time to finish this as well in the next few days.

To bring this merge on its way, I would suggest removing the flat_set - this is not useful for anyone currently, and writing a new issue for this. Please let me know if I should remove this for this merge.

@schaumb
Copy link
Owner

schaumb commented Dec 4, 2022

@florianbecker It can be skipped the flat_set for this PR. You can comment out that parts of the code.
Thanks 🙏

@florianbecker
Copy link
Author

Documentation is done, some basic examples are done, and tests are also done. flat_set is commented out.

It is useable, but I think there is a lot of work to do in near future.

Let me know, what changes have to be made by a full review from you.

@schaumb
Copy link
Owner

schaumb commented Dec 23, 2022

I don't have time to review the code here. I merge this, and we can continue the review in Neargye repo

@schaumb schaumb merged commit 7407bde into schaumb:containers Dec 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants