Permalink
Browse files

deps: cherry-pick 26b145a from upstream V8

Original commit message:

    [api] Deprecate ExternalStringResourceBase::IsCompressible

    R=yangguo@chromium.org

    Bug: v8:8238
    Change-Id: Ia59aefc54c2e9f4fa3348c42fb45e7fadab8ee76
    Reviewed-on: https://chromium-review.googlesource.com/c/1349231
    Reviewed-by: Yang Guo <yangguo@chromium.org>
    Commit-Queue: Andreas Haas <ahaas@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#57788}

Refs:

v8/v8@26b145a

PR-URL: #25148
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information...
sam-github committed Dec 21, 2018
1 parent eaa1544 commit 59fa7f12571f721bfe2f5952bc7fe415abb3ad1c
Showing with 3 additions and 13 deletions.
  1. +1 −1 common.gypi
  2. +2 −12 deps/v8/include/v8.h
@@ -38,7 +38,7 @@

# Reset this number to 0 on major V8 upgrades.
# Increment by one for each non-official patch applied to deps/v8.
'v8_embedder_string': '-node.7',
'v8_embedder_string': '-node.8',

##### V8 defaults for Node.js #####

@@ -2631,8 +2631,7 @@ class V8_EXPORT String : public Name {
public:
virtual ~ExternalStringResourceBase() = default;

V8_DEPRECATE_SOON("Use IsCacheable().",
virtual bool IsCompressible() const) {
V8_DEPRECATED("Use IsCacheable().", virtual bool IsCompressible() const) {
return false;
}

@@ -2641,16 +2640,7 @@ class V8_EXPORT String : public Name {
* ExternalStringResource::data() may be cached, otherwise it is not
* expected to be stable beyond the current top-level task.
*/
virtual bool IsCacheable() const {
#if __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#endif
return !IsCompressible();
#if __clang__
#pragma clang diagnostic pop
#endif
}
virtual bool IsCacheable() const { return true; }

protected:
ExternalStringResourceBase() = default;

0 comments on commit 59fa7f1

Please sign in to comment.