lib/formulae/parse/formula_peg.txt in rubyfromexcel-0.0.17 vs lib/formulae/parse/formula_peg.txt in rubyfromexcel-0.0.18
- old
+ new
@@ -15,17 +15,17 @@
number := /[-+]?[0-9]+\.?[0-9]*([eE][-+]?[0-9]+)?/
operator := '+' | '-' | '/' | '*' | '^'
external_reference := /\[\d+\]!?/ any_internal_reference
table_reference := table_name `'[' (range_structured_reference | complex_structured_reference | simple_structured_reference) `']'
local_table_reference := `'[' (range_structured_reference | complex_structured_reference | overly_structured_reference | simple_structured_reference) `']'
-table_name = /[.a-zA-Z0-9_]+/
+table_name = /[.\p{Word}]+/
range_structured_reference = /\[[^\u005d]*\],\[[^\u005d]*\]:\[[^\u005d]*\]/
complex_structured_reference = /\[[^\u005d]*\],\[[^\u005d]*\]/
overly_structured_reference = `'[' simple_structured_reference `']'
simple_structured_reference = /[^\u005d]*/
-named_reference := /[#a-zA-Z][\w_.!]+/
+named_reference := /[\p{Word}#][\p{Word}.!]*/
quoted_sheet_reference := single_quoted_string `'!' (sheetless_reference | named_reference)
-sheet_reference := /[a-zA-Z0-9][\w_.]+/ `'!' (sheetless_reference | named_reference)
+sheet_reference := /[\p{Word}][\p{Word}_.]+/ `'!' (sheetless_reference | named_reference)
single_quoted_string = `"'" /[^']*/ `"'"
sheetless_reference = column_range | row_range | area | cell
column_range := column `':' column
row_range := row `':' row
area := reference `':' reference