References:
        https://developer.github.com/v3/issues/comments/#delete-a-comment
355368
def delete_comment(repo: GithubRepository, comment_id: int) -> None:
    
    url = ("https://api.github.com/repos/{}/{}/issues/comments/{}"
           "?access_token={}".format(repo.organization,
                                     repo.name,
                                     comment_id,
                                     repo.access_token))
    response = requests.delete(url)
    if response.status_code != 204:
        raise RuntimeError(
            'Comment delete failed. Code: {}. Content: {}.'.format(
                response.status_code, response.content))
403138
function(source) {

    // Remove comment markup from comments
    var comment = source.split(/\/\/[ ]?/).join('').split('/*').join('').split('*/').join(''),
      additionalKssParams = {},
      _this = this;

    comment = standardizeLinebreaks(comment);
    comment = trimLinebreaks(comment);

    comment.split('\n\n').forEach(function(markUpBlock) {

      var varName = markUpBlock.match(/([^:^\n]*):[\s\S]*\n/);
      if (varName && varName[1] !== undefined) {
        varName = varName[1].trim();
      }
      if (varName && varName.substring(0, 3) === 'sg-') {
        additionalKssParams[varName] = _this.getValue(varName, markUpBlock);
      }

    });

    return additionalKssParams;
  }
387620
function removeExportAnnotationsFromComment(comment) {
  // Remove @export annotations.
  comment = comment.replace(EXPORT_REGEX, '')

  // Split into lines, remove empty comment lines, then recombine.
  comment = comment.split('\n')
      .filter(function(line) { return !/^ *\*? *$/.test(line); })
      .join('\n');

  return comment;
}
472256
function(f) {
        var STRIP_COMMENTS = /((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg,
            fn_text        = this.reflector.getProto()[this.name].toString().replace(STRIP_COMMENTS, '');

        return fn_text.substr(fn_text.indexOf('{') + 1, fn_text.lastIndexOf('}') - 4).replace(/}([^}]*)$/, '$1');
    }
173434
def edit(user_name, repo_name, comment_id, params={})
      _update_user_repo_params(user_name, repo_name)
      _validate_user_repo_params(user, repo) unless user? && repo?
      _validate_presence_of comment_id

      normalize! params
      # _merge_mime_type(:issue_comment, params)
      filter! VALID_ISSUE_COMMENT_PARAM_NAME, params
      assert_required_keys(%w[ content ], params)

      put_request("/1.0/repositories/#{user}/#{repo.downcase}/issues/comments/#{comment_id}", params)
    end
801458
public Comment removeComment(final long commentId) {
        Comment removedComment = null;

        if (comments != null) {
            for (int index = comments.size() - 1; index >= 0; --index) {
                Comment currentComment = comments.get(index);

                if (currentComment.getId() == commentId) {
                    removedComment = comments.remove(index);
                    break;
                }
            }
        }

        return removedComment;
    }
872250
def _remove_comment(line):
    
    # First find just quotes and their indexes.
    quote_indexes = []
    hash_indexes = []
    for i, ch in enumerate(line):
        if ch == '"':
            quote_indexes.append(i)
            if i > 0 and line[i - 1] == "\\":
                quote_indexes.pop()
        elif ch == '#':
            hash_indexes.append(i)

    comment_marker_index = -1
    for hash_index in hash_indexes:
        quote_index_ranges = [quote_indexes[i:i + 2] for i in range(0, len(quote_indexes), 2)]
        if not _check_index_within_index_pairs(hash_index, quote_index_ranges):
            comment_marker_index = hash_index
            break

    if comment_marker_index >= 0:
        line = line[:comment_marker_index]
    return line
556591
function stripComments(token) {
  return strip

  /* Strip comments. */
  function strip(value) {
    var index = value.indexOf(token)

    if (index !== -1) {
      value = value.substr(0, index)
    }

    return value
  }
}
1162998
function stripTrailingComment(line, comment) {

            // loc.column is zero-indexed
            return line.slice(0, comment.loc.start.column).replace(/\s+$/u, "");
        }
701079
public function removeAllAction()
    {
        $isPosted = $this->request->getPost('doRemoveAll');
        
        if (!$isPosted) {
            $this->response->redirect($this->request->getPost('redirect'));
        }

        $comments = new \Phpmvc\Comment\CommentsInSession();
        $comments->setDI($this->di);

        $comments->deleteAll();

        $this->response->redirect($this->request->getPost('redirect'));
    }
1035069
def purge(self, delta):
        
        self.db.execute([
            'DELETE FROM comments WHERE mode = 2 AND ? - created > ?;'
        ], (time.time(), delta))
        self._remove_stale()
269267
def editComment(self, repo_user, repo_name, comment_id, body):
        
        return self.api.makeRequest(
            ["repos", repo_user, repo_name,
             "pulls", "comments", str(comment_id)],
            method="POST",
            data=dict(body=body))
1192660
function findRequireComments(source, source_path, options, deps) {
  var comment_reg = /{! require\("([\w\.\/\-_\|[\]]+)\"\) !}/g, // matches proprietary comment syntax for requiring multiple partials
    bracket_reg = /\[([^\]]*)\]/g,                            // matches brackets inside the comment requiring
    result = null, bracket_result = null, alt, name;

  // search source for require comments
  while ((result = comment_reg.exec(source)) !== null) {
    // this will check if there are any comments that have a | delimited list of files, such as {! require("patterns/atoms/[button|button_link]") !}
    bracket_result = bracket_reg.exec(result[1]);

    // if there is a result, split the files by | and include them all
    if (bracket_result) {
      alt = bracket_result[1].split("|");
      for (var i = 0; i < alt.length; i++) {
        name = result[1].replace(bracket_reg, alt[i]);
        log(options, 'found comment dependency "' + name + '"');

        // add a dust dependency for each alternative name
        addDustDependency(name, source_path, options, deps);
      }
    }
    //if there isn't a result, assume it was just a normal require like {! require("patterns/atoms/button") !}
    else {
      log(options, 'found comment dependency "' + result[1] + '"');
      addDustDependency(result[1], source_path, options, deps);
    }
  }
}
385309
def delete_comment(self, comment_id):
        """"""

        comment_obj = self.query(Comment).get(comment_id)
        if comment_obj:
            logger.debug("Deleting comment {0}".format(comment_obj.id))

        self.session.delete(comment_obj)
        self.save()

        return comment_obj
1228813
function commentIssue (client, repo, number, comment) {
  return client.createComment(repo, number, comment).then(convertComment);
}
185582
def deletecc(self, cclist, comment=None):
        
        vals = self.bugzilla.build_update(comment=comment,
                                          cc_remove=cclist)
        log.debug("deletecc: update=%s", vals)

        return self.bugzilla.update_bugs(self.bug_id, vals)
743264
def deleteComment(self, commentId):
        
        url = "%s/comments/%s/delete" % (self.root, commentId)
        params = {
            "f": "json",
        }
        return self._post(url,
                             params,
                             securityHandler=self._securityHandler,
                             proxy_port=self._proxy_port,
                             proxy_url=self._proxy_url)