diff options
| author | Ingo Lohmar | 2021-05-27 22:52:11 +0200 |
|---|---|---|
| committer | Ingo Lohmar | 2021-05-27 22:54:40 +0200 |
| commit | a29a03c3bc8f16ab49fbc192567c1ee8428f34ea (patch) | |
| tree | 2e8de95ff9dbb5e2e1f74ba91b55f3a9ce62d1fa /lisp/progmodes/sql.el | |
| parent | f1c3b82d401eecd1facbe0a6c07ccde100ad65d8 (diff) | |
| download | emacs-a29a03c3bc8f16ab49fbc192567c1ee8428f34ea.tar.gz emacs-a29a03c3bc8f16ab49fbc192567c1ee8428f34ea.zip | |
* lisp/progmodes/sql.el: Turn `sql-*-statement-starters' to defvars.
These variables hold information on the SQL standard and
product-specific additions and should not be user-customizable.
Diffstat (limited to 'lisp/progmodes/sql.el')
| -rw-r--r-- | lisp/progmodes/sql.el | 47 |
1 files changed, 20 insertions, 27 deletions
diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index 2bfb222182d..f144549cf6d 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el | |||
| @@ -998,20 +998,6 @@ for the first time." | |||
| 998 | :version "24.1" | 998 | :version "24.1" |
| 999 | :type 'hook) | 999 | :type 'hook) |
| 1000 | 1000 | ||
| 1001 | ;; Customization for ANSI | ||
| 1002 | |||
| 1003 | (defcustom sql-ansi-statement-starters | ||
| 1004 | (regexp-opt '("create" "alter" "drop" | ||
| 1005 | "select" "insert" "update" "delete" "merge" | ||
| 1006 | "grant" "revoke")) | ||
| 1007 | "Regexp of keywords that start SQL commands. | ||
| 1008 | |||
| 1009 | All products share this list; products should define a regexp to | ||
| 1010 | identify additional keywords in a variable defined by | ||
| 1011 | the :statement feature." | ||
| 1012 | :version "24.1" | ||
| 1013 | :type 'regexp) | ||
| 1014 | |||
| 1015 | ;; Customization for Oracle | 1001 | ;; Customization for Oracle |
| 1016 | 1002 | ||
| 1017 | (defcustom sql-oracle-program "sqlplus" | 1003 | (defcustom sql-oracle-program "sqlplus" |
| @@ -1034,12 +1020,6 @@ You will find the file in your Orant\\bin directory." | |||
| 1034 | :type 'sql-login-params | 1020 | :type 'sql-login-params |
| 1035 | :version "24.1") | 1021 | :version "24.1") |
| 1036 | 1022 | ||
| 1037 | (defcustom sql-oracle-statement-starters | ||
| 1038 | (regexp-opt '("declare" "begin" "with")) | ||
| 1039 | "Additional statement starting keywords in Oracle." | ||
| 1040 | :version "24.1" | ||
| 1041 | :type 'string) | ||
| 1042 | |||
| 1043 | (defcustom sql-oracle-scan-on t | 1023 | (defcustom sql-oracle-scan-on t |
| 1044 | "Non-nil if placeholders should be replaced in Oracle SQLi. | 1024 | "Non-nil if placeholders should be replaced in Oracle SQLi. |
| 1045 | 1025 | ||
| @@ -1240,13 +1220,6 @@ add your name with a \"-U\" prefix (such as \"-Umark\") to the list." | |||
| 1240 | (push (match-string 1 row) res)))) | 1220 | (push (match-string 1 row) res)))) |
| 1241 | (nreverse res)))) | 1221 | (nreverse res)))) |
| 1242 | 1222 | ||
| 1243 | (defcustom sql-postgres-statement-starters | ||
| 1244 | (regexp-opt '("with")) | ||
| 1245 | "Additional statement-starting keywords in Postgres." | ||
| 1246 | :type 'string | ||
| 1247 | :group 'SQL | ||
| 1248 | :version "28.1") | ||
| 1249 | |||
| 1250 | ;; Customization for Interbase | 1223 | ;; Customization for Interbase |
| 1251 | 1224 | ||
| 1252 | (defcustom sql-interbase-program "isql" | 1225 | (defcustom sql-interbase-program "isql" |
| @@ -1510,6 +1483,26 @@ Based on `comint-mode-map'.") | |||
| 1510 | table) | 1483 | table) |
| 1511 | "Syntax table used in `sql-mode' and `sql-interactive-mode'.") | 1484 | "Syntax table used in `sql-mode' and `sql-interactive-mode'.") |
| 1512 | 1485 | ||
| 1486 | ;; Motion Function Keywords | ||
| 1487 | |||
| 1488 | (defvar sql-ansi-statement-starters | ||
| 1489 | (regexp-opt '("create" "alter" "drop" | ||
| 1490 | "select" "insert" "update" "delete" "merge" | ||
| 1491 | "grant" "revoke")) | ||
| 1492 | "Regexp of keywords that start SQL commands. | ||
| 1493 | |||
| 1494 | All products share this list; products should define a regexp to | ||
| 1495 | identify additional keywords in a variable defined by | ||
| 1496 | the :statement feature.") | ||
| 1497 | |||
| 1498 | (defvar sql-oracle-statement-starters | ||
| 1499 | (regexp-opt '("declare" "begin" "with")) | ||
| 1500 | "Additional statement-starting keywords in Oracle.") | ||
| 1501 | |||
| 1502 | (defvar sql-postgres-statement-starters | ||
| 1503 | (regexp-opt '("with")) | ||
| 1504 | "Additional statement-starting keywords in Postgres.") | ||
| 1505 | |||
| 1513 | ;; Font lock support | 1506 | ;; Font lock support |
| 1514 | 1507 | ||
| 1515 | (defvar sql-mode-font-lock-object-name | 1508 | (defvar sql-mode-font-lock-object-name |