[Lxr-commits] CVS: lxr/lib/LXR Common.pm,1.36,1.37
Brought to you by:
ajlittoz
|
From: Malcolm B. <mb...@us...> - 2001-11-18 03:31:37
|
Update of /cvsroot/lxr/lxr/lib/LXR
In directory usw-pr-cvs1:/tmp/cvs-serv15958/lib/LXR
Modified Files:
Common.pm
Log Message:
Fix bug 476695 - Java interfaces display as docs.
Changes the type field in the indexes table to be a (langid, typeid) tuple,
and adds another table to look up the (langid, typeid) -> string mapping.
This means that each language module can manage its own string table and the
right identifier type can easily be displayed.
This also means that each identifier is tagged with the language it occurs in,
which could be used for filtering displayed results when browsing. This has
not been implemented.
This change is database incompatible - you will need to drop and recreate the
lxr database. MySQL has been tested, Postgres has not though the changes have
been made.
Also add some limited support for Makefile in generic.conf.
Index: Common.pm
===================================================================
RCS file: /cvsroot/lxr/lxr/lib/LXR/Common.pm,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -d -r1.36 -r1.37
--- Common.pm 2001/11/17 03:06:19 1.36
+++ Common.pm 2001/11/18 03:31:34 1.37
@@ -28,13 +28,13 @@
use vars qw(@ISA @EXPORT @EXPORT_OK %EXPORT_TAGS
$files $index $config $pathname $identifier $release
- $HTTP %type_names $wwwdebug $tmpcounter);
+ $HTTP $wwwdebug $tmpcounter);
@ISA = qw(Exporter);
@EXPORT = qw($files $index $config &fatal);
@EXPORT_OK = qw($files $index $config $pathname $identifier $release
- $HTTP %type_names
+ $HTTP
&warning &fatal &abortall &fflush &urlargs &fileref
&idref &incref &htmlquote &freetextmarkup &markupfile
&markupstring &httpinit &makeheader &makefooter
@@ -53,21 +53,6 @@
$wwwdebug = 1;
-%type_names = ('c' => 'class',
- 'd' => 'macro (un)definition',
- 'e' => 'enumerator',
- 'f' => 'function definition',
- 'g' => 'enumeration name',
- 'm' => 'class, struct, or union member',
- 'n' => 'namespace',
- 'p' => 'function prototype or declaration',
- 's' => 'structure name',
- 't' => 'typedef',
- 'u' => 'union names',
- 'v' => 'variable definition',
- 'x' => 'extern or forward variable declaration',
- 'i' => 'interface');
-
$tmpcounter = 23;
@@ -296,7 +281,8 @@
# A source code file
if ($lang) {
- my $language = $lang->language; # To get back to the key to lookup the tabwidth.
+ my $language = $lang->language; # To get back to the key to lookup the tabwidth.
+
&LXR::SimpleParse::init($fileh, $config->filetype->{$language}[3], $lang->parsespec);
my ($btype, $frag) = &LXR::SimpleParse::nextfrag;
|