bug-bison
[Top][All Lists]
Advanced

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

Incorrectly dereferencing %union fields in y.tab.c


From: Milton KBenjamin
Subject: Incorrectly dereferencing %union fields in y.tab.c
Date: Sun, 15 Jun 2014 13:58:31 -0400

address@hidden

Hi All,

y.tab.c file dereferences with .int rather than with .ival

Best
Milt

y.tab.c file 

...
  YY_REDUCE_PRINT (yyn);
  switch (yyn)
    {
        case 4:

/* Line 1464 of yacc.c  */
#line 95 "cfg.y"
    {(yyval.int)=(yyvsp[(1) - (1)].int); dbg print("SensorId: 
INTEGER=%d\n",(yyvsp[(1) - (1)].int));;}
    break;

  case 5:

/* Line 1464 of yacc.c  */
#line 98 "cfg.y"
    {(yyval.sval)=(yyvsp[(1) - (1)].sval); dbg print("SecurityCode: 
LETTERS=%s\n",(yyvsp[(1) - (1)].sval));;}
    break;

  case 6:

/* Line 1464 of yacc.c  */
#line 101 "cfg.y"
    {(yyval.int)=(yyvsp[(1) - (1)].int);;}
    break;

  case 7:

/* Line 1464 of yacc.c  */
#line 102 "cfg.y"
    {(yyval.int)=(yyvsp[(1) - (1)].int);;}
    break;

  case 8:

Attachment: cfg.y
Description: Binary data

Attachment: cfg.h
Description: Text document


reply via email to

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