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
430 B
18 lines
430 B
name: duk_require_constructor_call
|
|
|
|
proto: |
|
|
void duk_require_constructor_call(duk_context *ctx);
|
|
|
|
summary: |
|
|
<p>Throw an error if current function was called as a normal function
|
|
call (<code>Foo()</code>) rather than a constructor call
|
|
(<code>new Foo()</code>). Also throws if no current call is in
|
|
progress. Otherwise returns.</p>
|
|
|
|
example: |
|
|
duk_require_constructor_call(ctx);
|
|
|
|
tags:
|
|
- stack
|
|
|
|
introduced: 2.4.0
|
|
|