Daniël Heres
2f71324c33
Fix deprecated way of initializing SimpleLogger ( #275 )
...
* Use builder pattern instead as suggested
2020-09-07 09:34:27 +02:00
eyalleshem
f500a42e99
Add snowflake dialect ( #259 )
2020-08-12 04:55:22 +03:00
Taehoon Moon
a0f076acda
Make the cli example print JSON ( #197 )
...
...via the new json_example feature - to make it easier to try out the parser without coding.
2020-06-12 16:38:59 +03:00
Daniël Heres
d32df527e6
Accept &str in Parse::parse_sql
( #182 )
...
It is more generic to accept a `&str` than a `String` in an API,
and avoids having to convert a string to a `String` when not
needed, avoiding a copy.
2020-06-03 23:31:41 +03:00
Nickolay Ponomarev
40853fe412
Fix a recently implemented clippy lint
...
https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports
"Import with single component use path such as `use cratename;`
is not necessary, and thus should be removed."
2020-05-10 21:16:25 +03:00
Nickolay Ponomarev
4ce0eb11ae
Fix a new clippy lint (.nth(0)
) to unbreak CI
...
"iter.next() is equivalent to iter.nth(0), as they both consume the
next element, but is more readable."
https://rust-lang.github.io/rust-clippy/master/index.html#iter_nth_zero
2020-04-14 17:09:48 +03:00
Nikhil Benesch
ac555d7e86
Remove "SQL" prefix from types
...
The rationale here is the same as the last commit: since this crate
exclusively parses SQL, there's no need to restate that in every type
name. (The prefix seems to be an artifact of this crate's history as a
submodule of Datafusion, where it was useful to explicitly call out
which types were related to SQL parsing.)
This commit has the additional benefit of making all type names
consistent; over type we'd added some types which were not prefixed with
"SQL".
2019-06-25 13:11:11 -04:00
Nikhil Benesch
cf655ad1a6
Remove "sql" prefix from module names
...
Since this crate only deals with SQL parsing, the modules are understood
to refer to SQL and don't need to restate that explicitly.
2019-06-24 12:56:26 -04:00
Nikhil Benesch
e78cf0483e
Standardize license headers
...
Standardize the license header, removing the Grove Enterprise copyright
notice where it exists per #58 . Also add a CI check to ensure that files
without license headers don't get merged.
Fix #58 .
2019-06-04 10:54:12 -04:00
Nickolay Ponomarev
e6f5ff2926
[example-cli] Support parsing with different dialects
2019-06-02 13:48:14 +03:00
Nickolay Ponomarev
098d1c4a17
Enable clippy lints by default in RLS
2019-04-21 04:46:19 +03:00
Nickolay Ponomarev
c223eaf0aa
Fix a bunch of trivial clippy lints
2019-04-21 04:46:19 +03:00
Nickolay Ponomarev
b12a19e197
Switch to the Rust 2018 edition
...
This requires Rust 1.31 (from last year) to build, but is otherwise
compatible with the 2015-edition code.
2019-04-21 04:41:11 +03:00
Nickolay Ponomarev
2e9da53ed3
Small CLI app that can be used to test parsing an external SQL file
2019-02-07 05:34:16 +03:00
Andy Grove
810cd8e6cf
tokenizer delegates to dialect now
2018-09-08 14:49:25 -06:00
Andy Grove
d5fd4aafaf
fix example
2018-09-08 08:51:52 -06:00
Andy Grove
06a8870bd7
Introduce concept of dialects
2018-09-08 08:39:32 -06:00
Andy Grove
7bea9a8648
cargo fmt
2018-09-03 11:45:03 -06:00
Andy Grove
87a576563b
Save
2018-09-03 10:31:04 -06:00
Andy Grove
0c23392adb
replace with code from datafusion
2018-09-03 09:56:39 -06:00
Andy Grove
a86bd30515
Refactoring
2018-09-03 09:13:43 -06:00
Andy Grove
375671e208
Refactoring
2018-09-03 08:04:20 -06:00
Andy Grove
a1696ccdb8
Refactoring
2018-09-03 07:59:05 -06:00
Andy Grove
fa2ef528b7
Refactoring
2018-09-03 07:45:48 -06:00
Andy Grove
037ebb0f73
Refactoring
2018-09-02 19:15:07 -06:00
Andy Grove
2e20b15c2e
Refactoring
2018-09-02 19:08:44 -06:00
Andy Grove
69a140a820
create Chars struct instead of using Peekable
2018-09-02 18:59:30 -06:00
Andy Grove
7ff4133327
Refactoring
2018-09-01 12:59:18 -06:00
Andy Grove
2ddc9f7a49
Refactoring
2018-09-01 08:58:00 -06:00
Andy Grove
72cff632c1
Roughing out pratt parser logic
2018-09-01 08:39:27 -06:00
Andy Grove
e6e9c8d2cc
Refactoring use of generics, added peek_token
2018-09-01 08:11:26 -06:00
Andy Grove
eed0261297
create module for ansi tokenizer/parser
2018-09-01 07:34:41 -06:00
Andy Grove
f56846098e
simple example of custom tokenizer
2018-02-09 06:53:49 -07:00
Andy Grove
fcf6b1150e
save
2018-02-09 05:58:14 -07:00