Show More
@@ -5,7 +5,7 b' General purpose utilities.' | |||||
5 | This is a grab-bag of stuff I find useful in most programs I write. Some of |
|
5 | This is a grab-bag of stuff I find useful in most programs I write. Some of | |
6 | these things are also convenient when working at the command line. |
|
6 | these things are also convenient when working at the command line. | |
7 |
|
7 | |||
8 |
$Id: genutils.py 26 |
|
8 | $Id: genutils.py 2661 2007-08-22 20:43:34Z vivainio $""" | |
9 |
|
9 | |||
10 | #***************************************************************************** |
|
10 | #***************************************************************************** | |
11 | # Copyright (C) 2001-2006 Fernando Perez. <fperez@colorado.edu> |
|
11 | # Copyright (C) 2001-2006 Fernando Perez. <fperez@colorado.edu> | |
@@ -1008,6 +1008,15 b' class SList(list):' | |||||
1008 |
|
1008 | |||
1009 | p = paths = property(get_paths) |
|
1009 | p = paths = property(get_paths) | |
1010 |
|
1010 | |||
|
1011 | def print_slist(arg): | |||
|
1012 | """ Prettier (non-repr-like) and more informative printer for SList """ | |||
|
1013 | print "SList (.p, .n, .l, .s available). Value:" | |||
|
1014 | nlprint(arg) | |||
|
1015 | ||||
|
1016 | print_slist = result_display.when_type(SList)(print_slist) | |||
|
1017 | ||||
|
1018 | ||||
|
1019 | ||||
1011 | #---------------------------------------------------------------------------- |
|
1020 | #---------------------------------------------------------------------------- | |
1012 | def esc_quotes(strng): |
|
1021 | def esc_quotes(strng): | |
1013 | """Return the input string with single and double quotes escaped out""" |
|
1022 | """Return the input string with single and double quotes escaped out""" |
General Comments 0
You need to be logged in to leave comments.
Login now