Changeset 1125


Ignore:
Timestamp:
Oct 1, 2012 1:33:14 PM (10 years ago)
Author:
jemian
Message:

fixes #37

File:
1 edited

Legend:

Unmodified
Added
Removed
  • specdomain/trunk/src/specdomain/sphinxcontrib/specmacrofileparser.py

    r1124 r1125  
    3737extended_comment_marker     = r'\"{3}'
    3838extended_comment_match      = r'(' + extended_comment_marker + r')'
    39 macro_name                  = r'\w+'
     39macro_name                  = r'[a-zA-Z_]\w*'
    4040macro_name_match            = r'(' + macro_name + r')'
    4141arglist_match               = r'(' + match_all + r')'
     
    198198            'extended comment': self.handle_extended_comment,
    199199            'function def': self.handle_def,
     200            'function rdef': self.handle_def,
    200201            'global': self.handle_other,
    201202            'local': self.handle_other,
    202203            'rdef': self.handle_other,
    203             'function rdef': self.handle_def,
    204204        }
    205205        process_first_list = ('descriptive comment', )
     
    421421            args = mo.group(3)
    422422            # TODO: What if args is multi-line?  flatten.  What if really long?
     423            if start == 225 and end == 225:
     424                pass
    423425            if args is not None:
    424426                if len(args)>2:
     
    429431                            pass  # TODO: Should we do something special here?
    430432                        args = m.group(1)
     433                elif args == '()':
     434                    objtype = 'function ' + objtype
    431435            d = {
    432436                'start_line': start,
Note: See TracChangeset for help on using the changeset viewer.