diff options
| author | nulltoken <emeric.fermas@gmail.com> | 2012-04-30 07:41:33 +0200 | 
|---|---|---|
| committer | nulltoken <emeric.fermas@gmail.com> | 2012-04-30 07:41:33 +0200 | 
| commit | 2de0652bb6d719eb937656153a920f20342bd5a4 (patch) | |
| tree | 49eed9a80b9e506953d18271bd03ae23558f29da /tests-clar/diff/diff_helpers.c | |
| parent | fa6420f73e8a621cc04e95820b625097b5c2fbf2 (diff) | |
| download | libgit2-2de0652bb6d719eb937656153a920f20342bd5a4.tar.gz | |
Leverage GIT_UNUSED macro to explicitly mark a function parameter as purposely unused
Diffstat (limited to 'tests-clar/diff/diff_helpers.c')
| -rw-r--r-- | tests-clar/diff/diff_helpers.c | 22 | 
1 files changed, 14 insertions, 8 deletions
| diff --git a/tests-clar/diff/diff_helpers.c b/tests-clar/diff/diff_helpers.c index 85dd52601..74a44ab99 100644 --- a/tests-clar/diff/diff_helpers.c +++ b/tests-clar/diff/diff_helpers.c @@ -27,7 +27,9 @@ int diff_file_fn(  	float progress)  {  	diff_expects *e = cb_data; -	(void)progress; + +	GIT_UNUSED(progress); +  	e->files++;  	switch (delta->status) {  	case GIT_DELTA_ADDED: e->file_adds++; break; @@ -48,9 +50,11 @@ int diff_hunk_fn(  	size_t header_len)  {  	diff_expects *e = cb_data; -	(void)delta; -	(void)header; -	(void)header_len; + +	GIT_UNUSED(delta); +	GIT_UNUSED(header); +	GIT_UNUSED(header_len); +  	e->hunks++;  	e->hunk_old_lines += range->old_lines;  	e->hunk_new_lines += range->new_lines; @@ -66,10 +70,12 @@ int diff_line_fn(  	size_t content_len)  {  	diff_expects *e = cb_data; -	(void)delta; -	(void)range; -	(void)content; -	(void)content_len; + +	GIT_UNUSED(delta); +	GIT_UNUSED(range); +	GIT_UNUSED(content); +	GIT_UNUSED(content_len); +  	e->lines++;  	switch (line_origin) {  	case GIT_DIFF_LINE_CONTEXT: | 
