Add API function to check if the specified feature is enabled. (#1465)
JerryScript-DCO-1.0-Signed-off-by: Robert Sipka rsipka.uszeged@partner.samsung.com
This commit is contained in:
@@ -68,6 +68,18 @@ typedef enum
|
||||
JERRY_ERROR_URI /**< URIError */
|
||||
} jerry_error_t;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
JERRY_FEATURE_ERROR_MESSAGES, /**< error messages */
|
||||
JERRY_FEATURE_CPOINTER_32_BIT, /**< 32 bit compressed pointers */
|
||||
JERRY_FEATURE_MEM_STATS, /**< memory statistics */
|
||||
JERRY_FEATURE_PARSER_DUMP, /**< parser byte-code dumps */
|
||||
JERRY_FEATURE_REGEXP_DUMP, /**< regexp byte-code dumps */
|
||||
JERRY_FEATURE_SNAPSHOT_SAVE, /**< saving snapshot files */
|
||||
JERRY_FEATURE_SNAPSHOT_EXEC, /**< executing snapshot files */
|
||||
JERRY_FEATURE__COUNT /**< number of features. NOTE: must be at the end of the list */
|
||||
} jerry_feature_t;
|
||||
|
||||
/**
|
||||
* Jerry's char value
|
||||
*/
|
||||
@@ -191,6 +203,11 @@ bool jerry_value_is_object (const jerry_value_t);
|
||||
bool jerry_value_is_string (const jerry_value_t);
|
||||
bool jerry_value_is_undefined (const jerry_value_t);
|
||||
|
||||
/**
|
||||
* Checker function of whether the specified compile feature is enabled
|
||||
*/
|
||||
bool jerry_is_feature_enabled (const jerry_feature_t);
|
||||
|
||||
/**
|
||||
* Error flag manipulation functions
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user