diff options
| author | Richard M. Stallman | 1995-01-22 09:57:57 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-01-22 09:57:57 +0000 |
| commit | fcdeb5d9170830bf9fc183082debcd50abcb483a (patch) | |
| tree | 58554307c05702eddde0e1425d2c7f734dd98d1a /src/emacs.c | |
| parent | 785c4478dd45aad5ba2ce78afd616f902833c107 (diff) | |
| download | emacs-fcdeb5d9170830bf9fc183082debcd50abcb483a.tar.gz emacs-fcdeb5d9170830bf9fc183082debcd50abcb483a.zip | |
(sort_args): Ordinary args get priority 0.
So do -f, -l, -insert, etc. --kill gets negative priority.
Everything else gets positive priority.
Diffstat (limited to 'src/emacs.c')
| -rw-r--r-- | src/emacs.c | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/src/emacs.c b/src/emacs.c index 226a8e1cd76..ac3263386a5 100644 --- a/src/emacs.c +++ b/src/emacs.c | |||
| @@ -960,11 +960,6 @@ struct standard_args standard_args[] = | |||
| 960 | { "-u", "--user", 30, 1 }, | 960 | { "-u", "--user", 30, 1 }, |
| 961 | { "-user", 0, 30, 1 }, | 961 | { "-user", 0, 30, 1 }, |
| 962 | { "-debug-init", "--debug-init", 20, 0 }, | 962 | { "-debug-init", "--debug-init", 20, 0 }, |
| 963 | { "-l", "--load", 10, 1 }, | ||
| 964 | { "-load", 0, 10, 1 }, | ||
| 965 | { "-f", "--funcall", 10, 1 }, | ||
| 966 | { "-funcall", 0, 10, 1 }, | ||
| 967 | { "-insert", "--insert", 10, 1 }, | ||
| 968 | { "-bg", "--background-color", 10, 1 }, | 963 | { "-bg", "--background-color", 10, 1 }, |
| 969 | { "-background", 0, 10, 1 }, | 964 | { "-background", 0, 10, 1 }, |
| 970 | { "-fg", "--foreground-color", 10, 1 }, | 965 | { "-fg", "--foreground-color", 10, 1 }, |
| @@ -983,12 +978,19 @@ struct standard_args standard_args[] = | |||
| 983 | { "-itype", 0, 10, 1 }, | 978 | { "-itype", 0, 10, 1 }, |
| 984 | { "-name", "--name", 10, 1 }, | 979 | { "-name", "--name", 10, 1 }, |
| 985 | { "-xrm", "--xrm", 10, 1 }, | 980 | { "-xrm", "--xrm", 10, 1 }, |
| 986 | { "-r", "--reverse-video", 0, 0 }, | 981 | { "-r", "--reverse-video", 5, 0 }, |
| 987 | { "-rv", 0, 0, 0 }, | 982 | { "-rv", 0, 5, 0 }, |
| 988 | { "-reverse", 0, 0, 0 }, | 983 | { "-reverse", 0, 5, 0 }, |
| 989 | { "-vb", "--vertical-scroll-bars", 0, 0 }, | 984 | { "-vb", "--vertical-scroll-bars", 5, 0 }, |
| 990 | { "-iconic", "--iconic", 0, 0 }, | 985 | { "-iconic", "--iconic", 5, 0 }, |
| 991 | { "-kill", "--kill", 0, 0 }, | 986 | /* These have the same priority as ordinary file name args, |
| 987 | so they are not reordered with respect to those. */ | ||
| 988 | { "-l", "--load", 0, 1 }, | ||
| 989 | { "-load", 0, 0, 1 }, | ||
| 990 | { "-f", "--funcall", 0, 1 }, | ||
| 991 | { "-funcall", 0, 0, 1 }, | ||
| 992 | { "-insert", "--insert", 0, 1 }, | ||
| 993 | { "-kill", "--kill", -10, 0 }, | ||
| 992 | }; | 994 | }; |
| 993 | 995 | ||
| 994 | /* Reorder the elements of ARGV (assumed to have ARGC elements) | 996 | /* Reorder the elements of ARGV (assumed to have ARGC elements) |
| @@ -1018,7 +1020,7 @@ sort_args (argc, argv) | |||
| 1018 | for (from = 1; from < argc; from++) | 1020 | for (from = 1; from < argc; from++) |
| 1019 | { | 1021 | { |
| 1020 | options[from] = -1; | 1022 | options[from] = -1; |
| 1021 | priority[from] = -1; | 1023 | priority[from] = 0; |
| 1022 | if (argv[from][0] == '-') | 1024 | if (argv[from][0] == '-') |
| 1023 | { | 1025 | { |
| 1024 | int match, thislen; | 1026 | int match, thislen; |