Friday, 15 July 2011

c - Standard alternative to POSIX typedef -


Before I read that posx has reserved reserved at the end of typing in _t , I used it repeatedly What would normally be a general standard option for this suffix?

"standard" is a big word. If you look at ISO C, it is beyond your work to define; In fact, it uses names like time_t or size_t because it is allowed because POSIX is secondary to it, apart from this, this conference is not implemented in the Windows-based programming environment. Happens, for example, for example.

IMHO, it is not really necessary that is a type of type in C. There are several types, so it is primary to determine whether it is an underlying type or ADT. In addition, in such underlying types, the short case is the name of a word: If you have seen stat_buffer you can immediately know that it can not be an underlying type.

Whatever you choose, it is important to keep consistent on your source code anyways, I can see that many times can happen:

  • Uppercase naming, like time or Pid
  • time or pid Type time or pid_type
  • suffix

No comments:

Post a Comment