mirror of https://github.com/svaarala/duktape.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
304 B
18 lines
304 B
/*===
|
|
FOO GET
|
|
BAR GET
|
|
===*/
|
|
|
|
/* A pretty basic test: use Object.defineProperties() to create two
|
|
* getter properties.
|
|
*/
|
|
|
|
var obj={};
|
|
Object.defineProperties(obj, {
|
|
foo: { get: function() { print("FOO GET"); } },
|
|
bar: { get: function() { print("BAR GET"); } }
|
|
});
|
|
|
|
void obj.foo;
|
|
void obj.bar;
|
|
|
|
|