From 36c3ddf82fa47f2718b9782e1a7586f477c1a0db Mon Sep 17 00:00:00 2001 From: Tyge Løvset Date: Thu, 13 Jan 2022 15:45:28 +0100 Subject: Fix a potential compilation bug in cbox/carc. --- include/stc/carc.h | 8 ++++---- include/stc/cbox.h | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'include') diff --git a/include/stc/carc.h b/include/stc/carc.h index ccb23a73..9c7d52c1 100644 --- a/include/stc/carc.h +++ b/include/stc/carc.h @@ -145,7 +145,7 @@ _cx_memb(_reset_from)(_cx_self* self, i_val val) { } #if !c_option(c_no_clone) && !defined _i_no_raw - STC_INLINE _cx_self _cx_memb(_new)(i_valraw raw) { + STC_INLINE _cx_self _cx_memb(_new)(_cx_raw raw) { return _cx_memb(_from)(i_valfrom(raw)); } #endif @@ -177,7 +177,7 @@ _cx_memb(_value_hash)(const _cx_value* x, size_t n) { #elif c_option(c_no_cmp) return c_hash32(&x, 4); #else - i_valraw rx = i_valto(x); + _cx_raw rx = i_valto(x); return i_hash(&rx, sizeof rx); #endif } @@ -187,7 +187,7 @@ _cx_memb(_value_cmp)(const _cx_value* x, const _cx_value* y) { #if c_option(c_no_cmp) return c_default_cmp(&x, &y); #else - i_valraw rx = i_valto(x), ry = i_valto(x); + _cx_raw rx = i_valto(x), ry = i_valto(x); return i_cmp(&rx, &ry); #endif } @@ -197,7 +197,7 @@ _cx_memb(_value_eq)(const _cx_value* x, const _cx_value* y) { #if c_option(c_no_cmp) return x == y; #else - i_valraw rx = i_valto(x), ry = i_valto(x); + _cx_raw rx = i_valto(x), ry = i_valto(x); return i_eq(&rx, &ry); #endif } diff --git a/include/stc/cbox.h b/include/stc/cbox.h index 5eb1f1e3..41d8f654 100644 --- a/include/stc/cbox.h +++ b/include/stc/cbox.h @@ -121,7 +121,7 @@ _cx_memb(_reset_from)(_cx_self* self, i_val val) { #if !c_option(c_no_clone) #if !defined _i_no_raw STC_INLINE _cx_self - _cx_memb(_new)(i_valraw raw) { + _cx_memb(_new)(_cx_raw raw) { return c_make(_cx_self){c_new(i_val, i_valfrom(raw))}; } #endif @@ -153,7 +153,7 @@ _cx_memb(_value_hash)(const _cx_value* x, size_t n) { #elif c_option(c_no_cmp) return c_hash32(&x, 4); #else - i_valraw rx = i_valto(x); + _cx_raw rx = i_valto(x); return i_hash(&rx, sizeof rx); #endif } @@ -163,7 +163,7 @@ _cx_memb(_value_cmp)(const _cx_value* x, const _cx_value* y) { #if c_option(c_no_cmp) return c_default_cmp(&x, &y); #else - i_valraw rx = i_valto(x), ry = i_valto(x); + _cx_raw rx = i_valto(x), ry = i_valto(x); return i_cmp(&rx, &ry); #endif } @@ -173,7 +173,7 @@ _cx_memb(_value_eq)(const _cx_value* x, const _cx_value* y) { #if c_option(c_no_cmp) return x == y; #else - i_valraw rx = i_valto(x), ry = i_valto(x); + _cx_raw rx = i_valto(x), ry = i_valto(x); return i_eq(&rx, &ry); #endif } -- cgit v1.2.3