code: function addComment(start, end, type, value) {
          assert(typeof start === 'number', 'Comment must have valid position');
  
          // Because the way the actual token is scanned, often the comments
          // (if any) are skipped twice during the lexical analysis.
          // Thus, we need to skip adding a comment if the comment array already
          // handled it.
          if (extra.comments.length > 0) {
              if (extra.comments[extra.comments.length - 1].range[1] > start) {
                  return;
              }
          }
  
          extra.comments.push({
              range: [start, end],
              type: type,
              value: value
          });
      }
docs: The following functions are needed only when the option to preserve the comments is active.