Remove compact profile.

The standard doesn't defines ECMAScript Compact Profile as a subset of Ecma-262 Edition 5.1.
Profile modes can be added easily like the minimal profile if required.

JerryScript-DCO-1.0-Signed-off-by: Robert Sipka rsipka.uszeged@partner.samsung.com
This commit is contained in:
Robert Sipka
2016-08-02 14:11:47 +02:00
parent 79bc5d0220
commit f15e7beadc
72 changed files with 237 additions and 435 deletions
+3 -3
View File
@@ -1649,7 +1649,7 @@ void
lexer_construct_regexp_object (parser_context_t *context_p, /**< context */
int parse_only) /**< parse only */
{
#ifndef CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN
#ifndef CONFIG_DISABLE_REGEXP_BUILTIN
const uint8_t *source_p = context_p->source_p;
const uint8_t *regex_start_p = context_p->source_p;
const uint8_t *regex_end_p = regex_start_p;
@@ -1835,10 +1835,10 @@ lexer_construct_regexp_object (parser_context_t *context_p, /**< context */
context_p->lit_object.literal_p = literal_p;
context_p->lit_object.index = (uint16_t) (context_p->literal_count - 1);
context_p->lit_object.type = LEXER_LITERAL_OBJECT_ANY;
#else /* CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN */
#else /* CONFIG_DISABLE_REGEXP_BUILTIN */
(void) parse_only;
parser_raise_error (context_p, PARSER_ERR_UNSUPPORTED_REGEXP);
#endif /* !CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN */
#endif /* !CONFIG_DISABLE_REGEXP_BUILTIN */
} /* lexer_construct_regexp_object */
/**
+1 -1
View File
@@ -718,7 +718,7 @@ parser_error_to_string (parser_error_t error) /**< error code */
}
case PARSER_ERR_UNSUPPORTED_REGEXP:
{
return "Regexp is not supported in compact profile.";
return "Regexp is not supported in the selected profile.";
}
case PARSER_ERR_IDENTIFIER_TOO_LONG:
{
+1 -1
View File
@@ -56,7 +56,7 @@ typedef enum
PARSER_ERR_INVALID_REGEXP, /**< invalid regular expression */
PARSER_ERR_UNKNOWN_REGEXP_FLAG, /**< unknown regexp flag */
PARSER_ERR_DUPLICATED_REGEXP_FLAG, /**< duplicated regexp flag */
PARSER_ERR_UNSUPPORTED_REGEXP, /**< regular expression is not supported in compact profile */
PARSER_ERR_UNSUPPORTED_REGEXP, /**< regular expression is not supported */
PARSER_ERR_IDENTIFIER_TOO_LONG, /**< too long identifier */
PARSER_ERR_STRING_TOO_LONG, /**< too long string literal */
+2 -2
View File
@@ -17,7 +17,7 @@
#include "ecma-globals.h"
#include "re-bytecode.h"
#ifndef CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN
#ifndef CONFIG_DISABLE_REGEXP_BUILTIN
/** \addtogroup parser Parser
* @{
@@ -442,4 +442,4 @@ re_dump_bytecode (re_bytecode_ctx_t *bc_ctx_p) /**< RegExp bytecode context */
* @}
*/
#endif /* !CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN */
#endif /* !CONFIG_DISABLE_REGEXP_BUILTIN */
+2 -2
View File
@@ -17,7 +17,7 @@
#ifndef RE_BYTECODE_H
#define RE_BYTECODE_H
#ifndef CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN
#ifndef CONFIG_DISABLE_REGEXP_BUILTIN
#include "ecma-globals.h"
@@ -125,5 +125,5 @@ void re_dump_bytecode (re_bytecode_ctx_t *bc_ctx);
* @}
*/
#endif /* !CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN */
#endif /* !CONFIG_DISABLE_REGEXP_BUILTIN */
#endif /* !RE_BYTECODE_H */
+2 -2
View File
@@ -25,7 +25,7 @@
#include "re-compiler.h"
#include "re-parser.h"
#ifndef CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN
#ifndef CONFIG_DISABLE_REGEXP_BUILTIN
/** \addtogroup parser Parser
* @{
@@ -643,4 +643,4 @@ re_compile_bytecode (const re_compiled_code_t **out_bytecode_p, /**< [out] point
* @}
*/
#endif /* !CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN */
#endif /* !CONFIG_DISABLE_REGEXP_BUILTIN */
+2 -2
View File
@@ -17,7 +17,7 @@
#ifndef RE_COMPILER_H
#define RE_COMPILER_H
#ifndef CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN
#ifndef CONFIG_DISABLE_REGEXP_BUILTIN
#include "ecma-globals.h"
#include "re-bytecode.h"
@@ -58,5 +58,5 @@ void re_cache_gc_run ();
* @}
*/
#endif /* !CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN */
#endif /* !CONFIG_DISABLE_REGEXP_BUILTIN */
#endif /* !RE_COMPILER_H */
+2 -2
View File
@@ -22,7 +22,7 @@
#include "re-compiler.h"
#include "re-parser.h"
#ifndef CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN
#ifndef CONFIG_DISABLE_REGEXP_BUILTIN
/** \addtogroup parser Parser
* @{
@@ -917,4 +917,4 @@ re_parse_next_token (re_parser_ctx_t *parser_ctx_p, /**< RegExp parser context *
* @}
*/
#endif /* !CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN */
#endif /* !CONFIG_DISABLE_REGEXP_BUILTIN */
+2 -2
View File
@@ -17,7 +17,7 @@
#ifndef RE_PARSER_H
#define RE_PARSER_H
#ifndef CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN
#ifndef CONFIG_DISABLE_REGEXP_BUILTIN
/** \addtogroup parser Parser
* @{
@@ -113,5 +113,5 @@ re_parse_next_token (re_parser_ctx_t *, re_token_t *);
* @}
*/
#endif /* !CONFIG_ECMA_COMPACT_PROFILE_DISABLE_REGEXP_BUILTIN */
#endif /* !CONFIG_DISABLE_REGEXP_BUILTIN */
#endif /* !RE_PARSER_H */