Mercurial > hg > octave-nkf
view libinterp/mkdocs @ 16229:7b7b1e4968e8
use functions instead of token return macros in lexer
* lex.h, lex.ll (DISPLAY_TOK_AND_RETURN, COUNT_TOK_AND_RETURN,
TOK_RETURN, TOK_PUSH_AND_RETURN, BIN_OP_RETURN_INTERNAL,
XBIN_OP_RETURN_INTERNAL, BIN_OP_RETURN, XBIN_OP_RETURN, LEXER_DEBUG):
Delete macros.
(octave_lexer::handle_op, octave_lexer::handle_incompatible_op,
octave_lexer::handle_op_internal, octave_lexer::push_token,
octave_lexer::handle_token, octave_lexer::count_token,
octave_lexer::show_token): New functions. Use them in place of
deleted macros.
(NOT, POW, EPOW): Delete pattern definitions.
({NOT}, {POW}=, {EPOW}=): Split into separate rules for each pattern.
(octave_lexer::handle_end_of_input, octave_lexer::handle_identifier):
Don't use OCTAVE_YYG here.
(octave_lexer::lexer_debug): Delete text argument. Use flex_yytext
instead.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Sat, 09 Mar 2013 00:02:58 -0500 |
parents | 2fc554ffbc28 |
children | d63878346099 |
line wrap: on
line source
#! /bin/sh # # Copyright (C) 1999-2012 John W. Eaton # # This file is part of Octave. # # Octave is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by the # Free Software Foundation; either version 3 of the License, or (at # your option) any later version. # # Octave is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License # for more details. # # You should have received a copy of the GNU General Public License # along with Octave; see the file COPYING. If not, see # <http://www.gnu.org/licenses/>. SED=${SED:-'sed'} $SED -n -e '/^BEGIN_DOC_STRING/{ : loop N /END_DOC_STRING/b done b loop : done s/BEGIN_DOC_STRING// s/END_DOC_STRING// p }'