]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
pysh: Say what kind of token isn't implemented
authorOlof Johansson <olof.johansson@axis.com>
Tue, 7 May 2013 09:22:37 +0000 (11:22 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 10 May 2013 12:33:58 +0000 (13:33 +0100)
When the shell lexer finds an unrecognized dollar token, the error
message should contain what kind of token it is having problems with.

Signed-off-by: Olof Johansson <olof.johansson@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
lib/bb/pysh/pyshlex.py

index b977b5e869c2e7b9b93d4fa343a999c5fe98d031..b30123675c1b1cc43a79615f98180d02331bc48a 100644 (file)
@@ -292,7 +292,7 @@ class WordLexer:
         elif sep=='${':
             parsefunc = self._parse_parameter
         else:
-            raise NotImplementedError()
+            raise NotImplementedError(sep)
             
         pos, closed = parsefunc(buf, result, eof)
         return pos, closed