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.
 
 
 
 
 
 

20 lines
394 B

=proto
const char *duk_require_string(duk_context *ctx, int index);
=stack
[ ... val! ... ]
=summary
<p>Like <code><a href="#duk_get_string">duk_get_string()</a></code>,
but throws an error if the value at <code>index</code> is not a string
or if the index is invalid.</p>
=example
const char *buf;
buf = duk_require_string(ctx);
printf("value is a string: %s\n", buf);
=tags
stack
string