[gjs] js: Adapt to upcoming JS::Heap API
- From: Philip Chimento <pchimento src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gjs] js: Adapt to upcoming JS::Heap API
- Date: Wed, 18 Jan 2017 02:54:42 +0000 (UTC)
commit 785bd8d1b4eaa6c25438c2b76f49b6cd41c2db4b
Author: Philip Chimento <philip chimento gmail com>
Date: Wed Jan 11 23:41:44 2017 -0800
js: Adapt to upcoming JS::Heap API
These lines as they previously were cause compile errors in SpiderMonkey
38. JS::Heap's operators are defined slightly differently than they
previously were.
https://bugzilla.gnome.org/show_bug.cgi?id=776966
gi/fundamental.cpp | 2 +-
gjs/context.cpp | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gi/fundamental.cpp b/gi/fundamental.cpp
index fd7ea16..3245a18 100644
--- a/gi/fundamental.cpp
+++ b/gi/fundamental.cpp
@@ -381,7 +381,7 @@ fundamental_invoke_constructor(FundamentalInstance *priv,
if (!gjs_object_require_property_value(context, obj, NULL,
constructor_const, &js_constructor) ||
- priv->prototype->constructor_name == JSID_VOID) {
+ priv->prototype->constructor_name.get() == JSID_VOID) {
gjs_throw (context,
"Couldn't find a constructor for type %s.%s",
g_base_info_get_namespace((GIBaseInfo*) priv->prototype->info),
diff --git a/gjs/context.cpp b/gjs/context.cpp
index 1c3b829..e814841 100644
--- a/gjs/context.cpp
+++ b/gjs/context.cpp
@@ -487,7 +487,7 @@ gjs_context_constructed(GObject *object)
if (!JS_DefineFunctions(js_context->context, global, &global_funcs[0]))
g_error("Failed to define properties on the global object");
- js_context->global.set(global);
+ js_context->global = global;
JS_AddExtraGCRootsTracer(js_context->runtime, gjs_context_tracer, js_context);
gjs_define_constructor_proxy_factory(js_context->context);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]