Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make more classes hashable and comparable #3363

Merged
merged 4 commits into from
Jul 29, 2024

Conversation

jjerphan
Copy link
Member

This allows using instances of MatchSpec and PackageInfo in mappings such as std::unordered_map.

@jjerphan jjerphan force-pushed the hashable-and-comparable-classes branch 6 times, most recently from 6f49c96 to 702d3fa Compare July 26, 2024 14:03
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
@jjerphan jjerphan force-pushed the hashable-and-comparable-classes branch from 702d3fa to d09b5fb Compare July 26, 2024 14:05
@jjerphan jjerphan marked this pull request as ready for review July 26, 2024 14:06
libmamba/include/mamba/specs/chimera_string_spec.hpp Outdated Show resolved Hide resolved
libmamba/include/mamba/specs/regex_spec.hpp Outdated Show resolved Hide resolved
libmamba/include/mamba/specs/match_spec.hpp Outdated Show resolved Hide resolved
libmamba/include/mamba/specs/package_info.hpp Outdated Show resolved Hide resolved
jjerphan and others added 2 commits July 26, 2024 17:07
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>

Co-authored-by: Klaim <Klaim@users.noreply.github.com>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>

Co-authored-by: Klaim <Klaim@users.noreply.github.com>
@jjerphan jjerphan requested a review from Klaim July 26, 2024 15:21
Copy link
Member

@Klaim Klaim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with some cleanups

libmamba/include/mamba/specs/build_number_spec.hpp Outdated Show resolved Hide resolved
libmamba/include/mamba/specs/match_spec.hpp Show resolved Hide resolved
@JohanMabille JohanMabille added the release::enhancements For enhancements PRs or implementing features label Jul 26, 2024
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>

Co-authored-by: Klaim <Klaim@users.noreply.github.com>
@Klaim Klaim merged commit b09f1d1 into mamba-org:main Jul 29, 2024
32 checks passed
@jjerphan jjerphan deleted the hashable-and-comparable-classes branch July 29, 2024 09:07
@Hind-M
Copy link
Member

Hind-M commented Jul 29, 2024

Can you please add tests in the corresponding files in libmamba/tests/src/specs and libmamba/tests/src/util? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release::enhancements For enhancements PRs or implementing features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants