Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(476)

Side by Side Diff: src/bootstrapper.cc

Issue 1994733003: Rewrite decodeURL as builtin function, remove now unused runtime functions. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Use Utf8::Encode() and ValueOf() Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | src/builtins.h » ('j') | src/builtins.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/bootstrapper.h" 5 #include "src/bootstrapper.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/api-natives.h" 8 #include "src/api-natives.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/extensions/externalize-string-extension.h" 10 #include "src/extensions/externalize-string-extension.h"
(...skipping 2799 matching lines...) Expand 10 before | Expand all | Expand 10 after
2810 // and the String function has been set up. 2810 // and the String function has been set up.
2811 Handle<JSFunction> string_function(native_context()->string_function()); 2811 Handle<JSFunction> string_function(native_context()->string_function());
2812 DCHECK(JSObject::cast( 2812 DCHECK(JSObject::cast(
2813 string_function->initial_map()->prototype())->HasFastProperties()); 2813 string_function->initial_map()->prototype())->HasFastProperties());
2814 native_context()->set_string_function_prototype_map( 2814 native_context()->set_string_function_prototype_map(
2815 HeapObject::cast(string_function->initial_map()->prototype())->map()); 2815 HeapObject::cast(string_function->initial_map()->prototype())->map());
2816 2816
2817 Handle<JSGlobalObject> global_object = 2817 Handle<JSGlobalObject> global_object =
2818 handle(native_context()->global_object()); 2818 handle(native_context()->global_object());
2819 2819
2820 // Install Global.decodeURI.
2821 SimpleInstallFunction(global_object, "decodeURI", Builtins::kGlobalDecodeURI,
2822 1, false);
2823
2824 // Install Global.decodeURIComponent.
2825 SimpleInstallFunction(global_object, "decodeURIComponent",
2826 Builtins::kGlobalDecodeURIComponent, 1, false);
2827
2820 // Install Global.encodeURI. 2828 // Install Global.encodeURI.
2821 SimpleInstallFunction(global_object, "encodeURI", Builtins::kGlobalEncodeURI, 2829 SimpleInstallFunction(global_object, "encodeURI", Builtins::kGlobalEncodeURI,
2822 1, false); 2830 1, false);
2823 2831
2824 // Install Global.encodeURIComponent. 2832 // Install Global.encodeURIComponent.
2825 SimpleInstallFunction(global_object, "encodeURIComponent", 2833 SimpleInstallFunction(global_object, "encodeURIComponent",
2826 Builtins::kGlobalEncodeURIComponent, 1, false); 2834 Builtins::kGlobalEncodeURIComponent, 1, false);
2827 2835
2828 // Install Global.eval. 2836 // Install Global.eval.
2829 { 2837 {
(...skipping 942 matching lines...) Expand 10 before | Expand all | Expand 10 after
3772 } 3780 }
3773 3781
3774 3782
3775 // Called when the top-level V8 mutex is destroyed. 3783 // Called when the top-level V8 mutex is destroyed.
3776 void Bootstrapper::FreeThreadResources() { 3784 void Bootstrapper::FreeThreadResources() {
3777 DCHECK(!IsActive()); 3785 DCHECK(!IsActive());
3778 } 3786 }
3779 3787
3780 } // namespace internal 3788 } // namespace internal
3781 } // namespace v8 3789 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/builtins.h » ('j') | src/builtins.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698