[Cmake-commits] [cmake-commits] king committed cmCommandArgumentParser.cxx 1.14 1.15 cmCommandArgumentParser.y 1.11 1.12

cmake-commits at cmake.org cmake-commits at cmake.org
Thu Dec 18 09:58:03 EST 2008


Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv27065/Source

Modified Files:
	cmCommandArgumentParser.cxx cmCommandArgumentParser.y 
Log Message:
BUG: Move previous parser bugfixes into input file

The command argument parser code is generated by bison.  This change
restores some fixes previously applied to the generated output that were
destroyed by regenerating the parser source.  This time the fixes have
been put in the input file so regenerating the parser will not destroy
them again.


Index: cmCommandArgumentParser.y
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmCommandArgumentParser.y,v
retrieving revision 1.11
retrieving revision 1.12
diff -C 2 -d -r1.11 -r1.12
*** cmCommandArgumentParser.y	17 Dec 2008 13:24:35 -0000	1.11
--- cmCommandArgumentParser.y	18 Dec 2008 14:58:01 -0000	1.12
***************
*** 26,29 ****
--- 26,30 ----
  Modify cmCommandArgumentParser.cxx:
    - remove TABs
+   - put header block at top of file
  
  */
***************
*** 63,69 ****
  
  #define YYDEBUG 1
! //#define YYMAXDEPTH 100000
! //#define YYINITDEPTH 10000
! 
  
  /* Disable some warnings in the generated code.  */
--- 64,70 ----
  
  #define YYDEBUG 1
! /* Configure the parser to support large input.  */
! #define YYMAXDEPTH 100000
! #define YYINITDEPTH 10000
  
  /* Disable some warnings in the generated code.  */
***************
*** 78,81 ****
--- 79,84 ----
  # pragma warning (disable: 4065) /* Switch statement contains default but no
                                      case. */
+ # pragma warning (disable: 4244) /* loss of precision */
+ # pragma warning (disable: 4702) /* unreachable code */
  #endif
  %}

Index: cmCommandArgumentParser.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmCommandArgumentParser.cxx,v
retrieving revision 1.14
retrieving revision 1.15
diff -C 2 -d -r1.14 -r1.15
*** cmCommandArgumentParser.cxx	17 Dec 2008 13:24:35 -0000	1.14
--- cmCommandArgumentParser.cxx	18 Dec 2008 14:58:01 -0000	1.15
***************
*** 10,15 ****
    See Copyright.txt or http://www.cmake.org/HTML/Copyright.html for details.
  
!      This software is distributed WITHOUT ANY WARRANTY; without even 
!      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
       PURPOSE.  See the above copyright notices for more information.
  
--- 10,15 ----
    See Copyright.txt or http://www.cmake.org/HTML/Copyright.html for details.
  
!      This software is distributed WITHOUT ANY WARRANTY; without even
!      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
       PURPOSE.  See the above copyright notices for more information.
  
***************
*** 151,154 ****
--- 151,155 ----
  Modify cmCommandArgumentParser.cxx:
    - remove TABs
+   - put header block at top of file
  
  */
***************
*** 188,194 ****
  
  #define YYDEBUG 1
! //#define YYMAXDEPTH 100000
! //#define YYINITDEPTH 10000
! 
  
  /* Disable some warnings in the generated code.  */
--- 189,195 ----
  
  #define YYDEBUG 1
! /* Configure the parser to support large input.  */
! #define YYMAXDEPTH 100000
! #define YYINITDEPTH 10000
  
  /* Disable some warnings in the generated code.  */
***************
*** 203,206 ****
--- 204,209 ----
  # pragma warning (disable: 4065) /* Switch statement contains default but no
                                      case. */
+ # pragma warning (disable: 4244) /* loss of precision */
+ # pragma warning (disable: 4702) /* unreachable code */
  #endif
  
***************
*** 237,241 ****
  
  /* Line 216 of yacc.c.  */
! #line 224 "cmCommandArgumentParser.cxx"
  
  #ifdef short
--- 240,244 ----
  
  /* Line 216 of yacc.c.  */
! #line 227 "cmCommandArgumentParser.cxx"
  
  #ifdef short
***************
*** 526,532 ****
  static const yytype_uint8 yyrline[] =
  {
!        0,   113,   113,   120,   125,   131,   135,   141,   146,   152,
!      157,   162,   167,   172,   177,   183,   189,   195,   201,   207,
!      212,   218,   222,   228,   233
  };
  #endif
--- 529,535 ----
  static const yytype_uint8 yyrline[] =
  {
!        0,   116,   116,   123,   128,   134,   138,   144,   149,   155,
!      160,   165,   170,   175,   180,   186,   192,   198,   204,   210,
!      215,   221,   225,   231,   236
  };
  #endif
