From: Sebastien Bourdeauducq Date: Mon, 9 Jan 2012 14:17:24 +0000 (+0100) Subject: record: better exception code X-Git-Tag: 24jan2021_ls180~2099^2~1088 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=cef1c5d3afff6d8feeb04487ba4b30a385917d68;p=litex.git record: better exception code --- diff --git a/migen/corelogic/record.py b/migen/corelogic/record.py index 59b5cc2d..e3862c34 100644 --- a/migen/corelogic/record.py +++ b/migen/corelogic/record.py @@ -42,8 +42,8 @@ class Record: pos_fields = fields for hop in path: pos_self = getattr(pos_self, hop) + lu = list(filter(lambda x: x[0] == hop, pos_fields)) try: - lu = list(filter(lambda x: x[0] == hop, pos_fields)) pos_fields = lu[0][1] except IndexError: n = []