Index: src/runtime.cc |
diff --git a/src/runtime.cc b/src/runtime.cc |
index 24c9655a394d2834dae2ee86fb14e6ed0774c43f..1fbedc6adc3cad719a24976e9929a0e686fca682 100644 |
--- a/src/runtime.cc |
+++ b/src/runtime.cc |
@@ -608,6 +608,17 @@ RUNTIME_FUNCTION(Runtime_CreatePrivateSymbol) { |
} |
+RUNTIME_FUNCTION(Runtime_CreatePrivateOwnSymbol) { |
+ HandleScope scope(isolate); |
+ DCHECK(args.length() == 1); |
+ CONVERT_ARG_HANDLE_CHECKED(Object, name, 0); |
+ RUNTIME_ASSERT(name->IsString() || name->IsUndefined()); |
+ Handle<Symbol> symbol = isolate->factory()->NewPrivateOwnSymbol(); |
+ if (name->IsString()) symbol->set_name(*name); |
+ return *symbol; |
+} |
+ |
+ |
RUNTIME_FUNCTION(Runtime_CreateGlobalPrivateSymbol) { |
HandleScope scope(isolate); |
DCHECK(args.length() == 1); |