***************
*** 1450,1454 ****
      {
          case 2:
! #line 114 "cmCommandArgumentParser.y"
      {
    (yyval.str) = 0;
--- 1453,1457 ----
      {
          case 2:
! #line 117 "cmCommandArgumentParser.y"
      {
    (yyval.str) = 0;
***************
*** 1458,1462 ****
  
    case 3:
! #line 121 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1461,1465 ----
  
    case 3:
! #line 124 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1465,1469 ****
  
    case 4:
! #line 126 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->CombineUnions((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str));
--- 1468,1472 ----
  
    case 4:
! #line 129 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->CombineUnions((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str));
***************
*** 1472,1476 ****
  
    case 5:
! #line 131 "cmCommandArgumentParser.y"
      {
    (yyval.str) = 0;
--- 1475,1479 ----
  
    case 5:
! #line 134 "cmCommandArgumentParser.y"
      {
    (yyval.str) = 0;
***************
*** 1479,1483 ****
  
    case 6:
! #line 136 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->CombineUnions((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str));
--- 1482,1486 ----
  
    case 6:
! #line 139 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->CombineUnions((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str));
***************
*** 1486,1490 ****
  
    case 7:
! #line 142 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1489,1493 ----
  
    case 7:
! #line 145 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1493,1497 ****
  
    case 8:
! #line 147 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1496,1500 ----
  
    case 8:
! #line 150 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1500,1504 ****
  
    case 9:
! #line 153 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1503,1507 ----
  
    case 9:
! #line 156 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1507,1511 ****
  
    case 10:
! #line 158 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1510,1514 ----
  
    case 10:
! #line 161 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1514,1518 ****
  
    case 11:
! #line 163 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1517,1521 ----
  
    case 11:
! #line 166 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1521,1525 ****
  
    case 12:
! #line 168 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1524,1528 ----
  
    case 12:
! #line 171 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1528,1532 ****
  
    case 13:
! #line 173 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1531,1535 ----
  
    case 13:
! #line 176 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1535,1539 ****
  
    case 14:
! #line 178 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1538,1542 ----
  
    case 14:
! #line 181 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1542,1546 ****
  
    case 15:
! #line 184 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->ExpandSpecialVariable((yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str));
--- 1545,1549 ----
  
    case 15:
! #line 187 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->ExpandSpecialVariable((yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str));
***************
*** 1550,1554 ****
  
    case 16:
! #line 190 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->ExpandSpecialVariable((yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str));
--- 1553,1557 ----
  
    case 16:
! #line 193 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->ExpandSpecialVariable((yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str));
***************
*** 1558,1562 ****
  
    case 17:
! #line 196 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->ExpandVariable((yyvsp[(2) - (3)].str));
--- 1561,1565 ----
  
    case 17:
! #line 199 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->ExpandVariable((yyvsp[(2) - (3)].str));
***************
*** 1566,1570 ****
  
    case 18:
! #line 202 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->ExpandVariableForAt((yyvsp[(1) - (1)].str));
--- 1569,1573 ----
  
    case 18:
! #line 205 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->ExpandVariableForAt((yyvsp[(1) - (1)].str));
***************
*** 1573,1577 ****
  
    case 19:
! #line 208 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1576,1580 ----
  
    case 19:
! #line 211 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1580,1584 ****
  
    case 20:
! #line 213 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (2)].str);
--- 1583,1587 ----
  
    case 20:
! #line 216 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (2)].str);
***************
*** 1587,1591 ****
  
    case 21:
! #line 218 "cmCommandArgumentParser.y"
      {
    (yyval.str) = 0;
--- 1590,1594 ----
  
    case 21:
! #line 221 "cmCommandArgumentParser.y"
      {
    (yyval.str) = 0;
***************
*** 1594,1598 ****
  
    case 22:
! #line 223 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->CombineUnions((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str));
--- 1597,1601 ----
  
    case 22:
! #line 226 "cmCommandArgumentParser.y"
      {
    (yyval.str) = yyGetParser->CombineUnions((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str));
***************
*** 1601,1605 ****
  
    case 23:
! #line 229 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1604,1608 ----
  
    case 23:
! #line 232 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1608,1612 ****
  
    case 24:
! #line 234 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
--- 1611,1615 ----
  
    case 24:
! #line 237 "cmCommandArgumentParser.y"
      {
    (yyval.str) = (yyvsp[(1) - (1)].str);
***************
*** 1616,1620 ****
  
  /* Line 1267 of yacc.c.  */
! #line 1603 "cmCommandArgumentParser.cxx"
        default: break;
      }
--- 1619,1623 ----
  
  /* Line 1267 of yacc.c.  */
! #line 1606 "cmCommandArgumentParser.cxx"
        default: break;
      }
***************
*** 1830,1834 ****
  
  
! #line 239 "cmCommandArgumentParser.y"
  
  /* End of grammar */
--- 1833,1837 ----
  
  
! #line 242 "cmCommandArgumentParser.y"
  
  /* End of grammar */



More information about the Cmake-commits mailing list