Ignore:
Timestamp:
Dec 10, 2014, 9:31:04 PM (10 years ago)
Author:
[email protected]
Message:

Use std::unique_ptr instead of OwnPtr in JSC - heap, jit, runtime, and parser directories
https://bugs.webkit.org/show_bug.cgi?id=139351

Reviewed by Filip Pizlo.

As a step to use std::unique_ptr<>, this cleans up OwnPtr and PassOwnPtr.

  • bytecode/SamplingTool.h:

(JSC::SamplingTool::SamplingTool):

  • heap/CopiedBlock.h:

(JSC::CopiedBlock::didSurviveGC):
(JSC::CopiedBlock::pin):

  • heap/CopiedBlockInlines.h:

(JSC::CopiedBlock::reportLiveBytes):

  • heap/GCActivityCallback.h:
  • heap/GCThread.cpp:
  • heap/Heap.h:
  • heap/HeapInlines.h:

(JSC::Heap::markListSet):

  • jit/ExecutableAllocator.cpp:
  • jit/JIT.cpp:

(JSC::JIT::privateCompile):

  • jit/JIT.h:
  • jit/JITThunks.cpp:

(JSC::JITThunks::JITThunks):
(JSC::JITThunks::clearHostFunctionStubs):

  • jit/JITThunks.h:
  • parser/Parser.cpp:

(JSC::Parser<LexerType>::Parser):

  • parser/Parser.h:

(JSC::Scope::Scope):
(JSC::Scope::pushLabel):

  • parser/ParserArena.cpp:
  • parser/ParserArena.h:

(JSC::ParserArena::identifierArena):

  • parser/SourceProviderCache.h:
  • runtime/CodeCache.h:
  • runtime/Executable.h:
  • runtime/JSArray.cpp:

(JSC::JSArray::sortVector):

  • runtime/JSGlobalObject.h:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/parser/Parser.h

    r177001 r177130  
    3838#include <wtf/Forward.h>
    3939#include <wtf/Noncopyable.h>
    40 #include <wtf/OwnPtr.h>
    4140#include <wtf/RefPtr.h>
    4241namespace JSC {
     
    130129    {
    131130        if (rhs.m_labels) {
    132             m_labels = adoptPtr(new LabelStack);
     131            m_labels = std::make_unique<LabelStack>();
    133132
    134133            typedef LabelStack::const_iterator iterator;
     
    150149    {
    151150        if (!m_labels)
    152             m_labels = adoptPtr(new LabelStack);
     151            m_labels = std::make_unique<LabelStack>();
    153152        m_labels->append(ScopeLabelInfo(label->impl(), isLoop));
    154153    }
     
    358357
    359358    typedef Vector<ScopeLabelInfo, 2> LabelStack;
    360     OwnPtr<LabelStack> m_labels;
     359    std::unique_ptr<LabelStack> m_labels;
    361360    IdentifierSet m_declaredParameters;
    362361    IdentifierSet m_declaredVariables;
     
    817816    const SourceCode* m_source;
    818817    ParserArena m_parserArena;
    819     OwnPtr<LexerType> m_lexer;
     818    std::unique_ptr<LexerType> m_lexer;
    820819   
    821820    bool m_hasStackOverflow;
Note: See TracChangeset for help on using the changeset viewer.