i'm looking at some legacy code and, in a header file, i find the
following (paraphrased for brevity):
typedef struct {
... stuff ...
} Widgets ;
extern Widgets Widget ;
huh? i can see why a header file would want to define a structure
but i'm confused why the *header* file would then refer to an external
object of that type. that's a new one on me -- typically, i'd expect
a *source* file to define such a thing and other *source* files to
contain the "extern" declaration.
is this some subtle programming cleverness of which i am unaware?
thanks.
rday
-
To unsubscribe from this list: send the line "unsubscribe linux-c-programming"
in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html