Skip to content

Commit

Permalink
deprecate UnmodifiableMapMixin.first and UnmodifiableMapMixin.last
Browse files Browse the repository at this point in the history
  • Loading branch information
devoncarew committed Dec 20, 2024
1 parent b124216 commit c2d5289
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pkgs/collection/lib/src/unmodifiable_wrappers.dart
Original file line number Diff line number Diff line change
Expand Up @@ -193,4 +193,12 @@ abstract mixin class UnmodifiableMapMixin<K, V> implements Map<K, V> {
/// operations that change the map are disallowed.
@override
void clear() => _throw();

/// Throws an [UnsupportedError].
@Deprecated('This will be removed at a later date.')
set first(dynamic _) => _throw();

/// Throws an [UnsupportedError].
@Deprecated('This will be removed at a later date.')
set last(dynamic _) => _throw();
}

0 comments on commit c2d5289

Please sign in to comment.