code: function parse(code) {
    code = code + '\n';
    var lines = code.split(/\r\n|\r|\n/);
  
    var header;
    var sections = [];
  
    var comments = [];
    var inComment = false, section;
    lines.forEach(function(line) {
      // comment block
      if (/^\/\*/.test(line)) {
        inComment = true;
      }
      if (/\*\/$/.test(line)) {
        inComment = false;
        line = line.replace(/\*\/$/, '');
        comments.push(cleanLine(line));
        return;
      }
  
      if (/^\/\//.test(line)) {
        comments.push(cleanLine(line));
        return;
      }
  
      if (inComment) {
        comments.push(cleanLine(line));
        return;
      }
  
      // it is not comment now
      if (comments.length) {
        section = parseSection(comments);
        if (section) {
          sections.push(section);
        } else if (!header && !sections.length) {
          header = comments.join('\n');
        }
        // reset storage
        comments = [];
      }
    });
    return {header: header, sections: sections};
  }
docs: /*
  @author: Hsiaoming Yang