• Tobias Tebbi's avatar
    [torque] make overload resolution robust concerning branching contexts · 93c13714
    Tobias Tebbi authored
    This changes the behavior of overload resolution to not consider if the
    call happens in a branching context (i.e., with implicit True and False
    labels from a conditional operator or statement).
    That way, it is not possible to get different behavior accidentially
    by using an operator in the wrong context. Instead, there will be a
    compile error because the call happened in a non-branching context, or
    because it is ambiguous without this information.
    
    The test doesn't perfectly fit the issue (impossible until we have
    negative tests), but instead tests that equality on HeapNumber's works
    in boolean contexts, which is something Peter fixed already in
    https://crrev.com/c/1432596.
    
    
    Bug: v8:8737 v8:7793
    Change-Id: I08a3801891587aac705dc93b1c65b0c6cf164107
    Reviewed-on: https://chromium-review.googlesource.com/c/1456093Reviewed-by: 's avatarPeter Wong <peter.wm.wong@gmail.com>
    Reviewed-by: 's avatarDaniel Clifford <danno@chromium.org>
    Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#59625}
    93c13714
Name
Last commit
Last update
benchmarks Loading commit data...
build_overrides Loading commit data...
custom_deps Loading commit data...
docs Loading commit data...
gni Loading commit data...
include Loading commit data...
infra Loading commit data...
samples Loading commit data...
src Loading commit data...
test Loading commit data...
testing Loading commit data...
third_party Loading commit data...
tools Loading commit data...
.clang-format Loading commit data...
.clang-tidy Loading commit data...
.editorconfig Loading commit data...
.git-blame-ignore-revs Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.gn Loading commit data...
.vpython Loading commit data...
.ycm_extra_conf.py Loading commit data...
AUTHORS Loading commit data...
BUILD.gn Loading commit data...
CODE_OF_CONDUCT.md Loading commit data...
ChangeLog Loading commit data...
DEPS Loading commit data...
LICENSE Loading commit data...
LICENSE.fdlibm Loading commit data...
LICENSE.strongtalk Loading commit data...
LICENSE.v8 Loading commit data...
LICENSE.valgrind Loading commit data...
OWNERS Loading commit data...
PRESUBMIT.py Loading commit data...
README.md Loading commit data...
WATCHLISTS Loading commit data...
codereview.settings Loading commit data...
snapshot_toolchain.gni Loading commit data...