Re: VS2005 doesn't like its own suggestions

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



"David F" <David-White@xxxxxxxxxxxxx> wrote in message
news:OoXuPl0jFHA.320@xxxxxxxxxxxxxxxxxxxx

1. Me, as an individual doing whatever with my program, is by no means even close in its consequences to what MS does, even if both of us doing the same. When I typedef in my program, it has an effect ONLY on me. When MS does, it imposes something on just about 3 million C++ programmers.

It imposes nothing in this case. I have never used INT and never felt I needed to.

2. MS, as an irresponsible entity, on top of shaving my throat yet
another keyword - INT, kept changing its definition - so far for
"portability".

No, INT has always been a typedef for int. What has changed is the size of int (note the lowercase). It used to be 16 bit and is now 32 bit. This change was consistent with C++, which only requires that int be at least 16 bit.

You are in any event wrong to say that changes to a typedef are inconsistent
with portability. It is precisely because a typedef can be changed that it
aids portability --- you can change it to what each platform requires.

Moreover, nobody showed why INT, even if they would
not keep
changing it, contributes to portability more than if they would keep
int as 32 bit int. See again my analysis.

See again my analysis.

3. I am afraid that several participants here miss a fundamental
point.
To say that a certain OS support a certain language, means that one
can use that language, and that language alone, w/o any other "keyword",
to complete his writing.

An identifier declared by a typedef is not a keyword.

Several people here confuse the term
"extensibility". They claim that "everybody does it" - "everybody has
extentions". Extentions means adding library functions,
that can simply save time
when writing a program, but it is up to a programer to decide whether
to use those libraries on the one hand but can as well accomplish the
same result by not using them. There is no language changes here.

It is you who are confused. The C++ standard specifically makes provision for extensions which include the introduction of new keywords. In any event, there are no language changes in a typedef for INT.

Those MS' keywords & OS/compiler are changing, distort the language
and sometimes forcing me to use them in order to accomplish certain
functionality.

A compiler is compliant with the C++ standard if it will compile standard C++ code. Whether or not it will compile other code is irrelevant. Since, bugs aside, VC++ will compile essentially all standard C++ code, you are not forced to use non-standard code due to any choice by Microsoft. If you are "forced" to use non-standard code, it is because standard C++ does not support the functionality you require. The limitations of standard C++ are not Microsoft's fault. Quite frankly, you have no idea what you are talking about.

MS has no business in defining, "extending" languages. They also
don't have the capacity in doing a good job at it. They should
develop OSes, compilers, IDEs, etc. Defining a language is too big on
them (if not on almost any single
body and that is why there are bodies such as ISO).  They either
support a standard language, such as ISO C++ - FULLY and AS IS or not.
No ifs no buts.

Microsoft has defined several languages (Visual Basic and C# come to mind). We are, however, discussing making extensions to them. As noted above, standard C++ makes provision for extensions. Moreover, such extensions provide a proving ground for changes that may be incorporated into future versions of the C++ standard.

--
John Carson

.



Relevant Pages

  • Re: If you could change the C or C++ or Java syntax, what would you like different?
    ... typedef int word; ... But the language is not limited to strictly conforming programs. ... I consider it a mere artifact of circumstance or necessity that the ...
    (comp.lang.c)
  • Re: Limit names suggestions
    ... long int ... modifiers come before types (enforced rule in most non-C languages, ... as noted, I also used IMO, indicating this was a personal opinion, rather than any sort of technically-driven mandate (and also stated that this was "common practice" and hence "not actually a requirement of the language", because if it were pert of the language, then it would be a part of the language, and thus not "common practice"). ... the Standard as it exists; you'd either have to add something like ...
    (comp.std.c)
  • Re: C++ more efficient than C?
    ... If you want to do language comparisons, ... complicated algorithm, though). ... int compare ... not been in C's standard library. ...
    (comp.lang.c)
  • Re: VS2005 doesnt like its own suggestions
    ... > Java gives fixed sizes for its int variables, ... > Using a typedef is fully consistent with ISO C++. ... To say that a certain OS support a certain language, ... MS has no business in defining, ...
    (microsoft.public.vc.language)
  • Re: value of the constant expression 1<<(1?1:1) < 0x9999
    ... The behavior is inconsistent with the C standard. ... for the C language", without mention of version, so I guess C89. ... This converts the left operand, 2, from int to unsigned int. ... unsigned char, yielding 1. ...
    (comp.lang.c)