Update of /cvsroot/wisp/wisp/users/dig
In directory sc8-pr-cvs1:/tmp/cvs-serv12316
Modified Files:
linkie.py
Log Message:
simplified Linkie.place_label
Index: linkie.py
===================================================================
RCS file: /cvsroot/wisp/wisp/users/dig/linkie.py,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -d -r1.40 -r1.41
--- linkie.py 26 Apr 2003 17:44:25 -0000 1.40
+++ linkie.py 26 Apr 2003 21:18:39 -0000 1.41
@@ -92,14 +92,9 @@
i = i - 1
referee, type, data = this._unresolved_locals[i]
if referee == label:
- if type == -1:
- this.add_byte(data, this._locals[label] - data)
- elif type == -2:
- this.add_wyde(data, this._locals[label] - data)
- elif type == -4:
- this.add_tetra(data, this._locals[label] - data)
- else:
- raise "Can't happen: unknown local reference type", this
+ if type in (-1, -2, -4):
+ this[data::-type] += this._locals[label] - data
+ else: raise "Can't happen: unknown local reference type", this
del this._unresolved_locals[i] # close the entry
def place_symbol (this, symbol, value = None):
"""place_symbol(symbol, value = None) => value
|