Skip to content

Commit

Permalink
docs: resolve C lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
kgryte committed Apr 18, 2023
1 parent 90c94f9 commit 28e1c84
Show file tree
Hide file tree
Showing 700 changed files with 802 additions and 814 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -258,21 +258,21 @@ void stdlib_strided_{{ALIAS_SNAKECASE}}( const int64_t N, const {{C_TYPE}} *X, c

int main( void ) {
// Create an input strided array:
{{C_TYPE}} X[] = { {{C_X_VALUES_LEN_8}} };
const {{C_TYPE}} X[] = { {{C_X_VALUES_LEN_8}} };

// Create a mask strided array:
uint8_t M[] = { {{C_MASK_VALUES_LEN_8}} };
const uint8_t M[] = { {{C_MASK_VALUES_LEN_8}} };

// Create an output strided array:
{{C_TYPE}} Y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };

// Specify the number of elements:
int64_t N = 4;
const int64_t N = 4;

// Specify the stride lengths:
int64_t strideX = 2;
int64_t strideM = 2;
int64_t strideY = 2;
const int64_t strideX = 2;
const int64_t strideM = 2;
const int64_t strideY = 2;

// Compute the results:
stdlib_strided_{{ALIAS_SNAKECASE}}( N, X, strideX, M, strideM, Y, strideY );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -235,17 +235,17 @@ void stdlib_strided_{{ALIAS_SNAKECASE}}( const int64_t N, const {{C_TYPE}} *X, c

int main( void ) {
// Create an input strided array:
{{C_TYPE}} X[] = { {{C_X_VALUES_LEN_8}} };
const {{C_TYPE}} X[] = { {{C_X_VALUES_LEN_8}} };

// Create an output strided array:
{{C_TYPE}} Y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };

// Specify the number of elements:
int64_t N = 4;
const int64_t N = 4;

// Specify the stride lengths:
int64_t strideX = 2;
int64_t strideY = 2;
const int64_t strideX = 2;
const int64_t strideY = 2;

// Compute the results:
stdlib_strided_{{ALIAS_SNAKECASE}}( N, X, strideX, Y, strideY );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/ccopy.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
float x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
float y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/cswap.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
float x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
float y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/dasum.h"
#include <stdio.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/daxpy.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
double y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/dcopy.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
double y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/ddot.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };
double y[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/dnrm2.h"
#include <stdio.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/dscal.h"
#include <stdio.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/dsdot.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
float x[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };
float y[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/dswap.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
double y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/sasum.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create a strided array:
float x[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/saxpy.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
float x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
float y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/scopy.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
float x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
float y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/sdot.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
float x[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };
float y[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/sdsdot.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
float x[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };
float y[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/snrm2.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create a strided array:
float x[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/sscal.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create a strided array:
float x[] = { 1.0, -2.0, 3.0, -4.0, 5.0, -6.0, 7.0, -8.0 };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/base/sswap.h"
#include <stdio.h>

int main() {
int main( void ) {
// Create strided arrays:
float x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
float y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/ext/base/dapx.h"
#include <stdio.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include <stdint.h>
#include <stdio.h>

int main() {
int main( void ) {
// Create a strided array:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include <stdint.h>
#include <stdio.h>

int main() {
int main( void ) {
// Create a strided array:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include <stdint.h>
#include <stdio.h>

int main() {
int main( void ) {
// Create a strided array:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include <stdint.h>
#include <stdio.h>

int main() {
int main( void ) {
// Create a strided array:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include <stdint.h>
#include <stdio.h>

int main() {
int main( void ) {
// Create a strided array:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include <stdint.h>
#include <stdio.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
double y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
double y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
double y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
double y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

int main() {
int main( void ) {
// Create strided arrays:
double x[] = { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 };
double y[] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "stdlib/blas/ext/base/dfill.h"
#include <stdio.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include <stdint.h>
#include <stdio.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include <stdint.h>
#include <stdio.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include <stdio.h>
#include <inttypes.h>

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

Expand Down
Loading

0 comments on commit 28e1c84

Please sign in to comment.