mercurial/utils/stringutil.py
changeset 51699 ca7bde5dbafb
parent 51696 7f0cb9ee0534
child 51725 278af66e6595
equal deleted inserted replaced
51698:b0a4de6c14f8 51699:ca7bde5dbafb
   572 
   572 
   573     if mailmapcontent is None:
   573     if mailmapcontent is None:
   574         return mailmap
   574         return mailmap
   575 
   575 
   576     for line in mailmapcontent.splitlines():
   576     for line in mailmapcontent.splitlines():
   577 
       
   578         # Don't bother checking the line if it is a comment or
   577         # Don't bother checking the line if it is a comment or
   579         # is an improperly formed author field
   578         # is an improperly formed author field
   580         if line.lstrip().startswith(b'#'):
   579         if line.lstrip().startswith(b'#'):
   581             continue
   580             continue
   582 
   581 
   799             # Arrange in reverse order so items can be efficiently popped
   798             # Arrange in reverse order so items can be efficiently popped
   800             # from a stack of chucks.
   799             # from a stack of chucks.
   801             chunks.reverse()
   800             chunks.reverse()
   802 
   801 
   803             while chunks:
   802             while chunks:
   804 
       
   805                 # Start the list of chunks that will make up the current line.
   803                 # Start the list of chunks that will make up the current line.
   806                 # cur_len is just the length of all the chunks in cur_line.
   804                 # cur_len is just the length of all the chunks in cur_line.
   807                 cur_line = []
   805                 cur_line = []
   808                 cur_len = 0
   806                 cur_len = 0
   809 
   807