Closed eschnett closed 6 months ago
I am building notcurses 3.0.9. I see this build error on Windows when building with GCC 7:
/workspace/srcdir/notcurses/src/demo/animate.c: In function ‘spin_cycle’: -- | [21:04:40] /workspace/srcdir/notcurses/src/demo/animate.c:134:19: error: empty scalar initializer | [21:04:40] 134 \| mbstate_t mbs = { }; | [21:04:40] \| ^ | [21:04:40] /workspace/srcdir/notcurses/src/demo/animate.c:134:19: note: (near initialization for ‘mbs’) | [21:04:40]
I believe the C 11 standard does not allow initializing variables via {}, i.e. via empty initializer lists.
{}
The same problem might exist further down in the same file in line 271 ncprogbar_options popts = { };.
ncprogbar_options popts = { };
yeah, we ought be using the = { 0 } form, good call
= { 0 }
should be resolved. thanks!
I am building notcurses 3.0.9. I see this build error on Windows when building with GCC 7:
I believe the C 11 standard does not allow initializing variables via
{}
, i.e. via empty initializer lists.The same problem might exist further down in the same file in line 271
ncprogbar_options popts = { };
.