• Clemens Backes's avatar
    [base] Fix {StaticCharVector} and add {StaticOneByteVector} · e04eb281
    Clemens Backes authored
    {StaticCharVector}, according to its name, should return a
    {Vector<const char>}. For getting a {Vector<const uint8_t>}, the method
    should be called {StaticOneByteVector}, analog to the
    {OneByteVector} methods that already exist.
    
    Also, {StaticCharVector} is constexpr, but {StaticOneByteVector} cannot
    be, since it contains a {reinterpret_cast}. The same holds for
    {Vector::cast} in general.
    
    This CL
    - changes the return type of {StaticCharVector} to be
      {Vector<const char>},
    - introduces a new {StaticOneByteVector} which returns
      {Vector<const uint8_t>},
    - fixes constexpr annotations at various methods returning {Vector}s,
    - refactors users of {StaticCharVector} to either use
      {StaticOneByteVector} instead, or work on {char} if that makes more
      sense.
    
    R=leszeks@chromium.org
    
    Bug: v8:10426
    Change-Id: I71e336097e41ad30f982aa6344ca3d67b3a01fe3
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2154196
    Commit-Queue: Clemens Backes <clemensb@chromium.org>
    Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#67213}
    e04eb281
Name
Last commit
Last update
..
OWNERS Loading commit data...
char-predicates-inl.h Loading commit data...
char-predicates.cc Loading commit data...
char-predicates.h Loading commit data...
string-builder-inl.h Loading commit data...
string-builder.cc Loading commit data...
string-case.cc Loading commit data...
string-case.h Loading commit data...
string-hasher-inl.h Loading commit data...
string-hasher.h Loading commit data...
string-search.h Loading commit data...
string-stream.cc Loading commit data...
string-stream.h Loading commit data...
unicode-decoder.cc Loading commit data...
unicode-decoder.h Loading commit data...
unicode-inl.h Loading commit data...
unicode.cc Loading commit data...
unicode.h Loading commit data...
uri.cc Loading commit data...
uri.h Loading commit data...