• Sigurd Schneider's avatar
    [cctest] Check compilation result in v8_compile · 88f8d801
    Sigurd Schneider authored
    This CL introduces a CHECK in v8_compile that compilation succeedes.
    Previously, a failed compilation would lead to undefined behavior or
    a crash in CompileRun, because it would call Script::Run on a nullptr.
    This CL introduced v8_try_compile that returns a MaybeLocal and supports
    test-cases that want to ensure that a compilation fails.
    
    Bug: chromium:1014415
    Change-Id: I559190da6049f325e8650e4a29c6e387d8ff7af5
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1943154
    Auto-Submit: Sigurd Schneider <sigurds@chromium.org>
    Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
    Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#65266}
    88f8d801
test-parsing.cc 399 KB