Remove obsolete global SubString method.
R=yangguo@chromium.org Review URL: https://codereview.chromium.org/24545002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16937 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
d0e12549ed
commit
a409a2d651
@ -285,15 +285,6 @@ Handle<Object> LookupSingleCharacterStringFromCode(Isolate* isolate,
|
||||
}
|
||||
|
||||
|
||||
Handle<String> SubString(Handle<String> str,
|
||||
int start,
|
||||
int end,
|
||||
PretenureFlag pretenure) {
|
||||
CALL_HEAP_FUNCTION(str->GetIsolate(),
|
||||
str->SubString(start, end, pretenure), String);
|
||||
}
|
||||
|
||||
|
||||
// Wrappers for scripts are kept alive and cached in weak global
|
||||
// handles referred from foreign objects held by the scripts as long as
|
||||
// they are used. When they are not used anymore, the garbage
|
||||
|
@ -299,11 +299,6 @@ Handle<FixedArray> GetEnumPropertyKeys(Handle<JSObject> object,
|
||||
Handle<FixedArray> UnionOfKeys(Handle<FixedArray> first,
|
||||
Handle<FixedArray> second);
|
||||
|
||||
Handle<String> SubString(Handle<String> str,
|
||||
int start,
|
||||
int end,
|
||||
PretenureFlag pretenure = NOT_TENURED);
|
||||
|
||||
// Sets the expected number of properties for the function's instances.
|
||||
void SetExpectedNofProperties(Handle<JSFunction> func, int nof);
|
||||
|
||||
|
@ -9734,7 +9734,8 @@ bool SharedFunctionInfo::HasSourceCode() {
|
||||
Handle<Object> SharedFunctionInfo::GetSourceCode() {
|
||||
if (!HasSourceCode()) return GetIsolate()->factory()->undefined_value();
|
||||
Handle<String> source(String::cast(Script::cast(script())->source()));
|
||||
return SubString(source, start_position(), end_position());
|
||||
return GetIsolate()->factory()->NewSubString(
|
||||
source, start_position(), end_position());
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user