Skip to content

Commit

Permalink
make Hash.delete($one_item) return that item (and not a list of items)
Browse files Browse the repository at this point in the history
Fixes RT #68482. Inspired by patrickas++
Also adds three more test files (of which two are unrelated)
  • Loading branch information
moritz committed May 25, 2010
1 parent 52a1375 commit baebe1f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/Hash.pm
Expand Up @@ -67,7 +67,7 @@ role Hash is EnumMap {
delete $P1[$P0]
}
}
@deleted
return |@deleted
}
method push(*@values) {
Expand Down
3 changes: 3 additions & 0 deletions t/spectest.data
Expand Up @@ -30,13 +30,15 @@ integration/advent2009-day04.t
integration/advent2009-day05.t
integration/advent2009-day06.t
integration/advent2009-day07.t
integration/advent2009-day08.t
integration/advent2009-day09.t
integration/advent2009-day11.t
integration/advent2009-day14.t
integration/advent2009-day15.t
integration/advent2009-day16.t
integration/advent2009-day17.t
integration/advent2009-day19.t
integration/advent2009-day20.t
integration/advent2009-day22.t
integration/advent2009-day23.t
integration/code-blocks-as-sub-args.t
Expand Down Expand Up @@ -490,6 +492,7 @@ S32-array/splice.t
S32-array/unshift.t
# S32-container/zip.t
S32-hash/exists.t
S32-hash/delete.t
S32-hash/invert.t
S32-hash/keys_values.t
S32-hash/pairs.t
Expand Down

0 comments on commit baebe1f

Please sign in to comment.