MCPcopy Create free account
hub / github.com/libgit2/pygit2 / wrap_branch

Function wrap_branch

src/branch.c:338–353  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

336};
337
338PyObject *
339wrap_branch(git_reference *c_reference, Repository *repo)
340{
341 Branch *py_branch=NULL;
342
343 py_branch = PyObject_New(Branch, &BranchType);
344 if (py_branch) {
345 py_branch->reference = c_reference;
346 if (repo) {
347 py_branch->repo = repo;
348 Py_INCREF(repo);
349 }
350 }
351
352 return (PyObject *)py_branch;
353}

Callers 4

Repository_lookup_branchFunction · 0.85
Repository_create_branchFunction · 0.85
Branch_renameFunction · 0.85
Branch_upstream__get__Function · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…