Sujet : Re: encapsulating directory operations
De : 643-408-1753 (at) *nospam* kylheku.com (Kaz Kylheku)
Groupes : comp.lang.cDate : 30. May 2025, 04:42:44
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <20250529203642.525@kylheku.com>
References : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
User-Agent : slrn/pre1.0.4-9 (Linux)
On 2025-05-30, Waldek Hebisch <
antispam@fricas.org> wrote:
Concerning new code it makes sense to avoid constructs that
are made illegal in later standard, that is write to the
latter of later standard even if you use only constructs
available in C90.
Speaking of which, I like to avoid declarations mixed
with statements. GCC supports that with a diagnostic:
-Werror=declaration-after-statement.
However, the wording of the diagnostic, when it goes off,
is poor: it says something like "C90 doesn't allow
mixed declarations and statements".
Aaaargh! I said, error out for declarations after
statements. I didn't say I'm writing in C90.
Look, in the same function, I initialized an automatic
aggregate with a non-constant, which is also not in C90!
-- TXR Programming Language: http://nongnu.org/txrCygnal: Cygwin Native Application Library: http://kylheku.com/cygnalMastodon: @Kazinator@mstdn.ca