Mesa (master): mesa: Avoid set comprehension.

Vinson Lee vlee at kemper.freedesktop.org
Wed Jul 5 19:48:56 UTC 2017


Module: Mesa
Branch: master
Commit: 95731b7ccc605bbfe2c3cb3d533219bc0788cbaa
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=95731b7ccc605bbfe2c3cb3d533219bc0788cbaa

Author: Vinson Lee <vlee at freedesktop.org>
Date:   Wed Jun 28 23:13:26 2017 -0700

mesa: Avoid set comprehension.

Fix build error on CentOS 6.9 with Python 2.6.

  GEN    main/format_fallback.c
  File "./main/format_fallback.py", line 42
    names = {fmt.name for fmt in formats}
                        ^
SyntaxError: invalid syntax

Fixes: a1983223d883 ("mesa: Add _mesa_format_fallback_rgbx_to_rgba() [v2]")
Signed-off-by: Vinson Lee <vlee at freedesktop.org>
Reviewed-by: Dylan Baker <dylan at pnwbakers.com>

---

 src/mesa/main/format_fallback.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/main/format_fallback.py b/src/mesa/main/format_fallback.py
index e3b9916f6e..7782e493d1 100644
--- a/src/mesa/main/format_fallback.py
+++ b/src/mesa/main/format_fallback.py
@@ -39,7 +39,7 @@ def parse_args():
     return p.parse_args()
 
 def get_rgbx_to_rgba_map(formats):
-    names = {fmt.name for fmt in formats}
+    names = set(fmt.name for fmt in formats)
 
     for fmt in formats:
         if not fmt.has_channel('r') or not fmt.has_channel('x'):




More information about the mesa-commit mailing list