[gjs/wip/ptomato/mozjs45prep: 34/36] js: Update obsolete comments
- From: Philip Chimento <pchimento src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gjs/wip/ptomato/mozjs45prep: 34/36] js: Update obsolete comments
- Date: Sun, 16 Apr 2017 20:53:18 +0000 (UTC)
commit 9079267fe340f351d6be5c31f21b0fc0279e35d1
Author: Philip Chimento <philip chimento gmail com>
Date: Sun Apr 16 13:19:49 2017 -0700
js: Update obsolete comments
These comments were previously correct, but have become incorrect in
SpiderMonkey 45.
gi/boxed.cpp | 2 +-
gi/function.cpp | 2 +-
gi/fundamental.cpp | 2 +-
gi/gerror.cpp | 2 +-
gi/interface.cpp | 2 +-
gi/ns.cpp | 2 +-
gi/object.cpp | 2 +-
gi/param.cpp | 2 +-
gi/repo.cpp | 2 +-
gi/union.cpp | 2 +-
gjs/byteArray.cpp | 2 +-
gjs/coverage.cpp | 2 +-
gjs/importer.cpp | 2 +-
gjs/jsapi-class.h | 2 +-
gjs/jsapi-dynamic-class.cpp | 7 ++-----
gjs/jsapi-util.cpp | 2 +-
test/gjs-test-rooting.cpp | 2 +-
17 files changed, 18 insertions(+), 21 deletions(-)
---
diff --git a/gi/boxed.cpp b/gi/boxed.cpp
index e5dbb79..1a32b0f 100644
--- a/gi/boxed.cpp
+++ b/gi/boxed.cpp
@@ -940,7 +940,7 @@ struct JSClass gjs_boxed_class = {
NULL, /* setProperty */
NULL, /* enumerate */
boxed_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
boxed_finalize,
NULL, /* call */
NULL, /* hasInstance */
diff --git a/gi/function.cpp b/gi/function.cpp
index a1239f1..29776c2 100644
--- a/gi/function.cpp
+++ b/gi/function.cpp
@@ -1493,7 +1493,7 @@ struct JSClass gjs_function_class = {
NULL, /* setProperty */
NULL, /* enumerate */
NULL, /* resolve */
- NULL, /* convert */
+ nullptr, /* mayResolve */
function_finalize,
function_call
};
diff --git a/gi/fundamental.cpp b/gi/fundamental.cpp
index a58b8cd..a12f42c 100644
--- a/gi/fundamental.cpp
+++ b/gi/fundamental.cpp
@@ -564,7 +564,7 @@ struct JSClass gjs_fundamental_instance_class = {
NULL, /* setProperty */
NULL, /* enumerate */
fundamental_instance_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
fundamental_finalize,
NULL, /* call */
NULL, /* hasInstance */
diff --git a/gi/gerror.cpp b/gi/gerror.cpp
index 9b45054..3433898 100644
--- a/gi/gerror.cpp
+++ b/gi/gerror.cpp
@@ -279,7 +279,7 @@ struct JSClass gjs_error_class = {
NULL, /* setProperty */
NULL, /* enumerate */
NULL, /* resolve */
- NULL, /* convert */
+ nullptr, /* mayResolve */
error_finalize
};
diff --git a/gi/interface.cpp b/gi/interface.cpp
index be670c6..d63240f 100644
--- a/gi/interface.cpp
+++ b/gi/interface.cpp
@@ -172,7 +172,7 @@ struct JSClass gjs_interface_class = {
NULL, /* setProperty */
NULL, /* enumerate */
interface_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
interface_finalize
};
diff --git a/gi/ns.cpp b/gi/ns.cpp
index 19c6e22..21e2146 100644
--- a/gi/ns.cpp
+++ b/gi/ns.cpp
@@ -165,7 +165,7 @@ struct JSClass gjs_ns_class = {
NULL, /* setProperty */
NULL, /* enumerate */
ns_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
ns_finalize
};
diff --git a/gi/object.cpp b/gi/object.cpp
index a8c4621..a73fea2 100644
--- a/gi/object.cpp
+++ b/gi/object.cpp
@@ -1812,7 +1812,7 @@ struct JSClass gjs_object_instance_class = {
object_instance_set_prop,
NULL, /* enumerate */
object_instance_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
object_instance_finalize,
NULL,
NULL,
diff --git a/gi/param.cpp b/gi/param.cpp
index 3c67700..2c514de 100644
--- a/gi/param.cpp
+++ b/gi/param.cpp
@@ -154,7 +154,7 @@ struct JSClass gjs_param_class = {
NULL, /* setProperty */
NULL, /* enumerate */
param_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
param_finalize
};
diff --git a/gi/repo.cpp b/gi/repo.cpp
index e831b7b..35d370c 100644
--- a/gi/repo.cpp
+++ b/gi/repo.cpp
@@ -234,7 +234,7 @@ struct JSClass gjs_repo_class = {
NULL, /* setProperty */
NULL, /* enumerate */
repo_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
repo_finalize
};
diff --git a/gi/union.cpp b/gi/union.cpp
index 8139ba6..4a17672 100644
--- a/gi/union.cpp
+++ b/gi/union.cpp
@@ -301,7 +301,7 @@ struct JSClass gjs_union_class = {
NULL, /* setProperty */
NULL, /* enumerate */
union_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
union_finalize
};
diff --git a/gjs/byteArray.cpp b/gjs/byteArray.cpp
index 6b4230d..499657b 100644
--- a/gjs/byteArray.cpp
+++ b/gjs/byteArray.cpp
@@ -65,7 +65,7 @@ struct JSClass gjs_byte_array_class = {
byte_array_set_prop,
NULL, /* enumerate */
NULL, /* resolve */
- NULL, /* convert */
+ nullptr, /* mayResolve */
byte_array_finalize
};
diff --git a/gjs/coverage.cpp b/gjs/coverage.cpp
index adc48e7..f59f1fb 100644
--- a/gjs/coverage.cpp
+++ b/gjs/coverage.cpp
@@ -1269,7 +1269,7 @@ static JSClass coverage_global_class = {
NULL, /* setProperty */
NULL, /* enumerate */
NULL, /* resolve */
- NULL, /* convert */
+ nullptr, /* mayResolve */
NULL, /* finalize */
NULL, /* call */
NULL, /* hasInstance */
diff --git a/gjs/importer.cpp b/gjs/importer.cpp
index dbcfd3d..0ec125d 100644
--- a/gjs/importer.cpp
+++ b/gjs/importer.cpp
@@ -869,7 +869,7 @@ const js::Class gjs_importer_real_class = {
NULL, /* setProperty */
NULL, /* enumerate (see below) */
importer_resolve,
- NULL, /* convert */
+ nullptr, /* mayResolve */
importer_finalize,
NULL, /* call */
NULL, /* hasInstance */
diff --git a/gjs/jsapi-class.h b/gjs/jsapi-class.h
index f5e3ff7..72aa73f 100644
--- a/gjs/jsapi-class.h
+++ b/gjs/jsapi-class.h
@@ -179,7 +179,7 @@ static struct JSClass gjs_##cname##_class = { \
nullptr, /* setProperty */ \
nullptr, /* enumerate */ \
nullptr, /* resolve */ \
- nullptr, /* convert */ \
+ nullptr, /* mayResolve */ \
gjs_##cname##_finalize \
}; \
_GJS_DEFINE_GET_PROTO(cname) \
diff --git a/gjs/jsapi-dynamic-class.cpp b/gjs/jsapi-dynamic-class.cpp
index 79b3f8e..cdaf048 100644
--- a/gjs/jsapi-dynamic-class.cpp
+++ b/gjs/jsapi-dynamic-class.cpp
@@ -79,11 +79,8 @@ gjs_init_class_dynamic(JSContext *context,
if (parent_proto) {
prototype.set(JS_NewObjectWithGivenProto(context, clasp, parent_proto));
} else {
- /* JS_NewObject will try to search for clasp prototype in the
- * global object, which is wrong, but it's not a problem because
- * it will fallback to Object.prototype if the clasp's
- * constructor is not found (and it won't be found, because we
- * never call JS_InitClass).
+ /* JS_NewObject will use Object.prototype as the prototype if the
+ * clasp's constructor is not a built-in class.
*/
prototype.set(JS_NewObject(context, clasp));
}
diff --git a/gjs/jsapi-util.cpp b/gjs/jsapi-util.cpp
index 902c282..19d03bd 100644
--- a/gjs/jsapi-util.cpp
+++ b/gjs/jsapi-util.cpp
@@ -54,7 +54,7 @@ static JSClass global_class = {
NULL, /* setProperty */
NULL, /* enumerate */
NULL, /* resolve */
- NULL, /* convert */
+ nullptr, /* mayResolve */
NULL, /* finalize */
NULL, /* call */
NULL, /* hasInstance */
diff --git a/test/gjs-test-rooting.cpp b/test/gjs-test-rooting.cpp
index 240455f..99bb0bc 100644
--- a/test/gjs-test-rooting.cpp
+++ b/test/gjs-test-rooting.cpp
@@ -33,7 +33,7 @@ static JSClass test_obj_class = {
NULL, /* setProperty */
NULL, /* enumerate */
NULL, /* resolve */
- NULL, /* convert */
+ nullptr, /* mayResolve */
test_obj_finalize
};
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]