help-bison
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: how to handle large varible sized semanitc values (in C-basedparsers


From: Hans Aberg
Subject: Re: how to handle large varible sized semanitc values (in C-basedparsers)?
Date: Thu, 5 Jul 2007 19:00:40 +0200


On 5 Jul 2007, at 16:26, Gary Funck wrote:


Hans, thanks for the follow-up.  I noticed after the
fact that I didn't modify my current %union definition
to the form where it held the storage for the binary
data within the node itself. To clarify, the defintion
should have been:

%union {
  uda_tword_t val;
  uda_tword_t val2[2];
  uda_tint_t signed_val;
  uda_taddr_t addr_val;
  uda_debugger_pts_t pts;
  char *str;
  uda_binary_data_t data;
}

where uda_binary_data_t is defined as:

One idea of using %union is to save space, so it would no longer apply with your definition, as the "union" takes up at least the size of its smallest member.

  Hans Aberg






reply via email to

[Prev in Thread] Current Thread [Next in Thread]