[Ctags] regex question
                
                Brought to you by:
                
                    dhiebert
                    
                
            
            
        
        
        
    | 
     
      
      
      From: Johannes Z. <joh...@ze...> - 2001-08-21 09:57:41
      
     
   | 
Hi, the following pattern: --langdef=basic --langmap=basic:.bas.vbs.sba --regex-basic=/^[ \t]*(private[ \t]+)?(sub|function)[ \t]+([^( \t]+)/\3/r,regex/ei yiels with a *.sba file containing Sub Main a tag file like this (note that there are tag entries ABOVE THE HEADER) Macro1.sba /^Sub Main$/;" r Macro2.bas /^Sub Main$/;" r PolyMAXpci01.sba /^Sub Main$/;" r syn.sba /^Sub Main$/;" r !_TAG_FILE_FORMAT 2 /extended format; --format=1 will not append ;" to lines/ !_TAG_FILE_SORTED 1 /0=unsorted, 1=sorted/ !_TAG_PROGRAM_AUTHOR Darren Hiebert /da...@hi.../ !_TAG_PROGRAM_NAME Exuberant Ctags // !_TAG_PROGRAM_URL http://ctags.sourceforge.net /official site/ !_TAG_PROGRAM_VERSION 5.0.1 // DialogProc Macro1.sba /^Private Function DialogProc(DlgItem$, Action%, SuppValue%) As Boolean$/;" r DialogProc syn.sba /^Private Function DialogProc(DlgItem$, Action%, SuppValue%) As Boolean$/;" r Dialog_XDIO40 X-DIO-40.sba /^Private Sub Dialog_XDIO40 ' [-- SETTING UP THE DIALOG --]$/;" r Main X-DIO-40.sba /^Sub Main $/;" r Main If I add a space after 'Sub Main ' everything's ok. Apparently the regex replacement \3 evaluates to an empty string. Is this a bug ? -- Johannes  |