|  | Good C Practice |  | |
| | | Christiano Farina Haesbae |  |
| Posted: Wed Sep 03, 2008 1:54 am Post subject: Good C Practice |  |
This is my first post to this group so please take it easy.
I'm no C expert but I've been coding in it for a while, I always ask myself what's the best place to see/read good C, by good C I mean projects that use C effectively in a "modern" and concise way.
How can I judge what's a good practice ? Where can we find it ?
For example, glib2, the low level API for the gtk framework uses C in a OO fashion, full of callbacks and types, providing loads of layers of abstraction. But each project is completely different from the other in this aspect.
So what's the *cool* thing ? the right thing and/or the *wrong* thing ? |
| |
| | | Ian Collins |  |
| Posted: Wed Sep 03, 2008 1:54 am Post subject: Re: Good C Practice |  |
Christiano Farina Haesbaert wrote:
| Quote: | This is my first post to this group so please take it easy.
I'm no C expert but I've been coding in it for a while, I always ask myself what's the best place to see/read good C, by good C I mean projects that use C effectively in a "modern" and concise way.
How can I judge what's a good practice ? Where can we find it ?
If you are looking for something recent, manageable and well structured, |
have a look at the Solaris ZFS source:
LINK
-- Ian Collins. |
| |
| | | Pilcrow |  |
| Posted: Wed Sep 03, 2008 2:51 am Post subject: Re: Good C Practice |  |
On Wed, 03 Sep 2008 13:59:30 +1200, Ian Collins <ian-news@hotmail.com> wrote:
| Quote: | Christiano Farina Haesbaert wrote: This is my first post to this group so please take it easy.
I'm no C expert but I've been coding in it for a while, I always ask myself what's the best place to see/read good C, by good C I mean projects that use C effectively in a "modern" and concise way.
How can I judge what's a good practice ? Where can we find it ?
If you are looking for something recent, manageable and well structured, have a look at the Solaris ZFS source:
LINK
|
Very interesting link. Pardon what may be a stupid question, but how similar/different is this from linux? |
| |
| | | Ian Collins |  |
| Posted: Wed Sep 03, 2008 3:00 am Post subject: Re: Good C Practice |  |
Pilcrow wrote:
| Quote: | On Wed, 03 Sep 2008 13:59:30 +1200, Ian Collins <ian-news@hotmail.com wrote:
Christiano Farina Haesbaert wrote: This is my first post to this group so please take it easy.
I'm no C expert but I've been coding in it for a while, I always ask myself what's the best place to see/read good C, by good C I mean projects that use C effectively in a "modern" and concise way.
How can I judge what's a good practice ? Where can we find it ?
If you are looking for something recent, manageable and well structured, have a look at the Solaris ZFS source:
LINK
Very interesting link. Pardon what may be a stupid question, but how similar/different is this from linux?
Years ahead! |
-- Ian Collins. |
| |
| | | Erik de Castro Lopo |  |
| Posted: Wed Sep 03, 2008 3:36 am Post subject: Re: Good C Practice |  |
Pilcrow wrote:
| Quote: | http://opensolaris.org/os/community/zfs/source/
Very interesting link. Pardon what may be a stupid question, but how similar/different is this from linux?
|
ZFS is a file system, Linux is an operating system kernel.
Erik -- ----------------------------------------------------------------- Erik de Castro Lopo ----------------------------------------------------------------- "... the industrial-capitalist mode of software production was doomed to be outcompeted from the moment capitalism began to create enough of a wealth surplus for many programmers to live in a post-scarcity gift culture." -- Eric S. Raymond |
| |
| | | Erik de Castro Lopo |  |
| Posted: Wed Sep 03, 2008 3:42 am Post subject: Re: Good C Practice |  |
Ian Collins wrote:
| Quote: | Very interesting link. Pardon what may be a stupid question, but how similar/different is this from linux?
Years ahead!
|
Saying ZFS (a filesystem) is years ahead of Linux (an OS kernel) is is somewhat silly.
Saying "The OpenSolaris platform" is years ahead of "The Linux Platform" is just as silly because there is at least one area where OpenSolaris is about a decade behind the commonly used Linux distros.
Erik (who once worked at SUN but never drank the Koolaid) -- ----------------------------------------------------------------- Erik de Castro Lopo ----------------------------------------------------------------- The word "Windows" is a word out of an old dialect of the Apaches. It means: "White man staring through glass-screen onto an hourglass..." |
| |
| | | Richard Bos |  |
| Posted: Wed Sep 03, 2008 6:36 am Post subject: Re: Good C Practice |  |
Erik de Castro Lopo <nospam@mega-nerd.com> wrote:
| Quote: | Ian Collins wrote:
Very interesting link. Pardon what may be a stupid question, but how similar/different is this from linux?
Years ahead!
Saying ZFS (a filesystem) is years ahead of Linux (an OS kernel) is is somewhat silly.
|
Not if you're talking about programming style. SunOS was years ahead of Linux in solidity and style decades ago, and still is.
Richard |
| |
| | | Thommy M. Malmström |  |
| Posted: Wed Sep 03, 2008 9:52 am Post subject: Re: Good C Practice |  |
Erik de Castro Lopo wrote:
| Quote: | Pilcrow wrote:
LINK Very interesting link. Pardon what may be a stupid question, but how similar/different is this from linux?
ZFS is a file system, Linux is an operating system kernel.
|
I think OP's question was regarding C programming style.
-- /"\ Join the ASCII | Thommy M. Malmström \ / ribbon campaign | AB Hardeberga IT X against HTML mail | Skiffervägen 23, 224 78 Lund / \ and postings | +46 70 969 57 93 ======================================================================= LINK thommym (at) at-hardeberga.com ======================================================================= "The box said 'Windows 2000 Server or better', so I installed Solaris." ======================================================================= |
| |
| | | Ian Collins |  |
| Posted: Wed Sep 03, 2008 5:06 pm Post subject: Re: Good C Practice |  |
Thommy M. Malmström wrote:
| Quote: | Erik de Castro Lopo wrote: Pilcrow wrote:
LINK Very interesting link. Pardon what may be a stupid question, but how similar/different is this from linux? ZFS is a file system, Linux is an operating system kernel.
I think OP's question was regarding C programming style.
So were my replies. |
-- Ian Collins. |
| |
|
|