Skip to content

Commit edee137

Browse files
committed
refactor: replace int8_t by size_t
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: passed - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed ---
1 parent e053444 commit edee137

File tree

1 file changed

+2
-1
lines changed
  • lib/node_modules/@stdlib/math/base/special/fibonacci/src

1 file changed

+2
-1
lines changed

lib/node_modules/@stdlib/math/base/special/fibonacci/src/main.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
#include "stdlib/constants/float64/max_safe_nth_fibonacci.h"
2121
#include "stdlib/math/base/assert/is_nonnegative_integer.h"
2222
#include <stdint.h>
23+
#include <stdlib.h>
2324

2425
static const int64_t fibonacci_value[ 79 ] = {
2526
0,
@@ -117,5 +118,5 @@ double stdlib_base_fibonacci( const double n ) {
117118
if ( !stdlib_base_is_nonnegative_integer( n ) || n > STDLIB_CONSTANT_FLOAT64_MAX_SAFE_NTH_FIBONACCI ) {
118119
return 0.0 / 0.0; // NaN
119120
}
120-
return fibonacci_value[ (int8_t)n ];
121+
return fibonacci_value[ (size_t)n ];
121122
}

0 commit comments

Comments
 (0)