Mercurial > emacs
comparison lib-src/etags.c @ 44607:8f3420af28a8
* etags.c (get_language_from_filename): Add one argument.
(strcaseeq): New function.
(get_language_from_filename): Use it to do a case insenstitive
comparison if called with appropriate args.
(find_entries): Try with case insensitive match.
(process_file): Bug fixed.
author | Francesco Potortì <pot@gnu.org> |
---|---|
date | Mon, 15 Apr 2002 16:04:52 +0000 |
parents | 1bec0b430206 |
children | 5adf2b1c20bb |
comparison
equal
deleted
inserted
replaced
44606:e0e4003c58d9 | 44607:8f3420af28a8 |
---|---|
31 * 2001 Nested classes by Francesco Potort́ (ideas by Mykola Dzyuba). | 31 * 2001 Nested classes by Francesco Potort́ (ideas by Mykola Dzyuba). |
32 * | 32 * |
33 * Francesco Potort́ <pot@gnu.org> has maintained it since 1993. | 33 * Francesco Potort́ <pot@gnu.org> has maintained it since 1993. |
34 */ | 34 */ |
35 | 35 |
36 char pot_etags_version[] = "@(#) pot revision number is 15.10"; | 36 char pot_etags_version[] = "@(#) pot revision number is 15.13"; |
37 | 37 |
38 #define TRUE 1 | 38 #define TRUE 1 |
39 #define FALSE 0 | 39 #define FALSE 0 |
40 | 40 |
41 #ifdef DEBUG | 41 #ifdef DEBUG |
1632 /* We rewind here, even if inf may be a pipe. We fail if the | 1632 /* We rewind here, even if inf may be a pipe. We fail if the |
1633 length of the first line is longer than the pipe block size, | 1633 length of the first line is longer than the pipe block size, |
1634 which is unlikely. */ | 1634 which is unlikely. */ |
1635 if (parser == NULL) | 1635 if (parser == NULL) |
1636 rewind (inf); | 1636 rewind (inf); |
1637 #if 0 | 1637 |
1638 /* Else try to guess the language given the case insensitive file name. */ | 1638 /* Else try to guess the language given the case insensitive file name. */ |
1639 if (parser == NULL) | 1639 if (parser == NULL) |
1640 { | 1640 { |
1641 lang = get_language_from_filename (curfdp->infname, FALSE); | 1641 lang = get_language_from_filename (curfdp->infname, FALSE); |
1642 if (lang != NULL && lang->function != NULL) | 1642 if (lang != NULL && lang->function != NULL) |
1643 { | 1643 { |
1644 curfdp->lang = lang; | 1644 curfdp->lang = lang; |
1645 parser = lang->function; | 1645 parser = lang->function; |
1646 } | 1646 } |
1647 } | 1647 } |
1648 #endif | 1648 |
1649 if (!no_line_directive | 1649 if (!no_line_directive |
1650 && curfdp->lang != NULL && curfdp->lang->metasource) | 1650 && curfdp->lang != NULL && curfdp->lang->metasource) |
1651 /* It may be that this is a bingo.y file, and we already parsed a bingo.c | 1651 /* It may be that this is a bingo.y file, and we already parsed a bingo.c |
1652 file, or anyway we parsed a file that is automatically generated from | 1652 file, or anyway we parsed a file that is automatically generated from |
1653 this one. If this is the case, the bingo.c file contained #line | 1653 this one. If this is the case, the bingo.c file contained #line |