Re: Why code completion and early error checking are needed

From: Steven T. Hatton (susudata_at_setidava.kushan.aa)
Date: 06/06/04


Date: Sun, 06 Jun 2004 08:10:09 -0400

Phlip wrote:

> Petec wrote:
>
>> Please, stop trying to turn C++ into Java.
>
> Man, that's such a great way to say it.

Then you'll be happy to know this:

Concurrency: I'd like to see a library supporting threads and a related
library supporting concurrency without shared memory. [Like Java has]

Reflection: I'd like to see something like that supported through a library
defining the interface to extended type information.[Like Java has]

Persistence: I'd like to see some support in the Standard Library, probably
in connection with the extended type information, but I don't currently
have any concrete suggestions.[Like Java has]

Regular expression matching: I'd like to see a pattern-matching library in
the standard. [Like Java has]

Garbage collection: I'd like to see the C++ standard explicitly acknowledge
that it is an acceptable implementation technique for C++, specifying that
"concealed pointers" can be ignored and what happens to destructors for
collected garbage. [Like Java has]

GUI: It would be nice to have a standard GUI framework, but I don't see how
that could be politically feasible. ["Politically feasible"? Who would try
to stop that?]

Platform-independent system facilities: I'd like to see the Standard Library
provide a broader range of standard interfaces to common system resources
(where available), such as directories and sockets. [Like Java has]

>
> To do such an IDE, you'd need to re-write a compiler front-end from
> scratch. Its object model and algorithms would support event-driven
> queries from the IDE about program structure.

You'd need a lexer:
http://developer.kde.org/documentation/library/cvs-api/kdevelop/html/classLexer.html

You'd need a parser:
http://developer.kde.org/documentation/library/cvs-api/kdevelop/html/classParser.html

Something to manage the parser scheduling:
http://developer.kde.org/documentation/library/cvs-api/kdevelop/html/cpp_2backgroundparser_8cpp.html

You'd need an abstract syntax table:
http://developer.kde.org/documentation/library/cvs-api/kdevelop/html/classAST.html

You'd need something to actually do the code completion:
http://developer.kde.org/documentation/library/cvs-api/kdevelop/html/classCppCodeCompletion.html

You'd need a class to do the colorization for syntax highlighting.
http://developer.kde.org/documentation/library/cvs-api/kdevelop/html/classCppColorizer.html

> Legacy compilers are tuned for batch-mode, not on-demand mode.
>
> Nobody's going to develop two compilers, one for the editor and
> another for the production build. And nobody is going to throw away a
> legacy compiler just to ship one that bonds with an IDE. Such a
> project would destroy an entire customer base, when the compiler
> delivered different bugs than the ones all our code has grown use to.

You are speaking from a very limited perspective, and are quite wrong about
what people are likely to create.

> And these points are all peripheral. Coding is not about entering
> statements hand-over-fist, or automating that. Coding is about
> designing a minimal set of methods to support a maximal set of
> requirements. That requires emmendment and thought, not ammendment and
> rote.

You really have no idea of the kinds of things I've been working with.

> Java and its editors, by demonstrating advanced automated support for
> writing code statements, are revealing how broken a language can be
> (not that C++ any better here). If a lowly editor can predict our next
> statement, then why should the vaunted compiler force us write it?

-- 
STH 
Hatton's Law: "There is only One inviolable Law"
KDevelop: http://www.kdevelop.org  SuSE: http://www.suse.com
Mozilla: http://www.mozilla.org


Relevant Pages

  • compile error on alpha - binutils problem?
    ... {standard input}:246: Error: macro requires $at register while noat in effect ... # PCCARD support ...
    (Linux-Kernel)
  • Re: COBOL COMPILER BLUES...
    ... I'm pretty sure Walter is still on the list, ... engineer providing lab support for the compiler, ... product and required little support. ... The standard does not address such things as how the compiler ...
    (comp.sys.hp.mpe)
  • Re: Integer Coersion
    ... and as this is Fortran not Delphi, ... vaguely standard conforming. ... It would be amazingly stupid of a compiler vendor to not support a byte-sized integer. ...
    (comp.lang.fortran)
  • Re: 128 bit integers is on topic
    ... what is not in the list of standard headers. ... printf format and scanf format are a problem in my case as well. ... the cost then, is that printf does not support 128-bit ints, or even 64-bit ... in my compiler, they are supported natively in both 32 and 64 bit mode. ...
    (comp.lang.c)
  • Re: New Ethiopian Find - Oldest Biped At 3.8-4 mya
    ... >> This is not an example of a double standard. ... > criticise arguments you don't support for not ... *elimination of human hair as it relates to swimming. ... primarily--neither set out to address hair reduction) required a rather ...
    (sci.anthropology.paleo)