Skip to content

Instantly share code, notes, and snippets.

@Whateverable
Created January 4, 2023 21:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Whateverable/2f2ea2b7b2f2a976ee8934dc6a205ec8 to your computer and use it in GitHub Desktop.
Save Whateverable/2f2ea2b7b2f2a976ee8934dc6a205ec8 to your computer and use it in GitHub Desktop.
bisectable6
multi foo(Int:D $n) { say "my int is $n"; }; multi foo(Str(Any:D) $s) { say "i obtained str $s"; }; foo 5
Bisecting: 145 revisions left to test after this (roughly 7 steps)
[014f1712c66f2bf29b89246065eb344aea87c336] Make |(1,2,3) xx 42 about 3x faster
»»»»» Testing 014f1712c66f2bf29b89246065eb344aea87c336
»»»»» Script output:
Ambiguous call to 'foo(Int)'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» Script exit code: 1
»»»»» Bisecting by output
»»»»» Output on “old” revision is:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» The output is different
»»»»» Therefore, marking this revision as “new”
»»»»» -------------------------------------------------------------------------
»»»»» Testing e543c890ad58d4c707f734035532090e418a379a
»»»»» Script output:
Ambiguous call to 'foo(Int)'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» Script exit code: 1
»»»»» Bisecting by output
»»»»» Output on “old” revision is:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» The output is different
»»»»» Therefore, marking this revision as “new”
»»»»» -------------------------------------------------------------------------
»»»»» Testing d9ce5e9b82fe1199fa669f0026d835688b1a9682
»»»»» Script output:
Ambiguous call to 'foo(Int)'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» Script exit code: 1
»»»»» Bisecting by output
»»»»» Output on “old” revision is:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» The output is different
»»»»» Therefore, marking this revision as “new”
»»»»» -------------------------------------------------------------------------
»»»»» Testing d4f53ed5d99d76b263fb0f2417989960a60151df
»»»»» Script output:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» Script exit code: 1
»»»»» Bisecting by output
»»»»» Output on “old” revision is:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» The output is identical
»»»»» Therefore, marking this revision as “old”
»»»»» -------------------------------------------------------------------------
»»»»» Testing 548dcf46561ec1975dfbe573987af6627f962255
»»»»» Script output:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» Script exit code: 1
»»»»» Bisecting by output
»»»»» Output on “old” revision is:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» The output is identical
»»»»» Therefore, marking this revision as “old”
»»»»» -------------------------------------------------------------------------
»»»»» Testing 9606aea22a341e7718b47a9270e479e6857b4335
»»»»» Script output:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» Script exit code: 1
»»»»» Bisecting by output
»»»»» Output on “old” revision is:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» The output is identical
»»»»» Therefore, marking this revision as “old”
»»»»» -------------------------------------------------------------------------
»»»»» Testing 98be6ab5ec8a12566a31c77ff1b313f26b6b76b6
»»»»» Script output:
Ambiguous call to 'foo(Int)'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» Script exit code: 1
»»»»» Bisecting by output
»»»»» Output on “old” revision is:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» The output is different
»»»»» Therefore, marking this revision as “new”
»»»»» -------------------------------------------------------------------------
»»»»» Testing 6d65cf4ff9e941e2c644945dd1be32cd47249a05
»»»»» Script output:
Ambiguous call to 'foo(Int)'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» Script exit code: 1
»»»»» Bisecting by output
»»»»» Output on “old” revision is:
Ambiguous call to 'foo'; these signatures all match:
:(Int:D $n)
:(Any:D $s)
in block <unit> at /tmp/TAR7OuEU3X line 1
»»»»» The output is different
»»»»» Therefore, marking this revision as “new”
6d65cf4ff9e941e2c644945dd1be32cd47249a05 is the first new commit
commit 6d65cf4ff9e941e2c644945dd1be32cd47249a05
Author: Daniel Green <ddgreen@gmail.com>
Date: Tue Dec 19 00:46:26 2017 -0500
Add argument to ambiguous call exception message
We already had the capture of the call's argument(s) in the exception,
just add it to the message to help debugging.
src/core/Exception.pm | 37 +++++++++++++++++++++++++++++++++++--
t/05-messages/02-errors.t | 7 ++++++-
2 files changed, 41 insertions(+), 3 deletions(-)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment