Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Mar 19, 2024
1 parent bd39e33 commit 20e0f3a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
12 changes: 6 additions & 6 deletions src/read_data.c
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
for ( i = 0; i < len; i++ ) { \
TT val_ = v[i]; \
val_ = RoundFunc(val_); \
if (val_ >= min_ && val_ <= max_) { \
if ( val_ >= min_ && val_ <= max_ ) { \
data[i] = (T)val_; \
} else { \
break; \
Expand All @@ -72,7 +72,7 @@
for ( j = 0; j < block_size; j++ ) { \
TT val_ = v[j]; \
val_ = RoundFunc(val_); \
if (val_ >= min_ && val_ <= max_) { \
if ( val_ >= min_ && val_ <= max_ ) { \
data[i + j] = (T)val_; \
} else { \
err_ = 1; \
Expand All @@ -91,7 +91,7 @@
for ( j = 0; j < len - i; j++ ) { \
TT val_ = v[j]; \
val_ = RoundFunc(val_); \
if (val_ >= min_ && val_ <= max_) { \
if ( val_ >= min_ && val_ <= max_ ) { \
data[i + j] = (T)val_; \
} else { \
err_ = 1; \
Expand All @@ -115,7 +115,7 @@
for ( i = 0; i < len; i++ ) { \
TT swapped_ = SwapFunc(&v[i]); \
swapped_ = RoundFunc(swapped_); \
if (swapped_ >= min_ && swapped_ <= max_) { \
if ( swapped_ >= min_ && swapped_ <= max_ ) { \
data[i] = (T)swapped_; \
} else { \
break; \
Expand All @@ -133,7 +133,7 @@
for ( j = 0; j < block_size; j++ ) { \
TT swapped_ = SwapFunc(&v[j]); \
swapped_ = RoundFunc(swapped_); \
if (swapped_ >= min_ && swapped_ <= max_) { \
if ( swapped_ >= min_ && swapped_ <= max_ ) { \
data[i + j] = (T)swapped_; \
} else { \
err_ = 1; \
Expand All @@ -151,7 +151,7 @@
if ( j == len - i ) { \
for ( j = 0; j < len - i; j++ ) { \
TT swapped_ = SwapFunc(&v[j]); \
if (swapped_ >= min_ && swapped_ <= max_) { \
if ( swapped_ >= min_ && swapped_ <= max_ ) { \
data[i + j] = (T)swapped_; \
} else { \
err_ = 1; \
Expand Down
2 changes: 1 addition & 1 deletion src/read_data_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ CAT(Round, READ_TYPE)(READ_TYPE value)
#if READ_TYPE_TYPE == READ_TYPE_DOUBLE
return round(value);
#elif READ_TYPE_TYPE == READ_TYPE_SINGLE
return roundf(value);
return roundf(value);
#else
return value;
#endif
Expand Down

0 comments on commit 20e0f3a

Please sign in to comment.