[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Emacs contributions, C and Lisp

From: Eli Zaretskii
Subject: Re: Emacs contributions, C and Lisp
Date: Tue, 25 Feb 2014 23:12:07 +0200

> From: Óscar Fuentes <address@hidden>
> Date: Tue, 25 Feb 2014 20:50:11 +0100
> Eli Zaretskii <address@hidden> writes:
> >> Nobody can parse C++ reliably.  GCC has given up on trying to teach
> >> Bison (aka LALR(1) and then some) how to parse C++ and has implemented
> >> its own hand-written parser.
> >
> > I understand the potential difficulties, but since we only need a
> > relatively small part of parsing,
> Why do we need a small part of parsing? For implementing C++ smart
> completion on a reliable way, you need semantic analysis.

Can you explain why?  I'm probably missing something.

> Furthermore, people here are talking too much about completion

Well, that's the only thing that clang has that prompted this thread,

> but there are other features that require whole-program semantic
> analysis and hence are out of reach of the approaches mentioned here
> based on gcc spitting not-quite-comprehensive information.

Can you list those features?

> > perhaps it's worth trying first?  If push comes to shove, what was
> > implemented in GCC can be reimplemented in Emacs Lisp, no?
> Right now the available systems for smart code completion are annoyingly
> slow. They are implemented on C/C++. It is reasonable to expect from a
> Elisp-based solution to be unbearably slow, not to mention the
> complexity.

We can always prototype in Lisp, then reimplement the slow parts in C
if needed.

> Why reinvent the wheel?

Because we cannot get the one that's already invented?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]