From 8cd842a41a55ab3d8f558a2e3e198beba7da58a1 Mon Sep 17 00:00:00 2001 From: Hamilton Kibbe Date: Thu, 21 Jan 2016 03:57:44 -0500 Subject: Manually mere rendering changes --- gerber/am_read.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'gerber/am_read.py') diff --git a/gerber/am_read.py b/gerber/am_read.py index 65d08a6..4aff00b 100644 --- a/gerber/am_read.py +++ b/gerber/am_read.py @@ -26,7 +26,8 @@ import string class Token: ADD = "+" SUB = "-" - MULT = ("x", "X") # compatibility as many gerber writes do use non compliant X + # compatibility as many gerber writes do use non compliant X + MULT = ("x", "X") DIV = "/" OPERATORS = (ADD, SUB, MULT[0], MULT[1], DIV) LEFT_PARENS = "(" @@ -62,6 +63,7 @@ def is_op(token): class Scanner: + def __init__(self, s): self.buff = s self.n = 0 @@ -111,7 +113,8 @@ class Scanner: def print_instructions(instructions): for opcode, argument in instructions: - print("%s %s" % (OpCode.str(opcode), str(argument) if argument is not None else "")) + print("%s %s" % (OpCode.str(opcode), + str(argument) if argument is not None else "")) def read_macro(macro): -- cgit