Добавление квалификатора const, который запрещает изменение указателя

This commit is contained in:
Andrey Pokidov 2026-03-23 18:55:33 +07:00
parent 51fafe50c8
commit 610756ffed
14 changed files with 1019 additions and 1039 deletions

View file

Internal server error - Personal Git Server: Beyond coding. We Forge.

500

Internal server error

Forgejo version: 11.0.1+gitea-1.22.0

@ -1,101 +1,101 @@
#include "./complex.h"
extern inline void bgc_fp32_complex_reset(BGC_FP32_Complex* complex);
extern inline void bgc_fp64_complex_reset(BGC_FP64_Complex* complex);
extern inline void bgc_fp32_complex_reset(BGC_FP32_Complex* const complex);
extern inline void bgc_fp64_complex_reset(BGC_FP64_Complex* const complex);
extern inline void bgc_fp32_complex_make(BGC_FP32_Complex* complex, const float real, const float imaginary);
extern inline void bgc_fp64_complex_make(BGC_FP64_Complex* complex, const double real, const double imaginary);
extern inline void bgc_fp32_complex_make(BGC_FP32_Complex* const complex, const float real, const float imaginary);
extern inline void bgc_fp64_complex_make(BGC_FP64_Complex* const complex, const double real, const double imaginary);
extern inline float bgc_fp32_complex_get_square_modulus(const BGC_FP32_Complex* number);
extern inline double bgc_fp64_complex_get_square_modulus(const BGC_FP64_Complex* number);
extern inline float bgc_fp32_complex_get_square_modulus(const BGC_FP32_Complex* const number);
extern inline double bgc_fp64_complex_get_square_modulus(const BGC_FP64_Complex* const number);
extern inline float bgc_fp32_complex_get_modulus(const BGC_FP32_Complex* number);
extern inline double bgc_fp64_complex_get_modulus(const BGC_FP64_Complex* number);
extern inline float bgc_fp32_complex_get_modulus(const BGC_FP32_Complex* const number);
extern inline double bgc_fp64_complex_get_modulus(const BGC_FP64_Complex* const number);
extern inline int bgc_fp32_complex_is_zero(const BGC_FP32_Complex* number);
extern inline int bgc_fp64_complex_is_zero(const BGC_FP64_Complex* number);
extern inline int bgc_fp32_complex_is_zero(const BGC_FP32_Complex* const number);
extern inline int bgc_fp64_complex_is_zero(const BGC_FP64_Complex* const number);
extern inline int bgc_fp32_complex_is_unit(const BGC_FP32_Complex* number);
extern inline int bgc_fp64_complex_is_unit(const BGC_FP64_Complex* number);
extern inline int bgc_fp32_complex_is_unit(const BGC_FP32_Complex* const number);
extern inline int bgc_fp64_complex_is_unit(const BGC_FP64_Complex* const number);
extern inline void bgc_fp32_complex_copy(BGC_FP32_Complex* destination, const BGC_FP32_Complex* source);
extern inline void bgc_fp64_complex_copy(BGC_FP64_Complex* destination, const BGC_FP64_Complex* source);
extern inline void bgc_fp32_complex_copy(BGC_FP32_Complex* const destination, const BGC_FP32_Complex* const source);
extern inline void bgc_fp64_complex_copy(BGC_FP64_Complex* const destination, const BGC_FP64_Complex* const source);
extern inline void bgc_fp32_complex_swap(BGC_FP32_Complex* number1, BGC_FP32_Complex* number2);
extern inline void bgc_fp64_complex_swap(BGC_FP64_Complex* number1, BGC_FP64_Complex* number2);
extern inline void bgc_fp32_complex_swap(BGC_FP32_Complex* const number1, BGC_FP32_Complex* const number2);
extern inline void bgc_fp64_complex_swap(BGC_FP64_Complex* const number1, BGC_FP64_Complex* const number2);
extern inline void bgc_fp64_complex_convert_to_fp32(BGC_FP32_Complex* destination, const BGC_FP64_Complex* source);
extern inline void bgc_fp32_complex_convert_to_fp64(BGC_FP64_Complex* destination, const BGC_FP32_Complex* source);
extern inline void bgc_fp64_complex_convert_to_fp32(BGC_FP32_Complex* const destination, const BGC_FP64_Complex* const source);
extern inline void bgc_fp32_complex_convert_to_fp64(BGC_FP64_Complex* const destination, const BGC_FP32_Complex* const source);
extern inline void bgc_fp32_complex_revert(BGC_FP32_Complex* number);
extern inline void bgc_fp64_complex_revert(BGC_FP64_Complex* number);
extern inline void bgc_fp32_complex_revert(BGC_FP32_Complex* const number);
extern inline void bgc_fp64_complex_revert(BGC_FP64_Complex* const number);
extern inline void bgc_fp32_complex_get_reverse(BGC_FP32_Complex* reverse, const BGC_FP32_Complex* number);
extern inline void bgc_fp64_complex_get_reverse(BGC_FP64_Complex* reverse, const BGC_FP64_Complex* number);
extern inline void bgc_fp32_complex_get_reverse(BGC_FP32_Complex* const reverse, const BGC_FP32_Complex* const number);
extern inline void bgc_fp64_complex_get_reverse(BGC_FP64_Complex* const reverse, const BGC_FP64_Complex* const number);
extern inline int bgc_fp32_complex_normalize(BGC_FP32_Complex* number);
extern inline int bgc_fp64_complex_normalize(BGC_FP64_Complex* number);
extern inline int bgc_fp32_complex_normalize(BGC_FP32_Complex* const number);
extern inline int bgc_fp64_complex_normalize(BGC_FP64_Complex* const number);
extern inline int bgc_fp32_complex_get_normalized(BGC_FP32_Complex* normalized, const BGC_FP32_Complex* number);
extern inline int bgc_fp64_complex_get_normalized(BGC_FP64_Complex* normalized, const BGC_FP64_Complex* number);
extern inline int bgc_fp32_complex_get_normalized(BGC_FP32_Complex* const normalized, const BGC_FP32_Complex* const number);
extern inline int bgc_fp64_complex_get_normalized(BGC_FP64_Complex* const normalized, const BGC_FP64_Complex* const number);
extern inline void bgc_fp32_complex_conjugate(BGC_FP32_Complex* number);
extern inline void bgc_fp64_complex_conjugate(BGC_FP64_Complex* number);
extern inline void bgc_fp32_complex_conjugate(BGC_FP32_Complex* const number);
extern inline void bgc_fp64_complex_conjugate(BGC_FP64_Complex* const number);
extern inline void bgc_fp32_complex_get_conjugate(BGC_FP32_Complex* conjugate, const BGC_FP32_Complex* number);
extern inline void bgc_fp64_complex_get_conjugate(BGC_FP64_Complex* conjugate, const BGC_FP64_Complex* number);
extern inline void bgc_fp32_complex_get_conjugate(BGC_FP32_Complex* const conjugate, const BGC_FP32_Complex* const number);
extern inline void bgc_fp64_complex_get_conjugate(BGC_FP64_Complex* const conjugate, const BGC_FP64_Complex* const number);
extern inline int bgc_fp32_complex_invert(BGC_FP32_Complex* number);
extern inline int bgc_fp64_complex_invert(BGC_FP64_Complex* number);
extern inline int bgc_fp32_complex_invert(BGC_FP32_Complex* const number);
extern inline int bgc_fp64_complex_invert(BGC_FP64_Complex* const number);
extern inline int bgc_fp32_complex_get_inverse(BGC_FP32_Complex* inverse, const BGC_FP32_Complex* number);
extern inline int bgc_fp64_complex_get_inverse(BGC_FP64_Complex* inverse, const BGC_FP64_Complex* number);
extern inline int bgc_fp32_complex_get_inverse(BGC_FP32_Complex* const inverse, const BGC_FP32_Complex* const number);
extern inline int bgc_fp64_complex_get_inverse(BGC_FP64_Complex* const inverse, const BGC_FP64_Complex* const number);
extern inline void bgc_fp32_complex_add(BGC_FP32_Complex* sum, const BGC_FP32_Complex* number1, const BGC_FP32_Complex* number2);
extern inline void bgc_fp64_complex_add(BGC_FP64_Complex* sum, const BGC_FP64_Complex* number1, const BGC_FP64_Complex* number2);