From 7b3f5296c54d0362ab90c2299b4c9255aca171a8 Mon Sep 17 00:00:00 2001 From: Yichao Yu Date: Tue, 5 Jul 2016 17:36:26 -0400 Subject: [PATCH] Fix compiler warnings --- src/alloc.c | 2 +- src/gf.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/alloc.c b/src/alloc.c index 6cabae7dd437d..50d42703424a4 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -860,7 +860,7 @@ jl_datatype_t *jl_new_abstracttype(jl_value_t *name, jl_datatype_t *super, return dt; } -jl_datatype_t *jl_new_uninitialized_datatype() +jl_datatype_t *jl_new_uninitialized_datatype(void) { jl_ptls_t ptls = jl_get_ptls_states(); jl_datatype_t *t = (jl_datatype_t*)jl_gc_alloc(ptls, sizeof(jl_datatype_t), jl_datatype_type); diff --git a/src/gf.c b/src/gf.c index d2d5ef7e5aad4..6a1ec04f34c33 100644 --- a/src/gf.c +++ b/src/gf.c @@ -1290,7 +1290,8 @@ jl_lambda_info_t *jl_compile_for_dispatch(jl_lambda_info_t *li) } } } - assert(!li->inInference && !li->inCompile && li->code != jl_nothing || li->jlcall_api == 2); + assert(!li->inInference && !li->inCompile && + (li->code != jl_nothing || li->jlcall_api == 2)); if (li->functionObjectsDecls.functionObject == NULL) { // check again, because jl_type_infer may have compiled it jl_compile_linfo(li); }