Ignore:
Timestamp:
Mar 31, 2010, 1:36:21 PM (15 years ago)
Author:
[email protected]
Message:

Bug 36871 - Remove JSC::CString
Use WTF::CString instead (which until recently was WebCore::CString).

Reviewed by Geoff Garen.

JavaScriptCore:

JavaScriptGlue:

  • ForwardingHeaders/wtf/text: Added.
  • ForwardingHeaders/wtf/text/CString.h: Added.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/runtime/UString.h

    r56560 r56864  
    3434#include <wtf/RefPtr.h>
    3535#include <wtf/Vector.h>
     36#include <wtf/text/CString.h>
    3637#include <wtf/unicode/Unicode.h>
    3738
     
    4041    using WTF::PlacementNewAdoptType;
    4142    using WTF::PlacementNewAdopt;
    42 
    43     class CString {
    44     public:
    45         CString()
    46             : m_length(0)
    47             , m_data(0)
    48         {
    49         }
    50 
    51         CString(const char*);
    52         CString(const char*, size_t);
    53         CString(const CString&);
    54 
    55         ~CString();
    56 
    57         static CString adopt(char*, size_t); // buffer should be allocated with new[].
    58 
    59         CString& append(const CString&);
    60         CString& operator=(const char* c);
    61         CString& operator=(const CString&);
    62         CString& operator+=(const CString& c) { return append(c); }
    63 
    64         size_t length() const { return m_length; }
    65         const char* data() const { return m_data; }
    66 
    67     private:
    68         size_t m_length;
    69         char* m_data;
    70     };
    71 
    72     bool operator==(const CString&, const CString&);
    73 
    74     typedef Vector<char, 32> CStringBuffer;
    7543
    7644    class UString {
Note: See TracChangeset for help on using the changeset viewer.