From: Finn B. <bc...@us...> - 2001-03-13 20:25:44
|
Update of /cvsroot/jython/jython/org/python/modules In directory usw-pr-cvs1:/tmp/cvs-serv28771 Modified Files: operator.java Log Message: Added docstring. Index: operator.java =================================================================== RCS file: /cvsroot/jython/jython/org/python/modules/operator.java,v retrieving revision 2.5 retrieving revision 2.6 diff -C2 -r2.5 -r2.6 *** operator.java 2001/02/02 11:29:42 2.5 --- operator.java 2001/03/13 20:27:43 2.6 *************** *** 81,84 **** --- 81,94 ---- public class operator implements ClassDictInit { + public static PyString __doc__ = new PyString( + "Operator interface.\n"+ + "\n"+ + "This module exports a set of functions implemented in C corresponding\n"+ + "to the intrinsic operators of Python. For example, operator.add(x, y)\n"+ + "is equivalent to the expression x+y. The function names are those\n"+ + "used for special class methods; variants without leading and trailing\n"+ + "'__' are also provided for convenience.\n" + ); + public static void classDictInit(PyObject dict) { dict.__setitem__("__add__", new OperatorFunctions("__add__", 0, 2)); |