writeexcel 0.1.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (143) hide show
  1. data/README +26 -31
  2. data/examples/a_simple.rb +42 -42
  3. data/examples/{autofilters.rb → autofilter.rb} +264 -266
  4. data/examples/bigfile.rb +29 -0
  5. data/examples/chart_area.rb +120 -0
  6. data/examples/chart_bar.rb +119 -0
  7. data/examples/chart_column.rb +119 -0
  8. data/examples/chart_line.rb +119 -0
  9. data/examples/chart_pie.rb +107 -0
  10. data/examples/chart_scatter.rb +120 -0
  11. data/examples/chart_stock.rb +147 -0
  12. data/examples/copyformat.rb +51 -51
  13. data/examples/data_validate.rb +278 -278
  14. data/examples/date_time.rb +86 -86
  15. data/examples/defined_name.rb +31 -0
  16. data/examples/demo.rb +120 -118
  17. data/examples/diag_border.rb +35 -35
  18. data/examples/formats.rb +489 -489
  19. data/examples/header.rb +136 -136
  20. data/examples/hidden.rb +28 -28
  21. data/examples/hyperlink.rb +42 -42
  22. data/examples/images.rb +52 -52
  23. data/examples/merge1.rb +39 -39
  24. data/examples/merge2.rb +44 -44
  25. data/examples/merge3.rb +65 -65
  26. data/examples/merge4.rb +82 -82
  27. data/examples/merge5.rb +79 -79
  28. data/examples/properties.rb +33 -0
  29. data/examples/properties_jp.rb +32 -0
  30. data/examples/protection.rb +46 -46
  31. data/examples/regions.rb +52 -52
  32. data/examples/repeat.rb +42 -42
  33. data/examples/stats.rb +75 -75
  34. data/examples/stocks.rb +80 -80
  35. data/examples/tab_colors.rb +30 -30
  36. data/examples/write_arrays.rb +82 -0
  37. data/lib/writeexcel.rb +1134 -18
  38. data/lib/writeexcel/biffwriter.rb +273 -260
  39. data/lib/writeexcel/chart.rb +2306 -217
  40. data/lib/writeexcel/charts/area.rb +152 -0
  41. data/lib/writeexcel/charts/bar.rb +177 -0
  42. data/lib/writeexcel/charts/column.rb +156 -0
  43. data/lib/writeexcel/charts/external.rb +61 -0
  44. data/lib/writeexcel/charts/line.rb +152 -0
  45. data/lib/writeexcel/charts/pie.rb +169 -0
  46. data/lib/writeexcel/charts/scatter.rb +192 -0
  47. data/lib/writeexcel/charts/stock.rb +211 -0
  48. data/lib/writeexcel/excelformulaparser.rb +208 -195
  49. data/lib/writeexcel/format.rb +1697 -1108
  50. data/lib/writeexcel/formula.rb +1050 -986
  51. data/lib/writeexcel/olewriter.rb +322 -322
  52. data/lib/writeexcel/properties.rb +251 -250
  53. data/lib/writeexcel/storage_lite.rb +968 -0
  54. data/lib/writeexcel/workbook.rb +3294 -2630
  55. data/lib/writeexcel/worksheet.rb +9012 -6377
  56. data/test/excelfile/Chart1.xls +0 -0
  57. data/test/excelfile/Chart2.xls +0 -0
  58. data/test/excelfile/Chart3.xls +0 -0
  59. data/test/excelfile/Chart4.xls +0 -0
  60. data/test/excelfile/Chart5.xls +0 -0
  61. data/test/perl_output/Chart1.xls.data +0 -0
  62. data/test/perl_output/Chart2.xls.data +0 -0
  63. data/test/perl_output/Chart3.xls.data +0 -0
  64. data/test/perl_output/Chart4.xls.data +0 -0
  65. data/test/perl_output/Chart5.xls.data +0 -0
  66. data/test/perl_output/a_simple.xls +0 -0
  67. data/test/perl_output/autofilter.xls +0 -0
  68. data/test/perl_output/chart_area.xls +0 -0
  69. data/test/perl_output/chart_bar.xls +0 -0
  70. data/test/perl_output/chart_column.xls +0 -0
  71. data/test/perl_output/chart_line.xls +0 -0
  72. data/test/perl_output/data_validate.xls +0 -0
  73. data/test/perl_output/date_time.xls +0 -0
  74. data/test/perl_output/demo.xls +0 -0
  75. data/test/perl_output/demo101.bin +0 -0
  76. data/test/perl_output/demo201.bin +0 -0
  77. data/test/perl_output/demo301.bin +0 -0
  78. data/test/perl_output/demo401.bin +0 -0
  79. data/test/perl_output/demo501.bin +0 -0
  80. data/test/perl_output/diag_border.xls +0 -0
  81. data/test/perl_output/headers.xls +0 -0
  82. data/test/perl_output/hyperlink.xls +0 -0
  83. data/test/perl_output/images.xls +0 -0
  84. data/test/perl_output/merge1.xls +0 -0
  85. data/test/perl_output/merge2.xls +0 -0
  86. data/test/perl_output/merge3.xls +0 -0
  87. data/test/perl_output/merge4.xls +0 -0
  88. data/test/perl_output/merge5.xls +0 -0
  89. data/test/perl_output/protection.xls +0 -0
  90. data/test/perl_output/regions.xls +0 -0
  91. data/test/perl_output/stats.xls +0 -0
  92. data/test/perl_output/stocks.xls +0 -0
  93. data/test/perl_output/tab_colors.xls +0 -0
  94. data/test/perl_output/unicode_cyrillic.xls +0 -0
  95. data/test/perl_output/workbook1.xls +0 -0
  96. data/test/perl_output/workbook2.xls +0 -0
  97. data/test/tc_all.rb +32 -31
  98. data/test/tc_biff.rb +104 -104
  99. data/test/tc_chart.rb +22 -22
  100. data/test/tc_example_match.rb +1944 -1280
  101. data/test/tc_format.rb +1254 -1267
  102. data/test/tc_formula.rb +63 -63
  103. data/test/tc_ole.rb +110 -110
  104. data/test/tc_storage_lite.rb +149 -0
  105. data/test/tc_workbook.rb +140 -115
  106. data/test/tc_worksheet.rb +115 -115
  107. data/test/test_00_IEEE_double.rb +14 -14
  108. data/test/test_01_add_worksheet.rb +12 -12
  109. data/test/test_02_merge_formats.rb +58 -58
  110. data/test/test_04_dimensions.rb +397 -397
  111. data/test/test_05_rows.rb +182 -182
  112. data/test/test_06_extsst.rb +80 -80
  113. data/test/test_11_date_time.rb +484 -484
  114. data/test/test_12_date_only.rb +506 -506
  115. data/test/test_13_date_seconds.rb +486 -486
  116. data/test/test_21_escher.rb +642 -629
  117. data/test/test_22_mso_drawing_group.rb +750 -739
  118. data/test/test_23_note.rb +78 -78
  119. data/test/test_24_txo.rb +80 -80
  120. data/test/test_25_position_object.rb +82 -0
  121. data/test/test_26_autofilter.rb +327 -327
  122. data/test/test_27_autofilter.rb +144 -144
  123. data/test/test_28_autofilter.rb +174 -174
  124. data/test/test_29_process_jpg.rb +681 -131
  125. data/test/test_30_validation_dval.rb +82 -82
  126. data/test/test_31_validation_dv_strings.rb +131 -131
  127. data/test/test_32_validation_dv_formula.rb +211 -211
  128. data/test/test_40_property_types.rb +191 -191
  129. data/test/test_41_properties.rb +238 -238
  130. data/test/test_42_set_properties.rb +442 -419
  131. data/test/test_50_name_stored.rb +305 -0
  132. data/test/test_51_name_print_area.rb +363 -0
  133. data/test/test_52_name_print_titles.rb +460 -0
  134. data/test/test_53_autofilter.rb +209 -0
  135. data/test/test_60_chart_generic.rb +576 -0
  136. data/test/test_61_chart_subclasses.rb +97 -0
  137. data/test/test_62_chart_formats.rb +270 -0
  138. data/test/test_63_chart_area_formats.rb +647 -0
  139. data/test/test_chartex.rb +35 -0
  140. data/test/ts_all.rb +46 -34
  141. data/writeexcel.gemspec +18 -0
  142. data/writeexcel.rdoc +583 -0
  143. metadata +162 -108
