At my request, John Hunter put a feature in the 'load' subroutine in
Pylab which treats everything after a '%' sign as a comment. This makes
it more compatible with MATLAB (tm); I use this feature to comment
files which would otherwise be simple lists of numbers. However, there
is a small bug. Line 851 in pylab.py should change from
line = line[:line.rfind('%')].strip()
to
line = line[:line.find('%')].strip()
since everything after a '%' sign should be treated as a comment. This
bit me when I had a comment line where the comment itself included a % sign.
|