From: "Robert P. J. Day" <rpjday@mindspring.com>
To: C programming list <linux-c-programming@vger.kernel.org>
Subject: any compelling reasons to use "offsetof"?
Date: Thu, 18 Aug 2005 10:21:50 -0400 (EDT) [thread overview]
Message-ID: <Pine.LNX.4.63.0508181019570.10814@localhost.localdomain> (raw)
in a legacy project i just inherited, i did a quick recursive grep
and noticed a number of invocations of "offsetof". from experience,
i've concluded that the majority of these calls are because of sloppy
programming or laziness or just plain doing something incredibly hacky
that could be done in a more straightforward way.
are there any really compelling reasons to need to know the offset
of a structure field? just curious.
rday
next reply other threads:[~2005-08-18 14:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-18 14:21 Robert P. J. Day [this message]
2005-08-19 5:46 ` any compelling reasons to use "offsetof"? _z33
2005-08-19 9:36 ` Glynn Clements
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.63.0508181019570.10814@localhost.localdomain \
--to=rpjday@mindspring.com \
--cc=linux-c-programming@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).