@@ -0,0 +1,211 @@
1
+ ###############################################################################
2
+ #
3
+ # Stock - A writer class for Excel Stock charts.
4
+ #
5
+ # Used in conjunction with Spreadsheet::WriteExcel::Chart.
6
+ #
7
+ # See formatting note in Spreadsheet::WriteExcel::Chart.
8
+ #
9
+ # Copyright 2000-2010, John McNamara, jmcnamara@cpan.org
10
+ #
11
+ # original written in Perl by John McNamara
12
+ # converted to Ruby by Hideo Nakamura, cxn03651@msj.biglobe.ne.jp
13
+ #
14
+
15
+ require 'writeexcel'
16
+
17
+ class Chart
18
+
19
+ # ==SYNOPSIS
20
+ #
21
+ # To create a simple Excel file with a Stock chart using WriteExcel:
22
+ #
23
+ # #!/usr/bin/ruby -w
24
+ #
25
+ # require 'writeexcel'
26
+ #
27
+ # workbook = Spreadsheet::WriteExcel.new('chart.xls')
28
+ # worksheet = workbook.add_worksheet
29
+ #
30
+ # chart = workbook.add_chart(:type => Chart::Stock)
31
+ #
32
+ # # Add a series for each Open-High-Low-Close.
33
+ # chart.add_series(:categories => '=Sheet1!$A$2:$A$6', :values => '=Sheet1!$B$2:$B$6')
34
+ # chart.add_series(:categories => '=Sheet1!$A$2:$A$6', :values => '=Sheet1!$C$2:$C$6')
35
+ # chart.add_series(:categories => '=Sheet1!$A$2:$A$6', :values => '=Sheet1!$D$2:$D$6')
36
+ # chart.add_series(:categories => '=Sheet1!$A$2:$A$6', :values => '=Sheet1!$E$2:$E$6')
37
+ #
38
+ # # Add the worksheet data the chart refers to.
39
+ # # ... See the full example below.
40
+ #
41
+ # workbook.close
42
+ #
43
+ # ==DESCRIPTION
44
+ #
45
+ # This module implements Stock charts for WriteExcel. The chart object
46
+ # is created via the Workbook add_chart() method:
47
+ #
48
+ # chart = workbook.add_chart(:type => Chart::Stock)
49
+ #
50
+ # Once the object is created it can be configured via the following methods
51
+ # that are common to all chart classes:
52
+ #
53
+ # chart.add_series
54
+ # chart.set_x_axis
55
+ # chart.set_y_axis
56
+ # chart.set_title
57
+ #
58
+ # These methods are explained in detail in Chart section of WriteExcel.
59
+ # Class specific methods or settings, if any, are explained below.
60
+ #
61
+ # ==Stock Chart Methods
62
+ #
63
+ # There aren't currently any stock chart specific methods.
64
+ # See the TODO section of Chart section in WriteExcel.
65
+ #
66
+ # The default Stock chart is an Open-High-Low-Close chart.
67
+ # A series must be added for each of these data sources.
68
+ #
69
+ # The default Stock chart is in black and white. User defined colours
70
+ # will be added at a later stage.
71
+ #
72
+ # ==EXAMPLE
73
+ #
74
+ # Here is a complete example that demonstrates most of the available features
75
+ # when creating a Stock chart.
76
+ #
77
+ # #!/usr/bin/ruby -w
78
+ #
79
+ # require 'writeexcel'
80
+ #
81
+ # workbook = Spreadsheet::WriteExcel.new('chart_stock_ex.xls')
82
+ # worksheet = workbook.add_worksheet
83
+ # bold = workbook.add_format(:bold => 1)
84
+ # date_format = workbook.add_format(:num_format => 'dd/mm/yyyy')
85
+ #
86
+ # # Add the worksheet data that the charts will refer to.
87
+ # headings = [ 'Date', 'Open', 'High', 'Low', 'Close' ]
88
+ # data = [
89
+ # [ '2009-08-23', 110.75, 113.48, 109.05, 109.40 ],
90
+ # [ '2009-08-24', 111.24, 111.60, 103.57, 104.87 ],
91
+ # [ '2009-08-25', 104.96, 108.00, 103.88, 106.00 ],
92
+ # [ '2009-08-26', 104.95, 107.95, 104.66, 107.91 ],
93
+ # [ '2009-08-27', 108.10, 108.62, 105.69, 106.15 ]
94
+ # ]
95
+ #
96
+ # worksheet.write('A1', headings, bold)
97
+ #
98
+ # row = 1
99
+ # data.each do |d|
100
+ # worksheet.write(row, 0, d[0], date_format)
101
+ # worksheet.write(row, 1, d[1])
102
+ # worksheet.write(row, 2, d[2])
103
+ # worksheet.write(row, 3, d[3])
104
+ # worksheet.write(row, 4, d[4])
105
+ # row += 1
106
+ # end
107
+ #
108
+ # # Create a new chart object. In this case an embedded chart.
109
+ # chart = workbook.add_chart(:type => Chart::Stock, ::embedded => 1)
110
+ #
111
+ # # Add a series for each of the Open-High-Low-Close columns.
112
+ # chart.add_series(
113
+ # :categories => '=Sheet1!$A$2:$A$6',
114
+ # :values => '=Sheet1!$B$2:$B$6',
115
+ # :name => 'Open'
116
+ # )
117
+ #
118
+ # chart.add_series(
119
+ # :categories => '=Sheet1!$A$2:$A$6',
120
+ # :values => '=Sheet1!$C$2:$C$6',
121
+ # :name => 'High'
122
+ # )
123
+ #
124
+ # chart.add_series(
125
+ # :categories => '=Sheet1!$A$2:$A$6',
126
+ # :values => '=Sheet1!$D$2:$D$6',
127
+ # :name => 'Low'
128
+ # )
129
+ #
130
+ # chart.add_series(
131
+ # :categories => '=Sheet1!$A$2:$A$6',
132
+ # :values => '=Sheet1!$E$2:$E$6',
133
+ # :name => 'Close'
134
+ # )
135
+ #
136
+ # # Add a chart title and some axis labels.
137
+ # chart.set_title(:name => 'Open-High-Low-Close')
138
+ # chart.set_x_axis(:name => 'Date')
139
+ # chart.set_y_axis(:name => 'Share price')
140
+ #
141
+ # # Insert the chart into the worksheet (with an offset).
142
+ # worksheet.insert_chart('F2', chart, 25, 10)
143
+ #
144
+ # workbook.close
145
+ #
146
+ class Stock < Chart
147
+ ###############################################################################
148
+ #
149
+ # new()
150
+ #
151
+ #
152
+ def initialize(*args) # :nodoc:
153
+ super
154
+ end
155
+
156
+ ###############################################################################
157
+ #
158
+ # _store_chart_type()
159
+ #
160
+ # Implementation of the abstract method from the specific chart class.
161
+ #
162
+ # Write the LINE chart BIFF record. A stock chart uses the same LINE record
163
+ # as a line chart but with additional DROPBAR and CHARTLINE records to define
164
+ # the stock style.
165
+ #
166
+ def store_chart_type # :nodoc:
167
+ record = 0x1018 # Record identifier.
168
+ length = 0x0002 # Number of bytes to follow.
169
+ grbit = 0x0000 # Option flags.
170
+
171
+ header = [record, length].pack('vv')
172
+ data = [grbit].pack('v')
173
+
174
+ append(header, data)
175
+ end
176
+
177
+ ###############################################################################
178
+ #
179
+ # _store_marker_dataformat_stream(). Overridden.
180
+ #
181
+ # This is an implementation of the parent abstract method to define
182
+ # properties of markers, linetypes, pie formats and other.
183
+ #
184
+ def store_marker_dataformat_stream # :nodoc:
185
+ store_dropbar
186
+ store_begin
187
+ store_lineformat(0x00000000, 0x0000, 0xFFFF, 0x0001, 0x004F)
188
+ store_areaformat(0x00FFFFFF, 0x0000, 0x01, 0x01, 0x09, 0x08)
189
+ store_end
190
+
191
+ store_dropbar
192
+ store_begin
193
+ store_lineformat(0x00000000, 0x0000, 0xFFFF, 0x0001, 0x004F)
194
+ store_areaformat(0x0000, 0x00FFFFFF, 0x01, 0x01, 0x08, 0x09)
195
+ store_end
196
+
197
+ store_chartline
198
+ store_lineformat(0x00000000, 0x0000, 0xFFFF, 0x0000, 0x004F)
199
+
200
+
201
+ store_dataformat(0x0000, 0xFFFD, 0x0000)
202
+ store_begin
203
+ store_3dbarshape
204
+ store_lineformat(0x00000000, 0x0005, 0xFFFF, 0x0000, 0x004F)
205
+ store_areaformat(0x00000000, 0x0000, 0x00, 0x01, 0x4D, 0x4D)
206
+ store_pieformat
207
+ store_markerformat(0x00, 0x00, 0x00, 0x00, 0x4D, 0x4D, 0x3C)
208
+ store_end
209
+ end
210
+ end
211
+ end
@@ -5,180 +5,183 @@
5
5
  #
6
6
 
7
7
  require 'racc/parser.rb'
8
- class ExcelFormulaParser < Racc::Parser
8
+ class ExcelFormulaParser < Racc::Parser # :nodoc:
9
9
  ##### State transition tables begin ###
10
10
 
11
11
  racc_action_table = [
12
- 16, 52, 25, 27, 29, 31, 33, 20, 19, 3,
13
- nil, 53, 22, 18, nil, 4, 5, 6, 8, 12,
14
- 13, 14, 15, 17, 16, 25, 27, 29, 31, 33,
15
- nil, 10, nil, nil, nil, 16, nil, 18, nil, 4,
16
- 5, 6, 8, 12, 13, 14, 15, 17, 18, 16,
17
- 4, 5, 6, 8, 12, 13, 14, 15, 17, nil,
18
- 16, nil, 18, nil, 4, 5, 6, 8, 12, 13,
19
- 14, 15, 17, 18, 16, 4, 5, 6, 8, 12,
20
- 13, 14, 15, 17, nil, 16, nil, 18, nil, 4,
21
- 5, 6, 8, 12, 13, 14, 15, 17, 18, 16,
22
- 4, 5, 6, 8, 12, 13, 14, 15, 17, nil,
23
- 16, nil, 18, 36, 4, 5, 6, 8, 12, 13,
24
- 14, 15, 17, 18, 16, 4, 5, 6, 8, 12,
25
- 13, 14, 15, 17, nil, 16, nil, 18, nil, 4,
26
- 5, 6, 8, 12, 13, 14, 15, 17, 18, 16,
27
- 4, 5, 6, 8, 12, 13, 14, 15, 17, nil,
28
- 16, nil, 18, nil, 4, 5, 6, 8, 12, 13,
29
- 14, 15, 17, 18, 16, 4, 5, 6, 8, 12,
30
- 13, 14, 15, 17, nil, 16, nil, 18, nil, 4,
31
- 5, 6, 8, 12, 13, 14, 15, 17, 18, 16,
32
- 4, 5, 6, 8, 12, 13, 14, 15, 17, nil,
33
- 16, nil, 18, nil, 4, 5, 6, 8, 12, 13,
34
- 14, 15, 17, 18, nil, 4, 5, 6, 8, 12,
35
- 13, 14, 15, 17, 22, 23, 26, 28, 30, 32,
36
- nil, nil, nil, nil, nil, 21, nil, 25, 27, 29,
37
- 31, 33, nil, 51, 22, 23, 26, 28, 30, 32,
38
- 22, 23, 26, 28, nil, nil, nil, 25, 27, 29,
39
- 31, 33, nil, 25, 27, 29, 31, 33, 22, 23,
40
- 26, 28, nil, nil, nil, 22, 23, 26, 28, 30,
41
- 32, 25, 27, 29, 31, 33, 21, 24, 25, 27,
42
- 29, 31, 33, 22, 23, 26, 28, 30, 32, nil,
43
- nil, nil, nil, nil, 21, nil, 25, 27, 29, 31,
44
- 33, 22, 23, 26, 28, 30, 32, nil, nil, nil,
45
- nil, nil, 21, nil, 25, 27, 29, 31, 33, 22,
46
- 23, 26, 28, 30, 32, 22, nil, nil, nil, nil,
47
- 21, nil, 25, 27, 29, 31, 33, nil, 25, 27,
48
- 29, 31, 33, 22, 23, 26, 28, 30, 32, 22,
49
- 23, nil, nil, nil, 21, nil, 25, 27, 29, 31,
50
- 33, nil, 25, 27, 29, 31, 33, 22, 23, 26,
51
- 28, 30, 32, 22, 23, nil, nil, nil, 21, nil,
52
- 25, 27, 29, 31, 33, nil, 25, 27, 29, 31,
53
- 33, 22, 23, 26, 28, 30, 32, nil, nil, nil,
54
- nil, nil, 21, nil, 25, 27, 29, 31, 33, 22,
55
- 23, 26, 28, 30, 32, nil, nil, nil, nil, nil,
56
- 21, nil, 25, 27, 29, 31, 33 ]
12
+ 16, 54, 26, 28, 30, 32, 34, 21, 20, 3,
13
+ nil, nil, 53, 19, 23, 4, 5, 6, 7, 10,
14
+ 13, 14, 15, 17, 18, 16, nil, 26, 28, 30,
15
+ 32, 34, 8, nil, nil, nil, nil, 16, 19, nil,
16
+ 4, 5, 6, 7, 10, 13, 14, 15, 17, 18,
17
+ 19, 16, 4, 5, 6, 7, 10, 13, 14, 15,
18
+ 17, 18, nil, 16, 19, nil, 4, 5, 6, 7,
19
+ 10, 13, 14, 15, 17, 18, 19, 16, 4, 5,
20
+ 6, 7, 10, 13, 14, 15, 17, 18, nil, 16,
21
+ 19, nil, 4, 5, 6, 7, 10, 13, 14, 15,
22
+ 17, 18, 19, 16, 4, 5, 6, 7, 10, 13,
23
+ 14, 15, 17, 18, nil, 16, 19, 37, 4, 5,
24
+ 6, 7, 10, 13, 14, 15, 17, 18, 19, 16,
25
+ 4, 5, 6, 7, 10, 13, 14, 15, 17, 18,
26
+ nil, 16, 19, nil, 4, 5, 6, 7, 10, 13,
27
+ 14, 15, 17, 18, 19, 16, 4, 5, 6, 7,
28
+ 10, 13, 14, 15, 17, 18, nil, 16, 19, nil,
29
+ 4, 5, 6, 7, 10, 13, 14, 15, 17, 18,
30
+ 19, 16, 4, 5, 6, 7, 10, 13, 14, 15,
31
+ 17, 18, nil, 16, 19, nil, 4, 5, 6, 7,
32
+ 10, 13, 14, 15, 17, 18, 19, 16, 4, 5,
33
+ 6, 7, 10, 13, 14, 15, 17, 18, nil, 16,
34
+ 19, nil, 4, 5, 6, 7, 10, 13, 14, 15,
35
+ 17, 18, 19, nil, 4, 5, 6, 7, 10, 13,
36
+ 14, 15, 17, 18, 23, 24, 27, 29, 31, 33,
37
+ nil, nil, nil, nil, nil, 22, nil, 26, 28, 30,
38
+ 32, 34, nil, 52, 23, 24, 27, 29, 31, 33,
39
+ 23, 24, 27, 29, nil, nil, nil, 26, 28, 30,
40
+ 32, 34, nil, 26, 28, 30, 32, 34, 23, 24,
41
+ 27, 29, nil, nil, nil, 23, 24, 27, 29, 31,
42
+ 33, 26, 28, 30, 32, 34, 22, 25, 26, 28,
43
+ 30, 32, 34, 23, 24, 27, 29, 31, 33, nil,
44
+ nil, nil, nil, nil, 22, nil, 26, 28, 30, 32,
45
+ 34, 23, 24, 27, 29, 31, 33, nil, nil, nil,
46
+ nil, nil, 22, nil, 26, 28, 30, 32, 34, 23,
47
+ 24, 27, 29, 31, 33, 23, nil, nil, nil, nil,
48
+ 22, nil, 26, 28, 30, 32, 34, nil, 26, 28,
49
+ 30, 32, 34, 23, 24, 27, 29, 31, 33, 23,
50
+ 24, nil, nil, nil, 22, nil, 26, 28, 30, 32,
51
+ 34, nil, 26, 28, 30, 32, 34, 23, 24, 27,
52
+ 29, 31, 33, 23, 24, nil, nil, nil, 22, nil,
53
+ 26, 28, 30, 32, 34, nil, 26, 28, 30, 32,
54
+ 34, 23, 24, 27, 29, 31, 33, nil, nil, nil,
55
+ nil, nil, 22, nil, 26, 28, 30, 32, 34, 23,
56
+ 24, 27, 29, 31, 33, nil, nil, nil, nil, nil,
57
+ 22, nil, 26, 28, 30, 32, 34 ]
57
58
 
58
59
  racc_action_check = [
59
- 33, 38, 34, 34, 34, 34, 34, 4, 3, 1,
60
- nil, 38, 40, 33, nil, 33, 33, 33, 33, 33,
61
- 33, 33, 33, 33, 2, 40, 40, 40, 40, 40,
62
- nil, 2, nil, nil, nil, 53, nil, 2, nil, 2,
63
- 2, 2, 2, 2, 2, 2, 2, 2, 53, 32,
64
- 53, 53, 53, 53, 53, 53, 53, 53, 53, nil,
65
- 31, nil, 32, nil, 32, 32, 32, 32, 32, 32,
66
- 32, 32, 32, 31, 16, 31, 31, 31, 31, 31,
67
- 31, 31, 31, 31, nil, 18, nil, 16, nil, 16,
68
- 16, 16, 16, 16, 16, 16, 16, 16, 18, 20,
69
- 18, 18, 18, 18, 18, 18, 18, 18, 18, nil,
70
- 21, nil, 20, 20, 20, 20, 20, 20, 20, 20,
71
- 20, 20, 20, 21, 22, 21, 21, 21, 21, 21,
72
- 21, 21, 21, 21, nil, 23, nil, 22, nil, 22,
73
- 22, 22, 22, 22, 22, 22, 22, 22, 23, 25,
74
- 23, 23, 23, 23, 23, 23, 23, 23, 23, nil,
75
- 26, nil, 25, nil, 25, 25, 25, 25, 25, 25,
76
- 25, 25, 25, 26, 27, 26, 26, 26, 26, 26,
77
- 26, 26, 26, 26, nil, 28, nil, 27, nil, 27,
78
- 27, 27, 27, 27, 27, 27, 27, 27, 28, 29,
79
- 28, 28, 28, 28, 28, 28, 28, 28, 28, nil,
80
- 30, nil, 29, nil, 29, 29, 29, 29, 29, 29,
81
- 29, 29, 29, 30, nil, 30, 30, 30, 30, 30,
82
- 30, 30, 30, 30, 35, 35, 35, 35, 35, 35,
83
- nil, nil, nil, nil, nil, 35, nil, 35, 35, 35,
84
- 35, 35, nil, 35, 39, 39, 39, 39, 39, 39,
85
- 47, 47, 47, 47, nil, nil, nil, 39, 39, 39,
86
- 39, 39, nil, 47, 47, 47, 47, 47, 49, 49,
87
- 49, 49, nil, nil, nil, 7, 7, 7, 7, 7,
88
- 7, 49, 49, 49, 49, 49, 7, 7, 7, 7,
89
- 7, 7, 7, 37, 37, 37, 37, 37, 37, nil,
90
- nil, nil, nil, nil, 37, nil, 37, 37, 37, 37,
91
- 37, 48, 48, 48, 48, 48, 48, nil, nil, nil,
92
- nil, nil, 48, nil, 48, 48, 48, 48, 48, 50,
93
- 50, 50, 50, 50, 50, 41, nil, nil, nil, nil,
94
- 50, nil, 50, 50, 50, 50, 50, nil, 41, 41,
95
- 41, 41, 41, 42, 42, 42, 42, 42, 42, 43,
96
- 43, nil, nil, nil, 42, nil, 42, 42, 42, 42,
97
- 42, nil, 43, 43, 43, 43, 43, 44, 44, 44,
98
- 44, 44, 44, 45, 45, nil, nil, nil, 44, nil,
99
- 44, 44, 44, 44, 44, nil, 45, 45, 45, 45,
100
- 45, 46, 46, 46, 46, 46, 46, nil, nil, nil,
101
- nil, nil, 46, nil, 46, 46, 46, 46, 46, 54,
102
- 54, 54, 54, 54, 54, nil, nil, nil, nil, nil,
103
- 54, nil, 54, 54, 54, 54, 54 ]
60
+ 34, 39, 35, 35, 35, 35, 35, 4, 3, 1,
61
+ nil, nil, 39, 34, 41, 34, 34, 34, 34, 34,
62
+ 34, 34, 34, 34, 34, 2, nil, 41, 41, 41,
63
+ 41, 41, 2, nil, nil, nil, nil, 53, 2, nil,
64
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
65
+ 53, 33, 53, 53, 53, 53, 53, 53, 53, 53,
66
+ 53, 53, nil, 32, 33, nil, 33, 33, 33, 33,
67
+ 33, 33, 33, 33, 33, 33, 32, 16, 32, 32,
68
+ 32, 32, 32, 32, 32, 32, 32, 32, nil, 19,
69
+ 16, nil, 16, 16, 16, 16, 16, 16, 16, 16,
70
+ 16, 16, 19, 21, 19, 19, 19, 19, 19, 19,
71
+ 19, 19, 19, 19, nil, 22, 21, 21, 21, 21,
72
+ 21, 21, 21, 21, 21, 21, 21, 21, 22, 23,
73
+ 22, 22, 22, 22, 22, 22, 22, 22, 22, 22,
74
+ nil, 24, 23, nil, 23, 23, 23, 23, 23, 23,
75
+ 23, 23, 23, 23, 24, 26, 24, 24, 24, 24,
76
+ 24, 24, 24, 24, 24, 24, nil, 27, 26, nil,
77
+ 26, 26, 26, 26, 26, 26, 26, 26, 26, 26,
78
+ 27, 28, 27, 27, 27, 27, 27, 27, 27, 27,
79
+ 27, 27, nil, 29, 28, nil, 28, 28, 28, 28,
80
+ 28, 28, 28, 28, 28, 28, 29, 30, 29, 29,
81
+ 29, 29, 29, 29, 29, 29, 29, 29, nil, 31,
82
+ 30, nil, 30, 30, 30, 30, 30, 30, 30, 30,
83
+ 30, 30, 31, nil, 31, 31, 31, 31, 31, 31,
84
+ 31, 31, 31, 31, 36, 36, 36, 36, 36, 36,
85
+ nil, nil, nil, nil, nil, 36, nil, 36, 36, 36,
86
+ 36, 36, nil, 36, 40, 40, 40, 40, 40, 40,
87
+ 48, 48, 48, 48, nil, nil, nil, 40, 40, 40,
88
+ 40, 40, nil, 48, 48, 48, 48, 48, 50, 50,
89
+ 50, 50, nil, nil, nil, 9, 9, 9, 9, 9,
90
+ 9, 50, 50, 50, 50, 50, 9, 9, 9, 9,
91
+ 9, 9, 9, 38, 38, 38, 38, 38, 38, nil,
92
+ nil, nil, nil, nil, 38, nil, 38, 38, 38, 38,
93
+ 38, 49, 49, 49, 49, 49, 49, nil, nil, nil,
94
+ nil, nil, 49, nil, 49, 49, 49, 49, 49, 51,
95
+ 51, 51, 51, 51, 51, 42, nil, nil, nil, nil,
96
+ 51, nil, 51, 51, 51, 51, 51, nil, 42, 42,
97
+ 42, 42, 42, 43, 43, 43, 43, 43, 43, 44,
98
+ 44, nil, nil, nil, 43, nil, 43, 43, 43, 43,
99
+ 43, nil, 44, 44, 44, 44, 44, 45, 45, 45,
100
+ 45, 45, 45, 46, 46, nil, nil, nil, 45, nil,
101
+ 45, 45, 45, 45, 45, nil, 46, 46, 46, 46,
102
+ 46, 47, 47, 47, 47, 47, 47, nil, nil, nil,
103
+ nil, nil, 47, nil, 47, 47, 47, 47, 47, 55,
104
+ 55, 55, 55, 55, 55, nil, nil, nil, nil, nil,
105
+ 55, nil, 55, 55, 55, 55, 55 ]
104
106
 
105
107
  racc_action_pointer = [
106
- nil, 9, 16, 8, -14, nil, nil, 282, nil, nil,
107
- nil, nil, nil, nil, nil, nil, 66, nil, 77, nil,
108
- 91, 102, 116, 127, nil, 141, 152, 166, 177, 191,
109
- 202, 52, 41, -8, -14, 231, nil, 300, -21, 251,
110
- 9, 342, 360, 366, 384, 390, 408, 257, 318, 275,
111
- 336, nil, nil, 27, 426 ]
108
+ nil, 9, 17, 8, -14, nil, nil, nil, nil, 292,
109
+ nil, nil, nil, nil, nil, nil, 69, nil, nil, 81,
110
+ nil, 95, 107, 121, 133, nil, 147, 159, 173, 185,
111
+ 199, 211, 55, 43, -8, -14, 241, nil, 310, -21,
112
+ 261, 11, 352, 370, 376, 394, 400, 418, 267, 328,
113
+ 285, 346, nil, 29, nil, 436 ]
112
114
 
113
115
  racc_action_default = [
114
- -2, -34, -1, -34, -20, -21, -22, -34, -23, -17,
115
- -4, -29, -24, -25, -26, -27, -34, -28, -34, 55,
116
- -34, -34, -34, -34, -3, -34, -34, -34, -34, -34,
117
- -34, -34, -34, -34, -19, -34, -31, -32, -34, -16,
118
- -9, -10, -11, -7, -12, -8, -13, -5, -14, -6,
119
- -15, -18, -30, -34, -33 ]
116
+ -2, -35, -1, -35, -20, -21, -22, -23, -4, -35,
117
+ -24, -17, -30, -25, -26, -27, -35, -28, -29, -35,
118
+ 56, -35, -35, -35, -35, -3, -35, -35, -35, -35,
119
+ -35, -35, -35, -35, -35, -19, -35, -32, -33, -35,
120
+ -16, -9, -10, -11, -7, -12, -8, -13, -5, -14,
121
+ -6, -15, -18, -35, -31, -34 ]
120
122
 
121
123
  racc_goto_table = [
122
- 7, 1, 2, 38, nil, nil, nil, nil, nil, nil,
123
- nil, nil, nil, nil, 34, nil, 35, nil, 37, 39,
124
- 40, 41, nil, 42, 43, 44, 45, 46, 47, 48,
125
- 49, 50, nil, nil, nil, nil, nil, nil, nil, nil,
124
+ 9, 1, 2, 39, nil, nil, nil, nil, nil, nil,
125
+ nil, nil, nil, nil, 35, nil, nil, 36, nil, 38,
126
+ 40, 41, 42, nil, 43, 44, 45, 46, 47, 48,
127
+ 49, 50, 51, nil, nil, nil, nil, nil, nil, nil,
126
128
  nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
127
- nil, 54 ]
129
+ nil, 55 ]
128
130
 
129
131
  racc_goto_check = [
130
132
  3, 1, 2, 6, nil, nil, nil, nil, nil, nil,
131
- nil, nil, nil, nil, 3, nil, 3, nil, 3, 3,
132
- 3, 3, nil, 3, 3, 3, 3, 3, 3, 3,
133
- 3, 3, nil, nil, nil, nil, nil, nil, nil, nil,
133
+ nil, nil, nil, nil, 3, nil, nil, 3, nil, 3,
134
+ 3, 3, 3, nil, 3, 3, 3, 3, 3, 3,
135
+ 3, 3, 3, nil, nil, nil, nil, nil, nil, nil,
134
136
  nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
135
137
  nil, 3 ]
136
138
 
137
139
  racc_goto_pointer = [
138
- nil, 1, 2, -2, nil, nil, -17 ]
140
+ nil, 1, 2, -2, nil, nil, -18 ]
139
141
 
140
142
  racc_goto_default = [
141
- nil, nil, nil, nil, 9, 11, nil ]
143
+ nil, nil, nil, nil, 11, 12, nil ]
142
144
 
143
145
  racc_reduce_table = [
144
146
  0, 0, :racc_error,
145
- 1, 34, :_reduce_none,
146
- 0, 35, :_reduce_2,
147
- 3, 35, :_reduce_3,
148
- 2, 35, :_reduce_none,
149
- 3, 36, :_reduce_5,
150
- 3, 36, :_reduce_6,
151
- 3, 36, :_reduce_7,
152
- 3, 36, :_reduce_8,
153
- 3, 36, :_reduce_9,
154
- 3, 36, :_reduce_10,
155
- 3, 36, :_reduce_11,
156
- 3, 36, :_reduce_12,
157
- 3, 36, :_reduce_13,
158
- 3, 36, :_reduce_14,
159
- 3, 36, :_reduce_15,
160
- 3, 36, :_reduce_16,
161
- 1, 36, :_reduce_none,
162
- 3, 37, :_reduce_18,
163
- 2, 37, :_reduce_19,
147
+ 1, 35, :_reduce_none,
148
+ 0, 36, :_reduce_2,
149
+ 3, 36, :_reduce_3,
150
+ 2, 36, :_reduce_none,
151
+ 3, 37, :_reduce_5,
152
+ 3, 37, :_reduce_6,
153
+ 3, 37, :_reduce_7,
154
+ 3, 37, :_reduce_8,
155
+ 3, 37, :_reduce_9,
156
+ 3, 37, :_reduce_10,
157
+ 3, 37, :_reduce_11,
158
+ 3, 37, :_reduce_12,
159
+ 3, 37, :_reduce_13,
160
+ 3, 37, :_reduce_14,
161
+ 3, 37, :_reduce_15,
162
+ 3, 37, :_reduce_16,
164
163
  1, 37, :_reduce_none,
165
- 1, 37, :_reduce_21,
166
- 1, 37, :_reduce_22,
167
- 1, 37, :_reduce_23,
168
- 1, 37, :_reduce_24,
169
- 1, 37, :_reduce_25,
170
- 1, 37, :_reduce_26,
171
- 1, 37, :_reduce_27,
172
- 1, 37, :_reduce_28,
173
- 1, 37, :_reduce_none,
174
- 4, 38, :_reduce_30,
175
- 3, 38, :_reduce_31,
176
- 1, 39, :_reduce_32,
177
- 3, 39, :_reduce_33 ]
178
-
179
- racc_reduce_n = 34
180
-
181
- racc_shift_n = 55
164
+ 3, 38, :_reduce_18,
165
+ 2, 38, :_reduce_19,
166
+ 1, 38, :_reduce_none,
167
+ 1, 38, :_reduce_21,
168
+ 1, 38, :_reduce_22,
169
+ 1, 38, :_reduce_23,
170
+ 1, 38, :_reduce_24,
171
+ 1, 38, :_reduce_25,
172
+ 1, 38, :_reduce_26,
173
+ 1, 38, :_reduce_27,
174
+ 1, 38, :_reduce_28,
175
+ 1, 38, :_reduce_29,
176
+ 1, 38, :_reduce_none,
177
+ 4, 39, :_reduce_31,
178
+ 3, 39, :_reduce_32,
179
+ 1, 40, :_reduce_33,
180
+ 3, 40, :_reduce_34 ]
181
+
182
+ racc_reduce_n = 35
183
+
184
+ racc_shift_n = 56
182
185
 
