Skip to content

Commit 3060592

Browse files
committed
chore: fix C lint errors
1 parent 8ad374c commit 3060592

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/node_modules/@stdlib/stats/base/dnanvariancetk/examples/c/example.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
int main( void ) {
2424
// Create a strided array:
25-
double x[] = { 1.0, 2.0, 0.0/0.0, 3.0, 0.0/0.0, 4.0, 5.0, 6.0, 0.0/0.0, 7.0, 8.0, 0.0/0.0 };
25+
const double x[] = { 1.0, 2.0, 0.0/0.0, 3.0, 0.0/0.0, 4.0, 5.0, 6.0, 0.0/0.0, 7.0, 8.0, 0.0/0.0 };
2626

2727
// Specify the number of elements:
2828
int64_t N = 6;

lib/node_modules/@stdlib/stats/base/dsnanmean/benchmark/c/benchmark.length.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ static float rand_float( void ) {
9696
*/
9797
static double benchmark( int iterations, int len ) {
9898
double elapsed;
99-
float x[ len ];
99+
float x[ len ] = {0}; /* Initialize array to silence warning */
100100
double v;
101101
double t;
102102
int i;

0 commit comments

Comments
 (0)