Changeset 3275


Ignore:
Timestamp:
Dec 2, 2010 9:35:52 PM (10 years ago)
Author:
jwatson
Message:

Fixing Python 2.5-related issue with string.translate in phutils.py - using None as the translation table is not allowed in Python 2.5.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • coopr.pysp/trunk/coopr/pysp/phutils.py

    r3217 r3275  
    102102   # replace all parens in the string with commas and
    103103   # proceed with the split.
    104    full_index=string.translate(full_index, None, "()")
     104   full_index=string.translate(full_index, string.maketrans("",""), "()")
    105105   indices = full_index.split(',')
    106106
     
    116116      # strings. remove these, as otherwise you have an
    117117      # illegal index.
    118       index=string.translate(index, None, "\'")
     118      index=string.translate(index, string.maketrans("",""), "\'")
    119119
    120120      # if the index is an integer, make it one!
Note: See TracChangeset for help on using the changeset viewer.