summaryrefslogtreecommitdiff
path: root/dtc-lexer.l
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2007-06-07 12:07:35 +1000
committerJon Loeliger <jdl@freescale.com>2007-06-06 21:51:49 -0500
commit41eecd4c2acaca01295fdb48ddc9ec5520f5a7d4 (patch)
tree296f61ef40b6ee058c013df105ed2cc61a1e18a8 /dtc-lexer.l
parent7ea144f4c0b47c6f25cb4862b3299b7e5d7f7813 (diff)
downloaddtc-41eecd4c2acaca01295fdb48ddc9ec5520f5a7d4.tar.gz
dtc: Fix recognition of whitespace characters
At present, the lexer in dtc recognizes only space, tab and newline as whitespace characters. This is broken; in particular this means that dtc will get syntax errors on files with DOS-style (CR-LF) newlines. This patch fixes the problem, using flex's built-int [:space:] character class. Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'dtc-lexer.l')
-rw-r--r--dtc-lexer.l2
1 files changed, 1 insertions, 1 deletions
diff --git a/dtc-lexer.l b/dtc-lexer.l
index d237181..77ccd54 100644
--- a/dtc-lexer.l
+++ b/dtc-lexer.l
@@ -27,7 +27,7 @@
PROPCHAR [a-zA-Z0-9,._+*#?-]
UNITCHAR [0-9a-f,]
-WS [ \t\n]
+WS [[:space:]]
REFCHAR ({PROPCHAR}|{UNITCHAR}|[/@])