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".
This commit is contained in:
Nikhil Benesch 2019-06-24 13:26:35 -04:00
parent cf655ad1a6
commit ac555d7e86
No known key found for this signature in database
GPG key ID: FCF98542083C5A69
17 changed files with 818 additions and 836 deletions

View file

@ -30,10 +30,10 @@ fn main() {
);
let dialect: Box<dyn Dialect> = match std::env::args().nth(2).unwrap_or_default().as_ref() {
"--ansi" => Box::new(AnsiSqlDialect {}),
"--ansi" => Box::new(AnsiDialect {}),
"--postgres" => Box::new(PostgreSqlDialect {}),
"--ms" => Box::new(MsSqlDialect {}),
"--generic" | "" => Box::new(GenericSqlDialect {}),
"--generic" | "" => Box::new(GenericDialect {}),
s => panic!("Unexpected parameter: {}", s),
};

View file

@ -12,7 +12,7 @@
#![warn(clippy::all)]
use sqlparser::dialect::GenericSqlDialect;
use sqlparser::dialect::GenericDialect;
use sqlparser::parser::*;
fn main() {
@ -21,7 +21,7 @@ fn main() {
WHERE a > b AND b < 100 \
ORDER BY a DESC, b";
let dialect = GenericSqlDialect {};
let dialect = GenericDialect {};
let ast = Parser::parse_sql(&dialect, sql.to_string()).unwrap();