Fix C lint errors
- 主要语言
- JavaScript
- 星标
- 6k
- 派生
- 1.3k
- 平均合并
- 1 天 3 小时
- 30 天内合并 PR
- 611
描述
## C Linting Failures
Linting failures were detected in the automated lint workflow run.
### Workflow Details
- Run: https://github.com/stdlib-js/stdlib/actions/runs/13935811455
- Type: C Linting
- Date: 2025-03-19 00:14:23 UTC
### Error Details
```
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:200:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_1D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:284:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_2D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:368:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_2D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:452:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_3D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:536:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_3D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:620:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_4D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:704:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_4D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:788:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_5D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:872:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_5D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:956:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_6D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1040:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_6D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1124:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_7D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1208:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_7D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1292:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_8D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1376:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_8D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1460:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_9D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1544:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_9D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1628:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_10D_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1712:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_10D_BLOCKED_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c:1796:2: style: Variable 'x1' can be declared as pointer to const [constVariablePointer]
STDLIB_NDARRAY_NULLARY_ND_LOOP_CLBK_RET_CAST_FCN( stdlib_complex128_t, stdlib_complex128_from_complex64 )
^
```
贡献指南
调研方向
从 lib/node_modules/@stdlib/ndarray/base/nullary/src/z_as_c.c 开始,检查 C lint workflow 运行中报告的宏展开。修正 x1 的 constVariablePointer 检查结果,然后重新运行 C lint workflow 或其等效流程,并确认这些错误不再出现。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- c
- 领域
- testing-qa
- Issue 类型
- 缺陷
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 活跃度
- 停滞
- 描述清晰度
- 描述清楚
- 新手友好度
- 35/100