FEniCS / FEniCS/ffcx

Casting warnings on Windows

Open
#715 0 comments 0 reactions 1 assignee Claimed by @jhale View on GitHub
Dominant language
Python
Stars
192
Forks
45
Avg merge
1d 18h
Merged PRs (30d)
17

Description

Originally reported by @minrk.

https://github.com/FEniCS/dolfinx/pull/3198#issuecomment-2143416276

_When running the tests on Windows_, forgot to mention, this warning came up:

```
libffcx_forms_1b9958e91fd54e9c55f60346c28378fb63cad26e.c(722): warning C4305: 'initializing': truncation from 'double' to 'const float'
```

104,127 times when running the tests. I'm not sure if that's something that should be fixed in ffcx.

compiler warnings summary from running the tests with `pytest -vs`:

```
# grep -E -o 'warning C.+' dolfinx-win64.txt | sort | uniq -c
1665 warning C4113: 'ufcx_tabulate_tensor_float32 (__cdecl **)' differs in parameter lists from 'void (__cdecl **)(float *,const float *,const float *,const float *,const int *,const uint8_t *)'
1665 warning C4113: 'ufcx_tabulate_tensor_float64 (__cdecl **)' differs in parameter lists from 'void (__cdecl **)(double *,const double *,const double *,const double *,const int *,const uint8_t *)'
165 warning C4244: 'initializing': conversion from 'double' to 'float', possible loss of data
104127 warning C4305: 'initializing': truncation from 'double' to 'const float'
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.