Files
jerryscript/jerry-core/ecma/base/ecma-errors.h
T
Csaba Repasi 271d9b2463 Outsource magic error messages (#4821)
Modify tools/gen-magic-strings.py to generate error messages.

JerryScript-DCO-1.0-Signed-off-by: Csaba Repasi repasics@inf.u-szeged.hu
2021-11-25 14:06:40 +01:00

40 lines
1.3 KiB
C

/* Copyright JS Foundation and other contributors, http://js.foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ECMA_ERRORS_H
#define ECMA_ERRORS_H
#include "lit-globals.h"
typedef enum
{
ECMA_ERR_EMPTY,
/** @cond doxygen_suppress */
#if JERRY_ERROR_MESSAGES
#define ECMA_ERROR_DEF(id, ascii_zt_string) id,
#else /* !JERRY_ERROR_MESSAGES */
#define ECMA_ERROR_DEF(id, ascii_zt_string) id = ECMA_ERR_EMPTY,
#endif /* JERRY_ERROR_MESSAGES */
#include "ecma-error-messages.inc.h"
#undef ECMA_ERROR_DEF
/** @endcond */
ECMA_IS_VALID_CONSTRUCTOR /* used as return value when checking constructor */
} ecma_error_msg_t;
const lit_utf8_byte_t* ecma_get_error_utf8 (uint32_t id);
lit_utf8_size_t ecma_get_error_size (uint32_t id);
#endif /* !ECMA_ERRORS_H */