From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: YOUNG Newsgroups: gmane.emacs.help Subject: c preprocessor and indent problem in c-mode? Date: Sun, 25 Jan 2009 16:46:38 -0800 (PST) Organization: http://groups.google.com Message-ID: <035566ec-3070-441e-8040-6f44c5c0d96c@p36g2000prp.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1232934101 8420 80.91.229.12 (26 Jan 2009 01:41:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 26 Jan 2009 01:41:41 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jan 26 02:42:54 2009 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.50) id 1LRGUw-00011c-8E for geh-help-gnu-emacs@m.gmane.org; Mon, 26 Jan 2009 02:42:46 +0100 Original-Received: from localhost ([127.0.0.1]:57779 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LRGTd-0000k2-Uz for geh-help-gnu-emacs@m.gmane.org; Sun, 25 Jan 2009 20:41:26 -0500 Original-Path: news.stanford.edu!newsfeed.stanford.edu!postnews.google.com!p36g2000prp.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 24 Original-NNTP-Posting-Host: 216.31.211.11 Original-X-Trace: posting.google.com 1232930798 17499 127.0.0.1 (26 Jan 2009 00:46:38 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Mon, 26 Jan 2009 00:46:38 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: p36g2000prp.googlegroups.com; posting-host=216.31.211.11; posting-account=1n6WnAoAAACbXH3nD5I7RQWqdkbTxZki User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.5) Gecko/2008120122 Firefox/3.0.5 (.NET CLR 3.5.30729), gzip(gfe), gzip(gfe) Original-Xref: news.stanford.edu gnu.emacs.help:166323 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:61646 Archived-At: Hi, If there is a following code, emacs does not present indent correctly. #incude int main(void) { int a = 10; #ifdef AAA if (a == 10) { printf("a:%d\n", a); #else if (b == 10) { printf("b=10\n"); #endif } #endif } If the curly brace is not closed before the preprocessor, emacs seems to confuse to make indent. Is there anyone who know this problem and how to resolve?