]> code.ossystems Code Review - openembedded-core.git/commitdiff
bb.pysh: add Case support to format_commands
authorChris Larson <chris_larson@mentor.com>
Thu, 11 Nov 2010 15:57:15 +0000 (08:57 -0700)
committerRichard Purdie <rpurdie@linux.intel.com>
Tue, 4 Jan 2011 14:46:39 +0000 (14:46 +0000)
(Bitbake rev: 6e24f573a0e95068eb9237c1d264ad1148b2f690)

Signed-off-by: Chris Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
bitbake/lib/bb/pysh/pyshyacc.py

index 6b2bf466d22c583b81363d725e2eeaa91424cdf6..8bb992732112adb23dbe75c5737c57bb04bb6a7d 100644 (file)
@@ -707,6 +707,9 @@ def format_commands(v):
         if v.reverse_status:
             name = '!' + name
         return [name, format_commands(v.commands)]
+    elif isinstance(v, Case):
+        name = ['Case']
+        name += [v.name, format_commands(v.items)]
     elif isinstance(v, SimpleCommand):
         name = ['SimpleCommand']
         if v.words: