Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions jerry-core/api/jerry-snapshot.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,6 @@ snapshot_get_global_flags (bool has_regex, /**< regex literal is present */

uint32_t flags = 0;

#ifdef JERRY_CPOINTER_32_BIT
flags |= JERRY_SNAPSHOT_FOUR_BYTE_CPOINTER;
#endif /* JERRY_CPOINTER_32_BIT */
#ifndef CONFIG_DISABLE_REGEXP_BUILTIN
flags |= (has_regex ? JERRY_SNAPSHOT_HAS_REGEX_LITERAL : 0);
#endif /* !CONFIG_DISABLE_REGEXP_BUILTIN */
Expand Down
2 changes: 1 addition & 1 deletion jerry-core/api/jerry-snapshot.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ typedef enum
JERRY_SNAPSHOT_HAS_REGEX_LITERAL = (1u << 0), /**< byte code has regex literal */
JERRY_SNAPSHOT_HAS_CLASS_LITERAL = (1u << 1), /**< byte code has class literal */
/* 24 bits are reserved for compile time features */
JERRY_SNAPSHOT_FOUR_BYTE_CPOINTER = (1u << 8) /**< compressed pointers are four byte long */
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it OK to simply drop this enumerator? In other public API headers (e.g., jerryscript-core.h), there are examples to keep deprecated enumerators with original values, with a comment stating that it's "deprecated, an unused placeholder now" (see jerry_init_flag_t).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the clarification. I've modified the patch and added a deprecated marker to this entry.

JERRY_SNAPSHOT_FOUR_BYTE_CPOINTER = (1u << 8) /**< deprecated, an unused placeholder now */
} jerry_snapshot_global_flags_t;

#endif /* !JERRY_SNAPSHOT_H */