From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Fren Zeee Newsgroups: gmane.emacs.help Subject: [OT] Re: What is the best way to navigate #ifdef and #endif in C program Date: Tue, 3 Aug 2010 21:45:31 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <53f62f81-fb10-4fb6-87ce-0eb5609d12f5@h17g2000pri.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1291857812 3443 80.91.229.12 (9 Dec 2010 01:23:32 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 9 Dec 2010 01:23:32 +0000 (UTC) Cc: Fren Zeee To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Dec 09 02:23:28 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PQVEF-0002W7-JE for geh-help-gnu-emacs@m.gmane.org; Thu, 09 Dec 2010 02:23:27 +0100 Original-Received: from localhost ([127.0.0.1]:36803 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PQVEF-0008Pd-0k for geh-help-gnu-emacs@m.gmane.org; Wed, 08 Dec 2010 20:23:27 -0500 Original-Path: usenet.stanford.edu!postnews.google.com!f42g2000yqn.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help, comp.unix.shell, comp.lang.c, comp.lang.lisp, comp.lang.scheme Original-Lines: 37 Original-NNTP-Posting-Host: 75.31.77.123 Original-X-Trace: posting.google.com 1280897131 3647 127.0.0.1 (4 Aug 2010 04:45:31 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Wed, 4 Aug 2010 04:45:31 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: f42g2000yqn.googlegroups.com; posting-host=75.31.77.123; posting-account=Xy1x0QoAAAC1_8XWVbTILoO5VL5JMCDm User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; {83B3ACED-AC9F-2058-FD69-DBCDCD722B97}; (R1 1.5)),gzip(gfe) Original-Xref: usenet.stanford.edu gnu.emacs.help:180338 comp.unix.shell:246329 comp.lang.c:979361 comp.lang.lisp:290870 comp.lang.scheme:87264 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:76377 Archived-At: On Aug 2, 5:31=A0pm, "Daniel (Youngwhan)" wrote: > Hi, > > If there is curly brace, it is easy to navigate between them by M-C-f > and M-C-b in c-mode. > > However, I cannot find a way to navigate in like curly brace when it > comes to #ifdef, #else, and #endif. > > For example, if there is a code like this: > > #ifdef A_DEFINED > (...100 lines) > #else > (... 500 lines) > #endif > > , is there a easy way to move the cursor from #endif to #ifdef or > #else and vice versa? > > Daniel You might get better luck posting in a C group also. I use #ifdef ... #endif often also to comment out blocks of code during debugging. My question to CLISP/ELISP/scheme people is If there is a wrapper do nothing type function in elisp/clisp/scheme which can have the same effect as commenting out. This is because I dont like to do comment-region/uncomment-region in emacs. These three lispy languages dont seem to have comment block construct like C ie /* and */