Re: Hungarian notation in C++ (is it used or not today, and if so, how?)

From: Thomas Matthews (Thomas_MatthewsSpitsOnSpamBots_at_sbcglobal.net)
Date: 10/27/04


Date: Wed, 27 Oct 2004 20:57:27 GMT

Colin Girling wrote:

> I had another discussion going about the use of Hungarian notation, and
> pointed out that all the companies I have worked for in the last 15 years
> have been useing this.
> If this is no longer used, what is used (or do people use nothing and just
> guess on the data type?)
>
> Also, I discovered there didn't seem to be any one standard, but many
> variations.
>
> The prefixes I am familiar with are these:
>
> p (pointer)
> c (constant)
> s (string)
> sz (null terminated string)
> l (long)
> u (unsigned), ul meaing unsinged long
> i (int)
> n (any integer type number)
> d (double)
> f (float or flag, varies)
> by (unsigned char, or byte)
> c (char)
> g or g_ (sometimes used for global)
> m_ (member variable)
>
>
> Any comments would be welcome, as I am always interested to hear what other
> people are using (if anything?)
> Thanks.
>
>

Personally, I'd rather spend my time understanding
an algorithm of a function that trying to figure out
puzzle of the Hungarian Notation prefix and validate
that the prefix is correct.

-- 
Thomas Matthews
C++ newsgroup welcome message:
          http://www.slack.net/~shiva/welcome.txt
C++ Faq: http://www.parashift.com/c++-faq-lite
C Faq:   http://www.eskimo.com/~scs/c-faq/top.html
alt.comp.lang.learn.c-c++ faq:
          http://www.comeaucomputing.com/learn/faq/
Other sites:
     http://www.josuttis.com  -- C++ STL Library book


Relevant Pages

  • Re: [C] fwrite question
    ... why the cast to pointer to unsigned char? ... > In either case, the first argument is pointer to void, which means ... Although the cast ... C++ Faq: http://www.parashift.com/c++-faq-lite C Faq: http://www.eskimo.com/~scs/c-faq/top.html alt.comp.lang.learn.c-c++ faq: ...
    (alt.comp.lang.learn.c-cpp)
  • Re: Really **wonderful** website for C interview questions!!!!!
    ... > then you should take a look at the C FAQ by Steve Summit... ... to return a string from a function"), and compare FAQ 7.5b. ... ("What is a NULL pointer? ... Or see pages/7_6.html ("How to declare an array of N pointers to ...
    (comp.lang.c)
  • Re: working with addresses
    ... The URL to the C FAQ has been in my sig block for years. ... what the FAQ emphasises is that those who seek to write portable code ... reason for it, and I guessed that speed might be your reason. ... likely to make for further imbalances in pointer sizes. ...
    (alt.comp.lang.learn.c-cpp)
  • Re: help alleaviate inheritance design confusion
    ... > within the bounds of Liskov Substitution Principle. ... > the base pointer to a derived object to garner access to the derived ... a.c.l.l.c-c++ FAQ: http://www.comeaucomputing.com/learn/faq ...
    (alt.comp.lang.learn.c-cpp)
  • Fixes for tar(5) format handling in pax(1)
    ... bug in paxrelated to handling pathnames of the maximum length ... prefix, linkname) to be unterminated if they fill the entire field ... if so just return a pointer to the name. ... * to find the biggest piece to fit in the name field (or the smallest ...
    (freebsd-arch)