[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Change the handling of the symbols in the skeletons.
From: |
Paolo Bonzini |
Subject: |
Re: [PATCH] Change the handling of the symbols in the skeletons. |
Date: |
Mon, 10 Nov 2008 14:21:45 +0100 |
User-agent: |
Thunderbird 2.0.0.17 (Macintosh/20080914) |
Akim Demaille wrote:
>
> Le 12 août 08 à 21:48, Akim Demaille a écrit :
>
>> Before we were using tables which lines were the symbols and which
>> columns were things like number, tag, type-name etc. It is was
>> difficult to extend: each time a column was added, all the numbers had
>> to be updated (you asked for colon $2, not for "tag"). Also, it was
>> hard to filter these tables when only a subset of the symbols (say the
>> tokens, or the nterms, or the tokens that have and external number
>> *and* a type-name) was of interest.
>>
>> Now instead of monolithic tables, we define one macro per cell. For
>> instance "b4_symbol(0, tag)" is a macro name which contents is
>> self-decriptive. The macro "b4_symbol" provides easier access to
>> these cells.
>>
>> * src/output.c (type_names_output): Remove.
>> (symbol_numbers_output, symbol_definitions_output): New.
>> (muscles_output): Call them.
>> (prepare_symbols): Define b4_symbols_number.
>
> This change should be propagated to the other skeletons as well, so that
> we keep a single access to the symbol components.
Would be easier if you had a changelog entry for lalr1.cc too ;-)
Paolo