bool lex_force_int_range (struct lexer *, const char *name,
long min, long max) WARN_UNUSED_RESULT;
bool lex_force_num (struct lexer *) WARN_UNUSED_RESULT;
+bool lex_force_num_range_closed (struct lexer *, const char *name,
+ double min, double max) WARN_UNUSED_RESULT;
+bool lex_force_num_range_halfopen (struct lexer *, const char *name,
+ double min, double max) WARN_UNUSED_RESULT;
+bool lex_force_num_range_open (struct lexer *, const char *name,
+ double min, double max) WARN_UNUSED_RESULT;
bool lex_force_id (struct lexer *) WARN_UNUSED_RESULT;
bool lex_force_string (struct lexer *) WARN_UNUSED_RESULT;
bool lex_force_string_or_id (struct lexer *) WARN_UNUSED_RESULT;
/* Token representation. */
char *lex_next_representation (const struct lexer *, int n0, int n1);
+char *lex_ofs_representation (const struct lexer *, int ofs0, int ofs1);
bool lex_next_is_from_macro (const struct lexer *, int n);
/* Current position. */
void lex_error (struct lexer *, const char *, ...) PRINTF_FORMAT (2, 3);
void lex_next_error (struct lexer *, int n0, int n1, const char *, ...)
PRINTF_FORMAT (4, 5);
+void lex_ofs_error (struct lexer *, int ofs0, int ofs1, const char *, ...)
+ PRINTF_FORMAT (4, 5);
int lex_end_of_command (struct lexer *);
void lex_error_expecting (struct lexer *, ...) SENTINEL(0);
void lex_error_valist (struct lexer *, const char *, va_list)
PRINTF_FORMAT (2, 0);
-void lex_next_error_valist (struct lexer *lexer, int n0, int n1,
- const char *format, va_list)
+void lex_ofs_error_valist (struct lexer *lexer, int ofs0, int ofs1,
+ const char *format, va_list)
PRINTF_FORMAT (4, 0);
/* Error handling. */