Changeset 194017 in webkit for trunk/Source/JavaScriptCore/parser/SourceProvider.h
- Timestamp:
- Dec 13, 2015, 12:03:24 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/parser/SourceProvider.h
r191973 r194017 44 44 JS_EXPORT_PRIVATE virtual ~SourceProvider(); 45 45 46 virtual const String& source() const = 0; 47 String getRange(int start, int end) const 46 virtual unsigned hash() const = 0; 47 virtual StringView source() const = 0; 48 StringView getRange(int start, int end) const 48 49 { 49 return source().substring SharingImpl(start, end - start);50 return source().substring(start, end - start); 50 51 } 51 52 … … 87 88 return adoptRef(*new StringSourceProvider(source, url, startPosition)); 88 89 } 90 91 unsigned hash() const override 92 { 93 return m_source.impl()->hash(); 94 } 89 95 90 virtual const String&source() const override96 virtual StringView source() const override 91 97 { 92 98 return m_source; … … 111 117 } 112 118 113 virtual const String& source() const override 119 unsigned hash() const override 120 { 121 return m_source.impl()->hash(); 122 } 123 124 virtual StringView source() const override 114 125 { 115 126 return m_source;
Note:
See TracChangeset
for help on using the changeset viewer.