hayadentaku 3.5.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (132) hide show
  1. checksums.yaml +7 -0
  2. data/.github/workflows/rspec.yml +26 -0
  3. data/.github/workflows/rubocop.yml +14 -0
  4. data/.gitignore +14 -0
  5. data/.pryrc +2 -0
  6. data/.rubocop.yml +114 -0
  7. data/.travis.yml +10 -0
  8. data/CHANGELOG.md +328 -0
  9. data/Gemfile +4 -0
  10. data/LICENSE +21 -0
  11. data/README.md +352 -0
  12. data/Rakefile +31 -0
  13. data/hayadentaku.gemspec +35 -0
  14. data/lib/dentaku/ast/access.rb +44 -0
  15. data/lib/dentaku/ast/arithmetic.rb +292 -0
  16. data/lib/dentaku/ast/array.rb +38 -0
  17. data/lib/dentaku/ast/bitwise.rb +42 -0
  18. data/lib/dentaku/ast/case/case_conditional.rb +38 -0
  19. data/lib/dentaku/ast/case/case_else.rb +35 -0
  20. data/lib/dentaku/ast/case/case_switch_variable.rb +35 -0
  21. data/lib/dentaku/ast/case/case_then.rb +35 -0
  22. data/lib/dentaku/ast/case/case_when.rb +39 -0
  23. data/lib/dentaku/ast/case.rb +93 -0
  24. data/lib/dentaku/ast/combinators.rb +50 -0
  25. data/lib/dentaku/ast/comparators.rb +88 -0
  26. data/lib/dentaku/ast/datetime.rb +8 -0
  27. data/lib/dentaku/ast/function.rb +56 -0
  28. data/lib/dentaku/ast/function_registry.rb +107 -0
  29. data/lib/dentaku/ast/functions/abs.rb +5 -0
  30. data/lib/dentaku/ast/functions/all.rb +19 -0
  31. data/lib/dentaku/ast/functions/and.rb +25 -0
  32. data/lib/dentaku/ast/functions/any.rb +19 -0
  33. data/lib/dentaku/ast/functions/avg.rb +13 -0
  34. data/lib/dentaku/ast/functions/count.rb +26 -0
  35. data/lib/dentaku/ast/functions/duration.rb +51 -0
  36. data/lib/dentaku/ast/functions/enum.rb +54 -0
  37. data/lib/dentaku/ast/functions/filter.rb +21 -0
  38. data/lib/dentaku/ast/functions/if.rb +47 -0
  39. data/lib/dentaku/ast/functions/intercept.rb +33 -0
  40. data/lib/dentaku/ast/functions/map.rb +19 -0
  41. data/lib/dentaku/ast/functions/max.rb +5 -0
  42. data/lib/dentaku/ast/functions/min.rb +5 -0
  43. data/lib/dentaku/ast/functions/mul.rb +12 -0
  44. data/lib/dentaku/ast/functions/not.rb +5 -0
  45. data/lib/dentaku/ast/functions/or.rb +25 -0
  46. data/lib/dentaku/ast/functions/pluck.rb +34 -0
  47. data/lib/dentaku/ast/functions/reduce.rb +60 -0
  48. data/lib/dentaku/ast/functions/round.rb +5 -0
  49. data/lib/dentaku/ast/functions/rounddown.rb +8 -0
  50. data/lib/dentaku/ast/functions/roundup.rb +8 -0
  51. data/lib/dentaku/ast/functions/ruby_math.rb +57 -0
  52. data/lib/dentaku/ast/functions/string_functions.rb +212 -0
  53. data/lib/dentaku/ast/functions/sum.rb +12 -0
  54. data/lib/dentaku/ast/functions/switch.rb +8 -0
  55. data/lib/dentaku/ast/functions/xor.rb +44 -0
  56. data/lib/dentaku/ast/grouping.rb +23 -0
  57. data/lib/dentaku/ast/identifier.rb +52 -0
  58. data/lib/dentaku/ast/literal.rb +30 -0
  59. data/lib/dentaku/ast/logical.rb +8 -0
  60. data/lib/dentaku/ast/negation.rb +54 -0
  61. data/lib/dentaku/ast/nil.rb +13 -0
  62. data/lib/dentaku/ast/node.rb +29 -0
  63. data/lib/dentaku/ast/numeric.rb +8 -0
  64. data/lib/dentaku/ast/operation.rb +44 -0
  65. data/lib/dentaku/ast/string.rb +15 -0
  66. data/lib/dentaku/ast.rb +42 -0
  67. data/lib/dentaku/bulk_expression_solver.rb +158 -0
  68. data/lib/dentaku/calculator.rb +192 -0
  69. data/lib/dentaku/date_arithmetic.rb +60 -0
  70. data/lib/dentaku/dependency_resolver.rb +29 -0
  71. data/lib/dentaku/exceptions.rb +116 -0
  72. data/lib/dentaku/flat_hash.rb +161 -0
  73. data/lib/dentaku/parser.rb +318 -0
  74. data/lib/dentaku/print_visitor.rb +112 -0
  75. data/lib/dentaku/string_casing.rb +7 -0
  76. data/lib/dentaku/token.rb +48 -0
  77. data/lib/dentaku/token_matcher.rb +138 -0
  78. data/lib/dentaku/token_matchers.rb +29 -0
  79. data/lib/dentaku/token_scanner.rb +240 -0
  80. data/lib/dentaku/tokenizer.rb +127 -0
  81. data/lib/dentaku/version.rb +3 -0
  82. data/lib/dentaku/visitor/infix.rb +86 -0
  83. data/lib/dentaku.rb +69 -0
  84. data/spec/ast/abs_spec.rb +26 -0
  85. data/spec/ast/addition_spec.rb +67 -0
  86. data/spec/ast/all_spec.rb +38 -0
  87. data/spec/ast/and_function_spec.rb +35 -0
  88. data/spec/ast/and_spec.rb +32 -0
  89. data/spec/ast/any_spec.rb +36 -0
  90. data/spec/ast/arithmetic_spec.rb +147 -0
  91. data/spec/ast/avg_spec.rb +42 -0
  92. data/spec/ast/case_spec.rb +84 -0
  93. data/spec/ast/comparator_spec.rb +87 -0
  94. data/spec/ast/count_spec.rb +40 -0
  95. data/spec/ast/division_spec.rb +64 -0
  96. data/spec/ast/filter_spec.rb +25 -0
  97. data/spec/ast/function_spec.rb +69 -0
  98. data/spec/ast/intercept_spec.rb +30 -0
  99. data/spec/ast/map_spec.rb +40 -0
  100. data/spec/ast/max_spec.rb +33 -0
  101. data/spec/ast/min_spec.rb +33 -0
  102. data/spec/ast/mul_spec.rb +43 -0
  103. data/spec/ast/negation_spec.rb +48 -0
  104. data/spec/ast/node_spec.rb +43 -0
  105. data/spec/ast/numeric_spec.rb +16 -0
  106. data/spec/ast/or_spec.rb +35 -0
  107. data/spec/ast/pluck_spec.rb +49 -0
  108. data/spec/ast/reduce_spec.rb +22 -0
  109. data/spec/ast/round_spec.rb +35 -0
  110. data/spec/ast/rounddown_spec.rb +35 -0
  111. data/spec/ast/roundup_spec.rb +35 -0
  112. data/spec/ast/string_functions_spec.rb +217 -0
  113. data/spec/ast/sum_spec.rb +43 -0
  114. data/spec/ast/switch_spec.rb +30 -0
  115. data/spec/ast/xor_spec.rb +35 -0
  116. data/spec/benchmark.rb +70 -0
  117. data/spec/bulk_expression_solver_spec.rb +241 -0
  118. data/spec/calculator_spec.rb +1003 -0
  119. data/spec/dentaku_spec.rb +52 -0
  120. data/spec/dependency_resolver_spec.rb +18 -0
  121. data/spec/exceptions_spec.rb +9 -0
  122. data/spec/external_function_spec.rb +177 -0
  123. data/spec/parser_spec.rb +183 -0
  124. data/spec/print_visitor_spec.rb +77 -0
  125. data/spec/spec_helper.rb +69 -0
  126. data/spec/token_matcher_spec.rb +134 -0
  127. data/spec/token_scanner_spec.rb +49 -0
  128. data/spec/token_spec.rb +16 -0
  129. data/spec/tokenizer_spec.rb +375 -0
  130. data/spec/visitor/infix_spec.rb +52 -0
  131. data/spec/visitor_spec.rb +139 -0
  132. metadata +353 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: bfe983880d85a1f690f3cb5eba24b4881ff1e3bdd33b6181731bc79b1417fc8a
