From the MapEquality documentation, I thought that the combination of key and value must be the same to have a collision, but the value can be swapped and the hash value will still be the same. For example, the following maps have the same hash value.
dart info
```
$ dart info
If providing this information as part of reporting a bug, please review the information
below to ensure it only contains things you're comfortable posting publicly.
#### General info
- Dart 3.2.0 (stable) (Tue Nov 14 18:26:59 2023 +0000) on "macos_arm64"
- on macos / Version 13.4 (Build 22F66)
- locale is ja-JP
#### Process info
| Memory | CPU | Elapsed time | Command line |
| -----: | ---: | -----------: | ------------------------------------------------------------------------------------------ |
| 426 MB | 0.0% | 01-20:23:25 | dart language-server --client-id=Android-Studio --client-version=AI-222.4459.24 --protocol=analyzer |
| 51 MB | 0.0% | 01-20:23:25 | flutter_tools.snapshot daemon
```
It could probably be improved.
It's an unordered hash, so the hashed of the entries are just xor'ed, but it probably should be an unordered hash of better hashed entries.
From the MapEquality documentation, I thought that the combination of key and value must be the same to have a collision, but the value can be swapped and the hash value will still be the same. For example, the following maps have the same hash value.
Is this expected behavior?
dart info
``` $ dart info If providing this information as part of reporting a bug, please review the information below to ensure it only contains things you're comfortable posting publicly. #### General info - Dart 3.2.0 (stable) (Tue Nov 14 18:26:59 2023 +0000) on "macos_arm64" - on macos / Version 13.4 (Build 22F66) - locale is ja-JP #### Process info | Memory | CPU | Elapsed time | Command line | | -----: | ---: | -----------: | ------------------------------------------------------------------------------------------ | | 426 MB | 0.0% | 01-20:23:25 | dart language-server --client-id=Android-Studio --client-version=AI-222.4459.24 --protocol=analyzer | | 51 MB | 0.0% | 01-20:23:25 | flutter_tools.snapshot daemon ```