summaryrefslogtreecommitdiff
path: root/Base/home
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2020-03-15 15:25:43 +0100
committerAndreas Kling <kling@serenityos.org>2020-03-15 15:25:43 +0100
commit23b1d97b0d757cf6427d86a736b811f13698fd92 (patch)
tree657957789b824175681790db236c8174fd1a5ad3 /Base/home
parentf1f14945cffd70a177e852ac7d9d97adfd813350 (diff)
downloadserenity-23b1d97b0d757cf6427d86a736b811f13698fd92.zip
LibJS: Add ObjectPrototype and implement hasOwnProperty()
All Objects will now have ObjectPrototype as their prototype, unless overridden.
Diffstat (limited to 'Base/home')
-rw-r--r--Base/home/anon/js/hasOwnProperty.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/Base/home/anon/js/hasOwnProperty.js b/Base/home/anon/js/hasOwnProperty.js
new file mode 100644
index 0000000000..26456344ab
--- /dev/null
+++ b/Base/home/anon/js/hasOwnProperty.js
@@ -0,0 +1,2 @@
+var x = "foobar";
+print(x.hasOwnProperty("length"));