From 87e8f59953f71c067b1c01109fbf7c7faf6e90c7 Mon Sep 17 00:00:00 2001 From: Ken Harris Date: Thu, 17 Aug 2023 21:11:01 -0700 Subject: [PATCH] Allow null git_diff_opts All libgit2 functions which take a git_diff_opts also allow NULL ("default values"). This change should allow Racket callers to pass #f here, too. --- libgit2/include/diff.rkt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libgit2/include/diff.rkt b/libgit2/include/diff.rkt index f435eb2..91bbe44 100644 --- a/libgit2/include/diff.rkt +++ b/libgit2/include/diff.rkt @@ -271,7 +271,7 @@ git_diff_free) (define-libgit2/alloc git_diff_index_to_workdir - (_fun _git_diff _git_repository _git_index _git_diff_opts-pointer -> _int) + (_fun _git_diff _git_repository _git_index _git_diff_opts-pointer/null -> _int) git_diff_free) (define-libgit2 git_diff_options_init @@ -311,17 +311,17 @@ (_fun (_git_buf/bytes-or-null) _git_diff _git_diff_format_t -> _int)) (define-libgit2/alloc git_diff_tree_to_index - (_fun _git_diff _git_repository _git_tree _git_index _git_diff_opts-pointer -> _int) + (_fun _git_diff _git_repository _git_tree _git_index _git_diff_opts-pointer/null -> _int) git_diff_free) (define-libgit2/alloc git_diff_tree_to_tree - (_fun _git_diff _git_repository _git_tree _git_tree _git_diff_opts-pointer -> _int) + (_fun _git_diff _git_repository _git_tree _git_tree _git_diff_opts-pointer/null -> _int) git_diff_free) (define-libgit2/alloc git_diff_tree_to_workdir - (_fun _git_diff _git_repository _git_tree _git_diff_opts-pointer -> _int) + (_fun _git_diff _git_repository _git_tree _git_diff_opts-pointer/null -> _int) git_diff_free) (define-libgit2/alloc git_diff_tree_to_workdir_with_index - (_fun _git_diff _git_repository _git_tree _git_diff_opts-pointer -> _int) + (_fun _git_diff _git_repository _git_tree _git_diff_opts-pointer/null -> _int) git_diff_free)