183
186
  racc_token_table = {
184
187
  false => 0,
@@ -211,11 +214,12 @@ racc_token_table = {
211
214
  :REF3D => 27,
212
215
  :RANGE2D => 28,
213
216
  :RANGE3D => 29,
214
- :TRUE => 30,
215
- :FALSE => 31,
216
- "," => 32 }
217
+ :NAME => 30,
218
+ :TRUE => 31,
219
+ :FALSE => 32,
220
+ "," => 33 }
217
221
 
218
- racc_nt_base = 33
222
+ racc_nt_base = 34
219
223
 
220
224
  racc_use_result_var = true
221
225
 
@@ -266,6 +270,7 @@ Racc_token_to_s_table = [
266
270
  "REF3D",
267
271
  "RANGE2D",
268
272
  "RANGE3D",
273
+ "NAME",
269
274
  "TRUE",
270
275
  "FALSE",
271
276
  "\",\"",
@@ -287,14 +292,14 @@ Racc_debug_parser = false
287
292
 
288
293
  module_eval(<<'.,.,', 'excelformula.y', 20)
289
294
  def _reduce_2(val, _values, result)
290
- result = []
295
+ result = []
291
296
  result
292
297
  end
293
298
  .,.,
294
299
 
295
300
  module_eval(<<'.,.,', 'excelformula.y', 21)
296
301
  def _reduce_3(val, _values, result)
297
- result.push val[1], '_arg', '1'
302
+ result.push val[1], '_arg', '1'
298
303
  result
299
304
  end
300
305
  .,.,
@@ -303,84 +308,84 @@ module_eval(<<'.,.,', 'excelformula.y', 21)
303
308
 
304
309
  module_eval(<<'.,.,', 'excelformula.y', 24)
305
310
  def _reduce_5(val, _values, result)
306
- result = [ val[0], val[2], 'ptgAdd' ]
311
+ result = [ val[0], val[2], 'ptgAdd' ]
307
312
  result
308
313
  end
309
314
  .,.,
310
315
 
311
316
  module_eval(<<'.,.,', 'excelformula.y', 25)
312
317
  def _reduce_6(val, _values, result)
313
- result = [ val[0], val[2], 'ptgSub' ]
318
+ result = [ val[0], val[2], 'ptgSub' ]
314
319
  result
315
320
  end
316
321
  .,.,
317
322
 
318
323
  module_eval(<<'.,.,', 'excelformula.y', 26)
319
324
  def _reduce_7(val, _values, result)
320
- result = [ val[0], val[2], 'ptgMul' ]
325
+ result = [ val[0], val[2], 'ptgMul' ]
321
326
  result
322
327
  end
323
328
  .,.,
324
329
 
325
330
  module_eval(<<'.,.,', 'excelformula.y', 27)
326
331
  def _reduce_8(val, _values, result)
327
- result = [ val[0], val[2], 'ptgDiv' ]
332
+ result = [ val[0], val[2], 'ptgDiv' ]
328
333
  result
329
334
  end
330
335
  .,.,
331
336
 
332
337
  module_eval(<<'.,.,', 'excelformula.y', 28)
333
338
  def _reduce_9(val, _values, result)
334
- result = [ val[0], val[2], 'ptgPower' ]
339
+ result = [ val[0], val[2], 'ptgPower' ]
335
340
  result
336
341
  end
337
342
  .,.,
338
343
 
339
344
  module_eval(<<'.,.,', 'excelformula.y', 29)
340
345
  def _reduce_10(val, _values, result)
341
- result = [ val[0], val[2], 'ptgConcat' ]
346
+ result = [ val[0], val[2], 'ptgConcat' ]
342
347
  result
343
348
  end
344
349
  .,.,
345
350
 
346
351
  module_eval(<<'.,.,', 'excelformula.y', 30)
347
352
  def _reduce_11(val, _values, result)
348
- result = [ val[0], val[2], 'ptgLT' ]
353
+ result = [ val[0], val[2], 'ptgLT' ]
349
354
  result
350
355
  end
351
356
  .,.,
352
357
 
353
358
  module_eval(<<'.,.,', 'excelformula.y', 31)
354
359
  def _reduce_12(val, _values, result)
355
- result = [ val[0], val[2], 'ptgGT' ]
360
+ result = [ val[0], val[2], 'ptgGT' ]
356
361
  result
357
362
  end
358
363
  .,.,
359
364
 
360
365
  module_eval(<<'.,.,', 'excelformula.y', 32)
361
366
  def _reduce_13(val, _values, result)
362
- result = [ val[0], val[2], 'ptgLE' ]
367
+ result = [ val[0], val[2], 'ptgLE' ]
363
368
  result
364
369
  end
365
370
  .,.,
366
371
 
367
372
  module_eval(<<'.,.,', 'excelformula.y', 33)
368
373
  def _reduce_14(val, _values, result)
369
- result = [ val[0], val[2], 'ptgGE' ]
374
+ result = [ val[0], val[2], 'ptgGE' ]
370
375
  result
371
376
  end
372
377
  .,.,
373
378
 
374
379
  module_eval(<<'.,.,', 'excelformula.y', 34)
375
380
  def _reduce_15(val, _values, result)
376
- result = [ val[0], val[2], 'ptgNE' ]
381
+ result = [ val[0], val[2], 'ptgNE' ]
377
382
  result
378
383
  end
379
384
  .,.,
380
385
 
381
386
  module_eval(<<'.,.,', 'excelformula.y', 35)
382
387
  def _reduce_16(val, _values, result)
383
- result = [ val[0], val[2], 'ptgEQ' ]
388
+ result = [ val[0], val[2], 'ptgEQ' ]
384
389
  result
385
390
  end
386
391
  .,.,
@@ -389,14 +394,14 @@ module_eval(<<'.,.,', 'excelformula.y', 35)
389
394
 
390
395
  module_eval(<<'.,.,', 'excelformula.y', 38)
391
396
  def _reduce_18(val, _values, result)
392
- result = [ val[1], '_arg', '1', 'ptgParen']
397
+ result = [ val[1], '_arg', '1', 'ptgParen']
393
398
  result
394
399
  end
395
400
  .,.,
396
401
 
397
402
  module_eval(<<'.,.,', 'excelformula.y', 39)
398
403
  def _reduce_19(val, _values, result)
399
- result = [ '_num', '-1', val[1], 'ptgMul' ]
404
+ result = [ '_num', '-1', val[1], 'ptgMul' ]
400
405
  result
401
406
  end
402
407
  .,.,
@@ -405,100 +410,108 @@ module_eval(<<'.,.,', 'excelformula.y', 39)
405
410
 
406
411
  module_eval(<<'.,.,', 'excelformula.y', 41)
407
412
  def _reduce_21(val, _values, result)
408
- result = [ '_num', val[0] ]
413
+ result = [ '_num', val[0] ]
409
414
  result
410
415
  end
411
416
  .,.,
412
417
 
413
418
  module_eval(<<'.,.,', 'excelformula.y', 42)
414
419
  def _reduce_22(val, _values, result)
415
- result = [ '_str', val[0] ]
420
+ result = [ '_str', val[0] ]
416
421
  result
417
422
  end
418
423
  .,.,
419
424
 
420
425
  module_eval(<<'.,.,', 'excelformula.y', 43)
421
426
  def _reduce_23(val, _values, result)
422
- result = [ '_ref2d', val[0] ]
427
+ result = [ '_ref2d', val[0] ]
423
428
  result
424
429
  end
425
430
  .,.,
426
431
 
427
432
  module_eval(<<'.,.,', 'excelformula.y', 44)
428
433
  def _reduce_24(val, _values, result)
429
- result = [ '_ref3d', val[0] ]
434
+ result = [ '_ref3d', val[0] ]
430
435
  result
431
436
  end
432
437
  .,.,
433
438
 
434
439
  module_eval(<<'.,.,', 'excelformula.y', 45)
435
440
  def _reduce_25(val, _values, result)
436
- result = [ '_range2d', val[0] ]
441
+ result = [ '_range2d', val[0] ]
437
442
  result
438
443
  end
439
444
  .,.,
440
445
 
441
446
  module_eval(<<'.,.,', 'excelformula.y', 46)
442
447
  def _reduce_26(val, _values, result)
443
- result = [ '_range3d', val[0] ]
448
+ result = [ '_range3d', val[0] ]
444
449
  result
445
450
  end
446
451
  .,.,
447
452
 
448
453
  module_eval(<<'.,.,', 'excelformula.y', 47)
449
454
  def _reduce_27(val, _values, result)
450
- result = [ 'ptgBool', '1' ]
455
+ result = [ '_name', val[0] ]
451
456
  result
452
457
  end
453
458
  .,.,
454
459
 
455
460
  module_eval(<<'.,.,', 'excelformula.y', 48)
456
461
  def _reduce_28(val, _values, result)
457
- result = [ 'ptgBool', '0' ]
462
+ result = [ 'ptgBool', '1' ]
458
463
  result
459
464
  end
460
465
  .,.,
461
466
 
462
- # reduce 29 omitted
463
-
464
- module_eval(<<'.,.,', 'excelformula.y', 51)
465
- def _reduce_30(val, _values, result)
466
- result = [ '_class', val[0], val[2], '_arg', val[2].size.to_s, '_func', val[0] ]
467
+ module_eval(<<'.,.,', 'excelformula.y', 49)
468
+ def _reduce_29(val, _values, result)
469
+ result = [ 'ptgBool', '0' ]
467
470
  result
468
471
  end
469
472
  .,.,
470
473
 
474
+ # reduce 30 omitted
475
+
471
476
  module_eval(<<'.,.,', 'excelformula.y', 52)
472
477
  def _reduce_31(val, _values, result)
473
- result = [ '_func', val[0] ]
478
+ result = [ '_class', val[0], val[2], '_arg', val[2].size.to_s, '_func', val[0] ]
474
479
  result
475
480
  end
476
481
  .,.,
477
482
 
478
- module_eval(<<'.,.,', 'excelformula.y', 54)
483
+ module_eval(<<'.,.,', 'excelformula.y', 53)
479
484
  def _reduce_32(val, _values, result)
480
- result = val
485
+ result = [ '_func', val[0] ]
481
486
  result
482
487
  end
483
488
  .,.,
484
489
 
485
490
  module_eval(<<'.,.,', 'excelformula.y', 55)
486
491
  def _reduce_33(val, _values, result)
487
- result.push val[2]
492
+ result = val
488
493
  result
489
494
  end
490
495
  .,.,
491
496
 
492
- def _reduce_none(val, _values, result)
493
- val[0]
494
- end
497
+ module_eval(<<'.,.,', 'excelformula.y', 56)
498
+ def _reduce_34(val, _values, result)
499
+ result.push val[2]
500
+ result
501
+ end
502
+ .,.,
503
+
504
+ def _reduce_none(val, _values, result)
505
+ val[0]
506
+ end
495
507
 
496
508
  end # class ExcelFormulaParser
497
509
 
498
510
 
499
- class ExcelFormulaParserError < StandardError; end
511
+ class ExcelFormulaParserError < StandardError #:nodoc:
512
+ end
500
513
 
501
- class Node
514
+ class Node # :nodoc:
502
515
 
503
516
  def exec_list(nodes)
504
517
  v = nil
@@ -513,7 +526,7 @@ class Node
513
526
 
514
527
  end
515
528
 
516
- class RootNode < Node
529
+ class RootNode < Node # :nodoc:
517
530
 
518
531
  def initialize(tree)
519
532
  @tree = tree
@@ -526,7 +539,7 @@ class RootNode < Node
526
539
  end
527
540
 
528
541
 
529
- class FuncallNode < Node
542
+ class FuncallNode < Node # :nodoc:
530
543
 
531
544
  def initialize(func, args)
532
545
  @func = func
@@ -543,7 +556,7 @@ class FuncallNode < Node
543
556
 
544
557
  end
545
558
 
546
- class NumberNode < Node
559
+ class NumberNode < Node # :nodoc:
547
560
 
548
561
  def initialize(val)
549
562
  @val = val
@@ -555,7 +568,7 @@ class NumberNode < Node
555
568
 
556
569
  end
557
570
 
558
- class OperateNode < Node
571
+ class OperateNode < Node # :nodoc:
559
572
 
560
573
  def initialize(op, left, right)
561
574
  @op = op