On Fri, 26 Jul 2013, Peter Zijlstra wrote: > On Thu, Jul 25, 2013 at 11:20:24PM -0400, Vince Weaver wrote: > > > > a thing that personally bothers me are these imaginary struct definitions > > added as part of the documentation that aren't actually available in the > > public perf_event.h > > > > I can see why it's done, but it can be confusing picking out in later > > definitions which struct fields are real and which ones are conceptual. > > Would it help if we changed the syntax to not look as much as real C > would? I've been thinking and I can't really think of a clearer way to present the layout. So I guess it's fine the way it is. Hopefully not many people are stuck having to implement code based on header file comments anyway. > > It might be clearer > > if you stuck the perf_event_attr::sample_id_all qualifier each > > place you add the sample_id field. > > Ah, I actually considered that but then got lazy and used the 0 sized > struct idea :/ It might just be me. For whatever reason the C parser in my head doesn't handle GNU extensions like 0-sized structs. Vince -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html