From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Engster Newsgroups: gmane.emacs.devel Subject: Re: CEDET merge question Date: Sun, 06 Sep 2009 23:11:06 +0200 Message-ID: <87k50bixsl.fsf@engster.org> References: <87eiql2w5s.fsf@cyd.mit.edu> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1252271498 16289 80.91.229.12 (6 Sep 2009 21:11:38 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 6 Sep 2009 21:11:38 +0000 (UTC) Cc: Chong Yidong , rms@gnu.org, emacs-devel@gnu.org To: Ken Raeburn Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Sep 06 23:11:31 2009 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MkP1F-00086y-MJ for ged-emacs-devel@m.gmane.org; Sun, 06 Sep 2009 23:11:29 +0200 Original-Received: from localhost ([127.0.0.1]:59205 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MkP1F-0008U3-0Y for ged-emacs-devel@m.gmane.org; Sun, 06 Sep 2009 17:11:29 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MkP18-0008SE-Rh for emacs-devel@gnu.org; Sun, 06 Sep 2009 17:11:22 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MkP17-0008Ox-Iz for emacs-devel@gnu.org; Sun, 06 Sep 2009 17:11:21 -0400 Original-Received: from [199.232.76.173] (port=52148 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MkP17-0008Ok-AB for emacs-devel@gnu.org; Sun, 06 Sep 2009 17:11:21 -0400 Original-Received: from m61s02.vlinux.de ([83.151.21.164]:44213) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MkP14-0002ZH-2g; Sun, 06 Sep 2009 17:11:18 -0400 Original-Received: from dslc-082-083-036-141.pools.arcor-ip.net ([82.83.36.141] helo=void) by m61s02.vlinux.de with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.69) (envelope-from ) id 1MkP0v-0000cG-8r; Sun, 06 Sep 2009 23:11:09 +0200 In-Reply-To: (Ken Raeburn's message of "Sun, 6 Sep 2009 13:46:58 -0400") User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/23.1 (gnu/linux) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:115070 Archived-At: Ken Raeburn writes: > On Sep 6, 2009, at 11:37, Richard Stallman wrote: >> Is it possible to use Bison itself rather than implement the >> same functionality differently? Or perhaps add an option >> to Bison to output its data in whatever format is convenient? > > Guile is also using a translation/reimplementation of Bison in Scheme. > I haven't looked at the CEDET code, but Guile's version wants the > grammar input using Scheme (s-expression) syntax. CEDET uses Bison grammars which are extended through "Optional Lambda Expressions" (OLE). They produce the actual tags, which are the basic objects resulting from the parsing stage. I don't think this can be easily replaced by Bison itself or Guile. But there's really not that much additional framework associated with Bison/Bovine. In the 'bovine' subdirectory, there are the actual grammar files (like c.by, erlang.by, etc.), and the major- and debugging-modes (bovine-grammar.el, bovine-debug.el). I think they are really only needed for developing and testing grammars. The file semantic-bovine.el contains the parsing core and is crucial. Then, there are files which deal with language-specific issues, for example semantic-c.el, semantic-erlang.el, semantic-java.el, etc.. These files contain overrides and helper functions to deal with stuff which usually differs between languages, like smart completion, local variables, namespaces and scoping issues, special preprocessor macros, etc. These files are only crucial for parsing the named language. The file semantic-gcc.el sets up stuff like system include paths for C/C++ by looking at the local gcc installation; it's very helpful for people using gcc. The files semantic-skel.el and skeleton.by are just there to get people started developing their own grammars and overrides; I think they can be safely dropped. As mentioned in my previous mail, the files semantic--by.el result from the compilation of the *.by files and could probably just be provided 'as is' in Emacs, without the additional grammar developing framework (this also implies that files could not just get synced from CEDET CVS to Emacs, but would need a compilation step in between). I can't speak for Eric here, of course. Maybe there's some not-so-obvious dependency, or another good reason to include the full grammar framework. Regards, David