Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add missing precondition check in forward_list::splice_after
`forward_list::splice_after(target_iterator, some_list, before_source_iterator)` requires that `++before_source_iterator` - the iterator that denotes the element to be removed from `some_list` and inserted into `*this` after `target_iterator` - be dereferenceable. We conventionally don't check preconditions when the result of violation is to dereference a `nullptr`, since the behavior is nicely predictable, but doing so here avoids confusion about what otherwise seems like a reasonable call. (See DevDiv-1456054.)
- Loading branch information