some warning isn't gonna be fix like documentation-unknown-command,
reserved-id-macro, cast-qual, padded and others.
T8283
Details
Details
- Reviewers
lauromoura felipealmeida - Maniphest Tasks
- T8283: clang warnings
compile with clang and -Weverything, fixing the warnings.
Diff Detail
Diff Detail
- Repository
- rEFL core/efl
- Branch
- arcpatch-D10172
- Lint
No Linters Available - Unit
No Unit Test Coverage - Build Status
Buildable 13819 Build 9601: arc lint + arc unit
Comment Actions
@bu5hm4n A practical example is because of this https://godbolt.org/z/hGcc4m .
(on the left, there isn't a declaration, on the right, there is it).
C compiler only see names declared above from the current name, so, for example,
in eina_accessor.c, we have
Eina_Bool eina_accessor_init(void) { return eina_magic_string_set(EINA_MAGIC_ACCESSOR, EINA_MAGIC_ACCESSOR_STR); } Eina_Bool eina_accessor_shutdown(void) { return EINA_TRUE; }
so, inside eina_accessor_init, it could be possible to do things like
(highly dependable of c and std version)
Eina_Bool eina_accessor_init(void) { eina_accessor_shutdown(1,2,3,4,5); return eina_magic_string_set(EINA_MAGIC_ACCESSOR, EINA_MAGIC_ACCESSOR_STR); }
But this is positional, with definition in the beginning of a file, it's possible not have the declaration,
for safety, it's good to have declarations.