Raymond Hettinger wrote: >> I think it's convenient but also rather odd that split() with a static >> string argument was moved from module string to a method in class str, >> while split() with a regexp has remained in module re. > > I don't see what you find odd. With str and unicode objects being > builtin, you don't need a separate module. In contrast, re is a > stand-alone extension which, of course, requires an import.
That's an implementation oriented view. IMHO it is all a match-and-cut operation with fixed strings the simplest form of match expressions. From that point of view the distinction between the two is quite arbitrary. Of course, when turning from principles to daily practice again it is quite clear the distinction is useful. --eric _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com