felangel / felangel/equatable

Assertion bug: 'a is! Set && b is! Set': iterableEquals doesn't support Sets

Open
#196 6 comments 2 reactions 2 assignees Claimed by @ShakyaCsun View on GitHub
bug
Dominant language
Dart
Stars
1.1k
Forks
118
PR merge metrics
No merged PRs in 30d

Description

I have a nested object that, when compared, calls `objectsEquals` internally and in turn `iterableEquals`.

In my case, `a` is `Iterable` and `b` is `Set`, so the following code calls `iterableEquals`:

```dart
} else if (a is Set && b is Set) {
return setEquals(a, b);
} else if (a is Iterable && b is Iterable) {
return iterableEquals(a, b);
}
```

However, inside `iterableEquals` I get the assertion error because `'a is! Set && b is! Set'` is `true`.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.