python: Use the print function

In Python 2, `print` was a statement, but it became a function in
Python 3.

Using print functions everywhere makes the script compatible with Python
versions >= 2.6, including Python 3.

Signed-off-by: Mathieu Bridon <bochecha@daitauha.fr>
Acked-by: Eric Engestrom <eric.engestrom@intel.com>
Acked-by: Dylan Baker <dylan@pnwbakers.com>
This commit is contained in:
Mathieu Bridon
2018-07-05 15:17:32 +02:00
committed by Dylan Baker
parent b3a42fa066
commit 0f7b18fa0d
38 changed files with 1643 additions and 1586 deletions

View File

@@ -1,3 +1,4 @@
from __future__ import print_function
template = """\
/* Copyright (C) 2015 Broadcom
@@ -68,4 +69,4 @@ from nir_opcodes import opcodes
from nir_intrinsics import INTR_OPCODES
from mako.template import Template
print Template(template).render(opcodes=opcodes, INTR_OPCODES=INTR_OPCODES)
print(Template(template).render(opcodes=opcodes, INTR_OPCODES=INTR_OPCODES))