<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD><TITLE></TITLE>
<STYLE>
body, table, tr, td, p {margin: 0px 0px 0px 0px}
.bgtabl {BACKGROUND-REPEAT: no-repeat}
</STYLE>
</HEAD>
<BODY bgProperties="fixed" bgcolor="#FFFFFF" background="http://flashimg.club-internet.fr/flash/vide.gif">
Hello everybody,<br>
<br>
I just like to know what all of you think of adding this functionnality
to python language, or  any other object oriented language in fact.<br>
<br>
(English is not my natural language so please e-mail if you can improve this text...)<br>
<br>
 x.( ... ? ... )  could be equivalent to ( ... x ... ) <br>
<br>
So an expression such as :<br>
(1)  html.stringtohtml(''.join(a.strip().split('/n')[:-1])).lower()<br>
<br>
could be replaced with :<br>
(2)   a.strip().split('/n')[:-1].(''.join(?)).(html.stringtohtml(?)).lower()<br>
<br>
(in this example html would be a module containing the function stringtohtml) <br>
The advantages of such a notation :<br>
<br>
- The order of operations always follows the (occidental?) reading
order, from left to right.  (in the formulation (1), we have a
mixed of right-to-left reading and left-to-right reading.)<br>
<br>
- The number of nested levels  - limited to 2 levels of
parenthesis - does not grow with the number of successive operations
(it  soon gives problems with formulation (1)). <br>
This is a bit like in math you improve readability replacing
f(g(h(j(x))) with f o g o h o j (x), except here this would be roughly
looking like x.(j).(h).(g).(h)<br>
<br>
Then you get other advantages :<br>
<br>
- The growth of complexity in formulation (1) leads to the use of
intermediates computations which introduces unusefull intermediates
variables (they are just used once)<br>
b = a.strip().split('/n')[:-1]<br>
c = ''.join(b)<br>
d = html.stringtohtml(c).lower()<br>
These 3 intermediate variables used to improve readability can
introduce bugs : you have to check that b, c and d are not used
anywhere else in the code.<br>
With notation (2), you minimise the use of unusefull intermediate variables.<br>
<br>
- Builtins classes do not have to have many mumber fonctions. For
example, though string class does not have any member function "tohtml"
giving the ability to write s.tohtml() , you can still write
s.(html.texttohtml(?)) or simplier  s.(texttohtml(?)) after
an  import html.texttohtml<br>
<br>
I'd like to have your opinions about that...<br>
<br>
Daniel Delay.<br>
 
<br>




</body></html>