Add emacs mode line and escape ' and " so it looks more like C.
authorJohan Dahlin <johan@gnome.org>
Thu, 27 Dec 2007 22:43:41 +0000 (22:43 +0000)
committerJohan Dahlin <johan@src.gnome.org>
Thu, 27 Dec 2007 22:43:41 +0000 (22:43 +0000)
2007-12-27  Johan Dahlin  <johan@gnome.org>

* src/scannerlexer.l (intsuffix): Add emacs mode line and
escape ' and " so it looks more like C.

svn path=/trunk/; revision=91

ChangeLog
src/scannerlexer.l

index dd03ea0..9f0836b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2007-12-27  Johan Dahlin  <johan@gnome.org>
 
+       * src/scannerlexer.l (intsuffix): Add emacs mode line and
+       escape ' and " so it looks more like C.
+
        * src/scanner.c:
        Unlink temporary file used.
 
index cbb9753..953ebf2 100644 (file)
@@ -1,3 +1,4 @@
+/* -*- Mode: C -*-
 /* GObject introspection: C lexer
  *
  * Copyright (c) 1997 Sandro Sigala  <ssigala@globalnet.it>
@@ -47,12 +48,12 @@ intsuffix                           ([uU][lL]?)|([lL][uU]?)
 fracconst                              ([0-9]*\.[0-9]+)|([0-9]+\.)
 exppart                                        [eE][-+]?[0-9]+
 floatsuffix                            [fFlL]
-chartext                               ([^'])|(\\.)
-stringtext                             ([^"])|(\\.)
+chartext                               ([^\'])|(\\.)
+stringtext                             ([^\"])|(\\.)
 
 %%
 
-"\n"                                   { ++lineno; }
+"\n"                                   { ++lineno; } /* " */
 [\t\f\v\r ]+                           { /* Ignore whitespace. */ }
 
 "/*"                                   { skip_comment(); }