| 7 | ) |
| 8 | |
| 9 | type AstNumber struct { |
| 10 | Source RegoSource |
| 11 | // Value is intentionally vague as to if it's an integer or a float. |
| 12 | // This defers that decision to the user. Rego keeps all numbers in this |
| 13 | // type. If we were to source the type from something other than Rego, |
| 14 | // we might want to make a Float and Int type which keep the original |
| 15 | // precision. |
| 16 | Value json.Number |
| 17 | } |
| 18 | |
| 19 | func Number(source RegoSource, v json.Number) Node { |
| 20 | return AstNumber{Value: v, Source: source} |
nothing calls this directly
no outgoing calls
no test coverage detected