21 #include <wine/port.h> 32 static const WCHAR descriptionW[] = {
'd',
'e',
's',
'c',
'r',
'i',
'p',
't',
'i',
'o',
'n',0};
47 static const WCHAR object_errorW[] = {
'[',
'o',
'b',
'j',
'e',
'c',
't',
' ',
'E',
'r',
'r',
'o',
'r',
']',0};
52 if(!jsthis || ctx->
version < 2) {
87 if(name_len && msg_len) {
94 ptr[name_len+1] =
' ';
170 err = heap_alloc_zero(
sizeof(*
err));
252 case DISPATCH_CONSTRUCT:
330 static const WCHAR ErrorW[] = {
'E',
'r',
'r',
'o',
'r',0};
331 static const WCHAR EvalErrorW[] = {
'E',
'v',
'a',
'l',
'E',
'r',
'r',
'o',
'r',0};
332 static const WCHAR RangeErrorW[] = {
'R',
'a',
'n',
'g',
'e',
'E',
'r',
'r',
'o',
'r',0};
333 static const WCHAR ReferenceErrorW[] = {
'R',
'e',
'f',
'e',
'r',
'e',
'n',
'c',
'e',
'E',
'r',
'r',
'o',
'r',0};
334 static const WCHAR RegExpErrorW[] = {
'R',
'e',
'g',
'E',
'x',
'p',
'E',
'r',
'r',
'o',
'r',0};
335 static const WCHAR SyntaxErrorW[] = {
'S',
'y',
'n',
't',
'a',
'x',
'E',
'r',
'r',
'o',
'r',0};
336 static const WCHAR TypeErrorW[] = {
'T',
'y',
'p',
'e',
'E',
'r',
'r',
'o',
'r',0};
337 static const WCHAR URIErrorW[] = {
'U',
'R',
'I',
'E',
'r',
'r',
'o',
'r',0};
static const WCHAR nameW[]
static jsstr_t * jsstr_alloc(const WCHAR *str)
static const WCHAR RangeErrorW[]
void jsval_release(jsval_t val)
static HRESULT ReferenceErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
#define memmove(s1, s2, n)
jsdisp_t * reference_error_constr
HRESULT throw_range_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
static const WCHAR EvalErrorW[]
static HRESULT RegExpErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
static HRESULT EvalErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
static HRESULT TypeErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
jsdisp_t * type_error_constr
static HRESULT Error_toString(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
static HRESULT create_error(script_ctx_t *ctx, jsdisp_t *constr, UINT number, jsstr_t *msg, jsdisp_t **ret)
#define JS_E_FUNCTION_EXPECTED
static HRESULT SyntaxErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
GLenum GLuint GLenum GLsizei const GLchar * buf
jsdisp_t * range_error_constr
static HRESULT Error_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
GLdouble GLdouble GLdouble r
static HRESULT URIErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
HRESULT jsdisp_define_data_property(jsdisp_t *obj, const WCHAR *name, unsigned flags, jsval_t value)
HRESULT create_builtin_constructor(script_ctx_t *ctx, builtin_invoke_t value_proc, const WCHAR *name, const builtin_info_t *builtin_info, DWORD flags, jsdisp_t *prototype, jsdisp_t **ret)
static const WCHAR messageW[]
static BOOL is_undefined(jsval_t v)
static unsigned jsstr_flush(jsstr_t *str, WCHAR *buf)
static unsigned jsstr_length(jsstr_t *str)
static void jsstr_release(jsstr_t *str)
int WINAPI LoadStringW(_In_opt_ HINSTANCE hInstance, _In_ UINT uID, _Out_writes_to_(cchBufferMax, return+1) LPWSTR lpBuffer, _In_ int cchBufferMax)
HRESULT throw_uri_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
jsdisp_t * syntax_error_constr
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
jsdisp_t * regexp_error_constr
static BOOL is_jscript_error(HRESULT hres)
HRESULT to_number(script_ctx_t *, jsval_t, double *) DECLSPEC_HIDDEN
WINE_DEFAULT_DEBUG_CHANNEL(jscript)
static size_t double number
static HRESULT to_string(VARIANT *src, BSTR *dst)
jsstr_t * jsstr_empty(void)
HRESULT throw_syntax_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
static const WCHAR numberW[]
static const WCHAR ErrorW[]
static HRESULT throw_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str, jsdisp_t *constr)
static jsval_t jsval_string(jsstr_t *str)
HRESULT init_error_constr(script_ctx_t *ctx, jsdisp_t *object_prototype)
static const WCHAR TypeErrorW[]
static jsdisp_t * get_jsdisp(vdisp_t *vdisp)
HINSTANCE jscript_hinstance
static const builtin_info_t ErrorInst_info
_CONST_RETURN wchar_t *__cdecl wcschr(_In_z_ const wchar_t *_Str, wchar_t _Ch)
HRESULT jsdisp_propget_name(jsdisp_t *obj, const WCHAR *name, jsval_t *val)
static const WCHAR SyntaxErrorW[]
static HRESULT RangeErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
static const WCHAR URIErrorW[]
static HRESULT error_constr(script_ctx_t *ctx, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r, jsdisp_t *constr)
static const WCHAR ReferenceErrorW[]
static const builtin_info_t Error_info
static const builtin_prop_t Error_props[]
#define memcpy(s1, s2, n)
static HRESULT ErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, unsigned argc, jsval_t *argv, jsval_t *r)
static const WCHAR toStringW[]
HRESULT throw_reference_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
static void jsdisp_release(jsdisp_t *jsdisp)
HRESULT init_dispex(jsdisp_t *dispex, script_ctx_t *ctx, const builtin_info_t *builtin_info, jsdisp_t *prototype)
static jsval_t jsval_obj(jsdisp_t *obj)
static const WCHAR descriptionW[]
jsstr_t * jsstr_alloc_buf(unsigned len, WCHAR **buf)
HRESULT throw_type_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
jsdisp_t * eval_error_constr
HRESULT init_dispex_from_constr(jsdisp_t *dispex, script_ctx_t *ctx, const builtin_info_t *builtin_info, jsdisp_t *constr)
HRESULT throw_generic_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
jsdisp_t * uri_error_constr
#define PROPF_CONFIGURABLE
HRESULT(* builtin_invoke_t)(script_ctx_t *, vdisp_t *, WORD, unsigned, jsval_t *, jsval_t *)
static const WCHAR RegExpErrorW[]
static jsval_t jsval_number(double n)
HRESULT throw_regexp_error(script_ctx_t *ctx, HRESULT error, const WCHAR *str)
static BOOL heap_free(void *mem)
static HRESULT alloc_error(script_ctx_t *ctx, jsdisp_t *prototype, jsdisp_t *constr, jsdisp_t **ret)
GLuint const GLchar * name