| time |
nick |
message |
14:42 |
<Udai> |
Hi Ralf |
14:42 |
<ralf> |
hi udai |
14:42 |
<Udai> |
I am having trouble with this add implementation |
14:43 |
<Udai> |
do you have time? |
14:44 |
<Udai> |
or should I just try more....... |
14:46 |
<Udai> |
anyway the problem the list |
14:47 |
<Udai> |
everytime I create an instance of add object a new list is being created |
14:58 |
<ralf> |
that's the expected behaviour |
15:02 |
<Udai> |
I think I just solved the problem |
15:02 |
<ralf> |
okay |
15:02 |
<Udai> |
I don't understand why this was happing ...let me try to explain |
15:03 |
<ralf> |
i'll see your solution when reviewing the patch |
15:03 |
<Udai> |
I was creating ArrayList in getMethod if the list property is found null |
15:03 |
<Udai> |
this way doesn't work |
15:04 |
<Udai> |
I just created a ArrayList at implementation (AbstractExp) and it begins to work as expected |
15:05 |
<ralf> |
okay |
15:05 |
<Udai> |
also I have created two list of exp one for additive and other for multiplicative |
15:07 |
<Udai> |
I think I should have just bugged you earlier as it solved my problem ;) |
15:07 |
<ralf> |
this doesn't sound rigth to me |
15:08 |
<ralf> |
i think there should only be one list |
15:08 |
<ralf> |
but i'll see what you did at review |
15:08 |
<Udai> |
first additive comes in () and then multiplicative in () |
15:09 |
<Udai> |
((field <additives list>) <multiplicative list>) |
15:11 |
<ralf> |
how about: (a*b+c*d)*e+f |
15:14 |
<ralf> |
you assumed a specific order of operations |
15:14 |
<ralf> |
but add and mult expressions can occure in any order |
15:21 |
<Udai> |
like field.add(4).multiply(8).add(3) |
15:21 |
<Udai> |
will be ((field + 4 + 3) * 8) |
15:22 |
<Udai> |
so this is wrong |
15:23 |
<Udai> |
it should be (((field +4)*8)+3) |