In some cases (@{<-n>} or <branchname>@{upstream}), the expression may
point to an intermediate reference. When such expressions are being passed
in, reference_out will be valued as well.
The returned object should be released with git_object_free and the
returned reference with git_reference_free when no longer needed.
@param object_out pointer to output object
@param reference_out pointer to output reference or null
@param repo the repository to search in
@param spec the textual specification for an object
@return 0 on success, git_error_code.GIT_ENOTFOUND, git_error_code.GIT_EAMBIGUOUS, git_error_code.GIT_EINVALIDSPEC
or an error code
Find a single object and intermediate reference by a revision string.
See man gitrevisions, or http://git-scm.com/docs/git-rev-parse.html#_specifying_revisions for information on the syntax accepted.
In some cases (@{<-n>} or <branchname>@{upstream}), the expression may point to an intermediate reference. When such expressions are being passed in, reference_out will be valued as well.
The returned object should be released with git_object_free and the returned reference with git_reference_free when no longer needed.
@param object_out pointer to output object @param reference_out pointer to output reference or null @param repo the repository to search in @param spec the textual specification for an object @return 0 on success, git_error_code.GIT_ENOTFOUND, git_error_code.GIT_EAMBIGUOUS, git_error_code.GIT_EINVALIDSPEC or an error code