unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Another small problem of CC Mode
@ 2007-01-12  1:58 Herbert Euler
  2007-01-12  2:05 ` Herbert Euler
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Herbert Euler @ 2007-01-12  1:58 UTC (permalink / raw)


Hi,

In a file that contains C program like this:

    extern void g(void);
    extern void h(void);

    int
    f(void)
    {
            do {
    #ifdef M1
            } while (g());
    #else
            } while (h());
    #endif /* M1 */
    }

Many functions in CC mode will behave incorrectly:
`c-beginning-of-defun' and `c-end-of-defun' cannot go to the right
place; `c-indent-command' cannot indent to the right column;
`c-electric-brace' tells an error, which is not, when typing the `}'
that finishes the function `f'; and so on.

Of course, this is rare.  But will making CC Mode detect this
situation and behave in a right way need much effort?

Thanks in advance.

Regards,
Guanpeng Xu

_________________________________________________________________
FREE pop-up blocking with the new MSN Toolbar - get it now! 
http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2007-01-13  2:12 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-01-12  1:58 Another small problem of CC Mode Herbert Euler
2007-01-12  2:05 ` Herbert Euler
2007-01-12  3:13 ` Alfred M. Szmidt
2007-01-12  9:03 ` Alan Mackenzie
2007-01-12 10:06   ` Herbert Euler
2007-01-13  2:12     ` Miles Bader

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).