4
+ data.tar.gz: c179876bf0ac6aae05c3e308fd34416bf55c7c50608e3fceeb9da4674a960ff7
5
+ SHA512:
6
+ metadata.gz: 02abec3e5a363f3dae7f3973e9fbe1bd1f9509eacb00b9031c6f529ad201fbba078e7efe636c0244ae5d404d1f6adfec8279dcace8165aa00d122040de6c676f
7
+ data.tar.gz: 457169b9bf33f11485b389f215cb0d743ad205dc10ee87f3c072feae6ddbb9c7cf659af52c8e58c630e7ba2bf419c2c385b0196d9573708406eea44c9a76d748
@@ -0,0 +1,26 @@
1
+ name: rspec
2
+ on:
3
+ push:
4
+ pull_request:
5
+ jobs:
6
+ rspec:
7
+ runs-on: ubuntu-latest
8
+ strategy:
9
+ matrix:
10
+ ruby:
11
+ - '2.5'
12
+ - '2.6'
13
+ - '2.7'
14
+ - '3.0'
15
+ - '3.1'
16
+ - '3.2'
17
+ - '3.3'
18
+ - '3.4'
19
+ fail-fast: false
20
+ steps:
21
+ - uses: actions/checkout@v4
22
+ - uses: ruby/setup-ruby@v1
23
+ with:
24
+ ruby-version: "${{ matrix.ruby }}"
25
+ bundler-cache: true
26
+ - run: bundle exec rspec --format documentation
@@ -0,0 +1,14 @@
1
+ name: rubocop
2
+ on:
3
+ push:
4
+ pull_request:
5
+ jobs:
6
+ rubocop:
7
+ runs-on: ubuntu-latest
8
+ steps:
9
+ - uses: actions/checkout@v4
10
+ - uses: ruby/setup-ruby@v1
11
+ with:
12
+ ruby-version: '3'
13
+ bundler-cache: true
14
+ - run: bundle exec rubocop
data/.gitignore ADDED
@@ -0,0 +1,14 @@
1
+ *.gem
2
+ .bundle
3
+ .rbenv-version
4
+ Gemfile.lock
5
+ bin/*
6
+ pkg/*
7
+ vendor/*
8
+
9
+ /.ruby-gemset
10
+ /.ruby-version
11
+ /.rspec
12
+
13
+ .byebug_history
14
+ coverage
data/.pryrc ADDED
@@ -0,0 +1,2 @@
1
+ require "bundler"
2
+ Bundler.require
data/.rubocop.yml ADDED
@@ -0,0 +1,114 @@
1
+ AllCops:
2
+ TargetRubyVersion: 2.6
3
+ # RuboCop has a bunch of cops enabled by default. This setting tells RuboCop
4
+ # to ignore them, so only the ones explicitly set in this file are enabled.
5
+ DisabledByDefault: true
6
+
7
+ # Prefer &&/|| over and/or.
8
+ Style/AndOr:
9
+ Enabled: true
10
+
11
+ # Align `when` with `case`.
12
+ Layout/CaseIndentation:
13
+ Enabled: true
14
+
15
+ # Align comments with method definitions.
16
+ Layout/CommentIndentation:
17
+ Enabled: true
18
+
19
+ # No extra empty lines.
20
+ Layout/EmptyLines:
21
+ Enabled: true
22
+
23
+ # In a regular class definition, no empty lines around the body.
24
+ Layout/EmptyLinesAroundClassBody:
25
+ Enabled: true
26
+
27
+ # In a regular method definition, no empty lines around the body.
28
+ Layout/EmptyLinesAroundMethodBody:
29
+ Enabled: true
30
+
31
+ # In a regular module definition, no empty lines around the body.
32
+ Layout/EmptyLinesAroundModuleBody:
33
+ Enabled: true
34
+
35
+ # Use Ruby >= 1.9 syntax for hashes. Prefer { a: :b } over { :a => :b }.
36
+ Style/HashSyntax:
37
+ Enabled: true
38
+
39
+ # Method definitions after `private` or `protected` isolated calls need one
40
+ # extra level of indentation.
41
+ Layout/IndentationConsistency:
42
+ Enabled: false
43
+
44
+ # Two spaces, no tabs (for indentation).
45
+ Layout/IndentationWidth:
46
+ Enabled: true
47
+
48
+ Layout/SpaceAfterColon:
49
+ Enabled: true
50
+
51
+ Layout/SpaceAfterComma:
52
+ Enabled: true
53
+
54
+ Layout/SpaceAroundEqualsInParameterDefault:
55
+ Enabled: true
56
+
57
+ Layout/SpaceAroundKeyword:
58
+ Enabled: true
59
+
60
+ Layout/SpaceAroundOperators:
61
+ Enabled: true
62
+
63
+ Layout/SpaceBeforeFirstArg:
64
+ Enabled: true
65
+
66
+ # Defining a method with parameters needs parentheses.
67
+ Style/MethodDefParentheses:
68
+ Enabled: true
69
+
70
+ # Use `foo {}` not `foo{}`.
71
+ Layout/SpaceBeforeBlockBraces:
72
+ Enabled: true
73
+
74
+ # Use `foo { bar }` not `foo {bar}`.
75
+ Layout/SpaceInsideBlockBraces:
76
+ Enabled: true
77
+
78
+ # Use `{a: 1}` not `{ a:1 }`.
79
+ Layout/SpaceInsideHashLiteralBraces:
80
+ Enabled: false
81
+
82
+ Layout/SpaceInsideParens:
83
+ Enabled: true
84
+
85
+ # Check quotes usage according to lint rule below.
86
+ Style/StringLiterals:
87
+ Enabled: false
88
+ EnforcedStyle: double_quotes
89
+
90
+ # Detect hard tabs, no hard tabs.
91
+ Layout/IndentationStyle:
92
+ Enabled: true
93
+
94
+ # Blank lines should not have any spaces.
95
+ Layout/TrailingEmptyLines:
96
+ Enabled: true
97
+
98
+ # No trailing whitespace.
99
+ Layout/TrailingWhitespace:
100
+ Enabled: true
101
+
102
+ # Use quotes for string literals when they are enough.
103
+ Style/RedundantPercentQ:
104
+ Enabled: true
105
+
106
+ # Align `end` with the matching keyword or starting expression except for
107
+ # assignments, where it should be aligned with the LHS.
108
+ Layout/EndAlignment:
109
+ Enabled: true
110
+ EnforcedStyleAlignWith: variable
111
+
112
+ # Use my_method(my_arg) not my_method( my_arg ) or my_method my_arg.
113
+ Lint/RequireParentheses:
114
+ Enabled: true
data/.travis.yml ADDED
@@ -0,0 +1,10 @@
1
+ language: ruby
2
+ sudo: false
3
+ rvm:
4
+ - 2.5.9
5
+ - 2.6.7
6
+ - 2.7.3
7
+ - 3.0.1
8
+ before_install:
9
+ - gem update bundler
10
+ - gem update --system
data/CHANGELOG.md ADDED
@@ -0,0 +1,328 @@
1
+ # Change Log
2
+
3
+ ## [v3.5.7] 2025-12-16
4
+ - fix misclassification of unary minus as subtraction
5
+ - fix parsing empty function call
6
+
7
+ ## [v3.5.6] 2025-10-20
8
+ - fix comparison of Hash with integer
9
+ - refactor case parsing
10
+ - remove input mutation
11
+ - fix bug with arithmetic node validation
12
+
13
+ ## [v3.5.5] 2025-08-20
14
+ - fix percentages in print visitor
15
+ - repo cleanup
16
+ - fix modulo zero
17
+ - fix array arithmetic
18
+ - refactor parser
19
+
20
+ ## [v3.5.4] 2024-08-13
21
+ - add support for default value for PLUCK function
22
+ - improve error handling for MAP/ANY/ALL functions
23
+ - fix modulo / percentage operator determination
24
+ - fix string casing bug with bulk expressions
25
+ - add explicit gem dependency for BigDecimal
26
+
27
+ ## [v3.5.3] 2024-07-04
28
+ - add support for empty array literals
29
+ - add support for quoted identifiers
30
+ - add REDUCE function
31
+ - add INTERCEPT function
32
+ - improve date/time parsing an arithmetic
33
+ - improve custom class arithmetic
34
+ - fix IF dependency
35
+
36
+ ## [v3.5.2] 2023-12-06
37
+ - add ABS function
38
+ - add array support for AST visitors
39
+ - add support for function callbacks
40
+ - improve support for date / time values
41
+ - improve error messaging for invalid arity
42
+ - improve AVG function accuracy
43
+ - validate enum arguments at parse time
44
+ - support adding multiple functions at once to global registry
45
+ - fix bug in print visitor precedence checking
46
+ - fix handling of Math::DomainError
47
+ - fix invalid cast
48
+
49
+ ## [v3.5.1] 2022-10-24
50
+ - add bitwise shift left and shift right operators
51
+ - improve numeric conversions
52
+ - improve parse exceptions
53
+ - improve bitwise exceptions
54
+ - include variable name in bulk expression exceptions
55
+
56
+ ## [v3.5.0] 2022-03-17
57
+ - fix bug with function argument count
58
+ - add XOR operator
59
+ - make function args publicly accessible
60
+ - better argument handling for collection functions
61
+ - better dependency reporting for collection functions
62
+ - allow ruby math-backed functions to be serialized
63
+ - improve scientific notation handling
64
+ - improve comparator argument errors
65
+ - respect case sensitivity in nested case statments
66
+ - add visitor pattern
67
+
68
+ ## [v3.4.2] 2021-07-14
69
+ - add FILTER function
70
+ - add concurrent-ruby dependency to make global calculator object thread safe
71
+ - add Ruby 3 support
72
+ - allow formulas to access intermediate context values
73
+ - fix incorrect Ruby Math function return type
74
+ - fix context mutation bug
75
+ - fix dependency resolution bug
76
+
77
+ ## [v3.4.1] 2020-12-12
78
+ - prevent extra evaluations in bulk expression solver
79
+
80
+ ## [v3.4.0] 2020-12-07
81
+ - allow access to intermediate values of flattened hashes
82
+ - catch invalid array syntax in the parse phase
83
+ - drop support for Ruby < 2.5, add support for Ruby 2.7
84
+ - add support for subtracting date literals
85
+ - improve error handling
86
+ - improve math function implementation
87
+ - add caching for calculated variable values
88
+ - allow custom unbound variable handling block at Dentaku module level
89
+ - add enum functions `ANY`, `ALL`, `MAP` and `PLUCK`
90
+ - allow self-referential formulas in bulk expression solver
91
+ - misc internal fixes and enhancements
92
+
93
+ ## [v3.3.4] 2019-11-21
94
+ - bugfix release
95
+
96
+ ## [v3.3.3] 2019-11-20
97
+ - date / duration addition and subtraction
98
+ - validate arity for custom functions with variable arity
99
+ - make AST serializable with Marshal.dump
100
+ - performance optimization for arithmetic node validation
101
+ - support lazy evaluation for expensive values
102
+ - short-circuit IF function
103
+ - better error when empty string is used in arithmetic operation
104
+
105
+ ## [v3.3.2] 2019-06-10
106
+ - add ability to pre-load AST cache
107
+ - fix negation node bug
108
+
109
+ ## [v3.3.1] 2019-03-26
110
+ - better errors for parse failures and exceptions in internal functions
111
+ - fix Ruby 2.6.0 deprecation warnings
112
+ - fix issue with functions in nested case statements
113
+
114
+ ## [v3.3.0] 2018-12-04
115
+ - add array literal syntax
116
+ - return correct type from string function AST nodes
117
+
118
+ ## [v3.2.1] 2018-10-24
119
+ - make `evaluate` rescue more exceptions
120
+
121
+ ## [v3.2.0] 2018-03-14
122
+ - add `COUNT` and `AVG` functions
123
+ - add unicode support 😎
124
+ - fix CASE parsing bug
125
+ - allow dependency filtering based on context
126
+ - add variadic MUL function
127
+ - performance optimization
128
+
129
+ ## [v3.1.0] 2018-01-10
130
+ - allow decimals with no leading zero
131
+ - nested hash and array support in bulk expression solver
132
+ - add a variadic SUM function
133
+ - support array arguments to min, max, sum, and Math functions
134
+ - add case-sensitive variable support
135
+ - allow opt-out of nested data for performance boost
136
+
137
+ ## [v3.0.0] 2017-10-11
138
+ - add && and || as aliases for AND and OR
139
+ - add hexadecimal literal support
140
+ - add the SWITCH function
141
+ - add AND and OR functions
142
+ - add array access
143
+ - make UnboundVariableError show all missing values
144
+ - cast inputs to numeric function to numeric
145
+ - fix issue with zero-arity functions used as function args
146
+ - fix division when context values contain one or more strings
147
+ - drop Ruby 1.9 support
148
+
149
+ ## [v2.0.11] 2017-05-08
150
+ - fix dependency checking for logical AST nodes
151
+ - make `CONCAT` variadic
152
+ - fix casting strings to numeric in negation operations
153
+ - add date/time support
154
+ - add `&` (bitwise and) and `|` (bitwise or) operators
155
+ - fix incompatibility with 'mathn' module
156
+ - add `CONTAINS` string function
157
+ - allow storage of nested hashes in calculator memory
158
+ - allow duck type arithmetic
159
+ - fix error handling code to work with Ruby 2.4.0
160
+ - allow calculators to store own registry of functions
161
+ - add timezone support to time literals
162
+ - optimizations
163
+
164
+ ## [v2.0.10] 2016-12-30
165
+ - fix string function initialization bug
166
+ - fix issues with CASE statements
167
+ - allow injecting AST cache
168
+
169
+ ## [v2.0.9] 2016-09-19
170
+ - namespace tokenization errors
171
+ - automatically coerce arguments to string functions as strings
172
+ - selectively disable or clear AST cache
173
+
174
+ ## [v2.0.8] 2016-05-10
175
+ - numeric input validations
176
+ - fail with gem-specific error for invalid arithmetic operands
177
+ - add `LEFT`, `RIGHT`, `MID`, `LEN`, `FIND`, `SUBSTITUTE`, and `CONCAT` string functions
178
+
179
+ ## [v2.0.7] 2016-02-25
180
+ - fail with gem-specific error for parsing issues
181
+ - support NULL literals and nil variables
182
+ - keep reference to variable that caused failure when bulk-solving
183
+
184
+ ## [v2.0.6] 2016-01-26
185
+ - support array parameters for external functions
186
+ - support case statements
187
+ - support precision for `ROUNDUP` and `ROUNDDOWN` functions
188
+ - prevent errors from corrupting calculator memory
189
+
190
+ ## [v2.0.5] 2015-09-03
191
+ - fix bug with detecting unbound nodes
192
+ - silence warnings
193
+ - allow registration of custom token scanners
194
+
195
+ ## [v2.0.4] 2015-09-03
196
+ - fix BigDecimal conversion bug
197
+ - add caching for bulk expression solving dependency order
198
+ - allow for custom configuration for token scanners
199
+
200
+ ## [v2.0.3] 2015-08-25
201
+ - bug fixes
202
+ - performance enhancements
203
+ - code cleanup
204
+
205
+ ## [v2.0.1] 2015-08-15
206
+ - add support for boolean literals
207
+ - implement basic parse-time type checking
208
+
209
+ ## [v2.0.0] 2015-08-07
210
+ - shunting-yard parser for performance enhancement and AST generation
211
+ - AST caching for performance enhancement
212
+ - support comments in formulas
213
+ - support all functions from the Ruby Math module
214
+
215
+ ## [v1.2.6] 2015-05-30
216
+ - support custom error handlers for systems of formulas
217
+
218
+ ## [v1.2.5] 2015-05-23
219
+ - fix memory leak
220
+
221
+ ## [v1.2.2] 2014-12-19
222
+ - performance enhancements
223
+ - unary minus bug fixes
224
+ - preserve provided hash keys for systems of formulas
225
+
226
+ ## [v1.2.0] 2014-10-21
227
+ - add dependency resolution to automatically solve systems of formulas
228
+
229
+ ## [v1.1.0] 2014-07-30
230
+ - add strict evaluation mode to raise `UnboundVariableError` if not all variable values are provided
231
+ - return division results as `BigDecimal` values
232
+
233
+ ## [v1.0.0] 2014-03-06
234
+ - cleanup and 1.0 release
235
+
236
+ ## [v0.2.14] 2014-01-24
237
+ - add modulo operator
238
+ - add unary percentage operator
239
+ - support registration of custom functions at runtime
240
+
241
+ ## [v0.2.10] 2012-12-10
242
+ - return integer result for exact division, decimal otherwise
243
+
244
+ ## [v0.2.9] 2012-10-17
245
+ - add `ROUNDUP` / `ROUNDDOWN` functions
246
+
247
+ ## [v0.2.8] 2012-09-30
248
+ - make function name matching case-insensitive
249
+
250
+ ## [v0.2.7] 2012-09-26
251
+ - support passing arbitrary expressions as function arguments
252
+
253
+ ## [v0.2.6] 2012-09-19
254
+ - add `NOT` function
255
+
256
+ ## [v0.2.5] 2012-06-20
257
+ - add exponent operator
258
+ - add support for digits in variable identifiers
259
+
260
+ ## [v0.2.4] 2012-02-29
261
+ - add support for `min < x < max` syntax for inequality ranges
262
+
263
+ ## [v0.2.2] 2012-02-22
264
+ - support `ROUND` to arbitrary decimal place on older Rubies
265
+ - ensure case is preserved for string values
266
+
267
+ ## [v0.2.1] 2012-02-12
268
+ - add `ROUND` function
269
+
270
+ ## [v0.1.3] 2012-01-31
271
+ - add support for string datatype
272
+
273
+ ## [v0.1.1] 2012-01-24
274
+ - change from square bracket to parentheses for top-level evaluation
275
+ - add `IF` function
276
+
277
+ ## [v0.1.0] 2012-01-20
278
+ - initial release
279
+
280
+ [v3.5.6]: https://github.com/rubysolo/dentaku/compare/v3.5.5...v3.5.6
281
+ [v3.5.5]: https://github.com/rubysolo/dentaku/compare/v3.5.4...v3.5.5
282
+ [v3.5.4]: https://github.com/rubysolo/dentaku/compare/v3.5.3...v3.5.4
283
+ [v3.5.3]: https://github.com/rubysolo/dentaku/compare/v3.5.2...v3.5.3
284
+ [v3.5.2]: https://github.com/rubysolo/dentaku/compare/v3.5.1...v3.5.2
285
+ [v3.5.1]: https://github.com/rubysolo/dentaku/compare/v3.5.0...v3.5.1
286
+ [v3.5.0]: https://github.com/rubysolo/dentaku/compare/v3.4.2...v3.5.0
287
+ [v3.4.2]: https://github.com/rubysolo/dentaku/compare/v3.4.1...v3.4.2
288
+ [v3.4.1]: https://github.com/rubysolo/dentaku/compare/v3.4.0...v3.4.1
289
+ [v3.4.0]: https://github.com/rubysolo/dentaku/compare/v3.3.4...v3.4.0
290
+ [v3.3.4]: https://github.com/rubysolo/dentaku/compare/v3.3.3...v3.3.4
291
+ [v3.3.3]: https://github.com/rubysolo/dentaku/compare/v3.3.2...v3.3.3
292
+ [v3.3.2]: https://github.com/rubysolo/dentaku/compare/v3.3.1...v3.3.2
293
+ [v3.3.1]: https://github.com/rubysolo/dentaku/compare/v3.3.0...v3.3.1
294
+ [v3.3.0]: https://github.com/rubysolo/dentaku/compare/v3.2.1...v3.3.0
295
+ [v3.2.1]: https://github.com/rubysolo/dentaku/compare/v3.2.0...v3.2.1
296
+ [v3.2.0]: https://github.com/rubysolo/dentaku/compare/v3.1.0...v3.2.0
297
+ [v3.1.0]: https://github.com/rubysolo/dentaku/compare/v3.0.0...v3.1.0
298
+ [v3.0.0]: https://github.com/rubysolo/dentaku/compare/v2.0.11...v3.0.0
299
+ [v2.0.11]: https://github.com/rubysolo/dentaku/compare/v2.0.10...v2.0.11
300
+ [v2.0.10]: https://github.com/rubysolo/dentaku/compare/v2.0.9...v2.0.10
301
+ [v2.0.9]: https://github.com/rubysolo/dentaku/compare/v2.0.8...v2.0.9
302
+ [v2.0.8]: https://github.com/rubysolo/dentaku/compare/v2.0.7...v2.0.8
303
+ [v2.0.7]: https://github.com/rubysolo/dentaku/compare/v2.0.6...v2.0.7
304
+ [v2.0.6]: https://github.com/rubysolo/dentaku/compare/v2.0.5...v2.0.6
305
+ [v2.0.5]: https://github.com/rubysolo/dentaku/compare/v2.0.4...v2.0.5
306
+ [v2.0.4]: https://github.com/rubysolo/dentaku/compare/v2.0.3...v2.0.4
307
+ [v2.0.3]: https://github.com/rubysolo/dentaku/compare/v2.0.1...v2.0.3
308
+ [v2.0.1]: https://github.com/rubysolo/dentaku/compare/v2.0.0...v2.0.1
309
+ [v2.0.0]: https://github.com/rubysolo/dentaku/compare/v1.2.6...v2.0.0
310
+ [v1.2.6]: https://github.com/rubysolo/dentaku/compare/v1.2.5...v1.2.6
311
+ [v1.2.5]: https://github.com/rubysolo/dentaku/compare/v1.2.2...v1.2.5
312
+ [v1.2.2]: https://github.com/rubysolo/dentaku/compare/v1.2.0...v1.2.2
313
+ [v1.2.0]: https://github.com/rubysolo/dentaku/compare/v1.1.0...v1.2.0
314
+ [v1.1.0]: https://github.com/rubysolo/dentaku/compare/v1.0.0...v1.1.0
315
+ [v1.0.0]: https://github.com/rubysolo/dentaku/compare/v0.2.14...v1.0.0
316
+ [v0.2.14]: https://github.com/rubysolo/dentaku/compare/v0.2.10...v0.2.14
317
+ [v0.2.10]: https://github.com/rubysolo/dentaku/compare/v0.2.9...v0.2.10
318
+ [v0.2.9]: https://github.com/rubysolo/dentaku/compare/v0.2.8...v0.2.9
319
+ [v0.2.8]: https://github.com/rubysolo/dentaku/compare/v0.2.7...v0.2.8
320
+ [v0.2.7]: https://github.com/rubysolo/dentaku/compare/v0.2.6...v0.2.7
321
+ [v0.2.6]: https://github.com/rubysolo/dentaku/compare/v0.2.5...v0.2.6
322
+ [v0.2.5]: https://github.com/rubysolo/dentaku/compare/v0.2.4...v0.2.5
323
+ [v0.2.4]: https://github.com/rubysolo/dentaku/compare/v0.2.2...v0.2.4
324
+ [v0.2.2]: https://github.com/rubysolo/dentaku/compare/v0.2.1...v0.2.2
325
+ [v0.2.1]: https://github.com/rubysolo/dentaku/compare/v0.1.3...v0.2.1
326
+ [v0.1.3]: https://github.com/rubysolo/dentaku/compare/v0.1.1...v0.1.3
327
+ [v0.1.1]: https://github.com/rubysolo/dentaku/compare/v0.1.0...v0.1.1
328
+ [v0.1.0]: https://github.com/rubysolo/dentaku/commit/68724fd9c8fa637baf7b9d5515df0caa31e226bd
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source "http://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in hayadentaku.gemspec
4
+ gemspec
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2012 Solomon White
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.