| OpenSim Discussion Discuss development, use, and support issues related to the OpenSim project. |
| |
![]() |
| | LinkBack | Thread Tools | Display Modes |
| | #1 (permalink) |
| Senior Member ![]() ![]() ![]() ![]() ![]() ![]() SLU Supporter ![]() ![]() ![]() ![]() ![]()
Running 'round in Circle's
Join Date: Sep 2007 Location: Australia
Posts: 6,949
My Mood: SLShopper Ads: 1 SL Join Date: 12-Oct-2003
Business: Psyke's Defence Systems Blog Entries: 3 | I have noticed a divergence with OpenSim LSL and SecondLife LSL. Code: default
{
state_entry()
{
list llist = ["a","b"];
llist = (llist=[]) + llist + ["c"];
llSay(0, llDumpList2String(llist,"|"));
}
}
In SL llist will become ["a","b","c"]; However is OpenSim XEngine (at least) llist will become ["c"] Is this a bug, or should we stop using OpenSim for SL development due to divergence in how things work? However.. Code: default
{
state_entry()
{
list llist = ["a","b"];
llist += (llist=[]) + ["c"];
llSay(0, llDumpList2String(llist,"|"));
}
}
OpenSim warning: "Warning: Multiple assignments to 'list' at line 5 column 19; results may differ between LSL and OSSL."
__________________ |
| | |
| | #3 (permalink) | |
| Senior Member ![]() ![]() ![]() ![]()
Beeble Bubble Bimbo
Join Date: Aug 2007 Location: Darkmere
Posts: 3,885
My Mood: SLShopper Ads: 22 SL Join Date: October 24, 2006
Business: Cortech Enterprises | Quote:
llist = (llist=[]) + llist + ["c"]; Besides that some languages any "assignment" value would return TRUE (a=1) = TRUE So you could possibly get a 'type mismatch' as you are trying to add a logical value to a list without typecasting it first. At best you would assume that it would do correct order-of-operation: The problem being you don't know whether it'll get the value of llist rewritten to [] before it adds it in a second time. Mutters about memory recall/write vs. processing cyles and timings and stuff I used to know a lot more about. LSL is goofy. ![]() It's not so much a divergence in processing as to how a different platform copes with a logically 'questionable' script line. | |
| | |
| 1 User Said Thanks: |
| | #4 (permalink) |
| Senior Member ![]() ![]() ![]() ![]() ![]() ![]() SLU Supporter ![]() ![]() ![]() ![]() ![]()
Running 'round in Circle's
Join Date: Sep 2007 Location: Australia
Posts: 6,949
My Mood: SLShopper Ads: 1 SL Join Date: 12-Oct-2003
Business: Psyke's Defence Systems Blog Entries: 3 | Even so it begs the bigger question. Can OpenSim in the future be used to develop for SecondLife? Or will the differences become too much. Whilst I agree that having to do the above to save memory is stupid, it is extremely useful when limited to 64kb. It would become tedious if, to develop code on OpenSim, we had to edit it after transfering to SL. I hope they keep 100% "goofy" LSL compatibility whilst also developing all the other compatibilities. |
| | |
| 1 User Agreed: |
| | #5 (permalink) |
| Senior Member ![]() ![]() ![]() ![]()
Beeble Bubble Bimbo
Join Date: Aug 2007 Location: Darkmere
Posts: 3,885
My Mood: SLShopper Ads: 22 SL Join Date: October 24, 2006
Business: Cortech Enterprises | It's tricky to ensure compatibility for things that are basically hacks that work on sluggish processors. |
| | |
| | #6 (permalink) |
| Senior Member ![]() ![]() ![]() ![]() ![]() ![]() SLU Supporter ![]() ![]() ![]() ![]()
Better than Joshua at worms
armageddon.
Join Date: Sep 2007 Location: Perth, Orstraya.
Posts: 3,210
My Mood: SL Join Date: 9-Jan-04
Business: Azure Islands | I know the list hack has been a point of contention - since to support the SL order of operations there requires rewriting parts of the LSL Lexer/Parser we use. There's a bug on the mantis about it. 0003187: popular list memory saving hack does not work in LSL - Mantis |
| | |
| 1 User Said Yay!: |
| 3 Users Said Thanks : |
| | #7 (permalink) |
| Senior Member ![]() ![]() ![]() ![]() ![]() ![]() SLU Supporter ![]() ![]() ![]() ![]() ![]()
Running 'round in Circle's
Join Date: Sep 2007 Location: Australia
Posts: 6,949
My Mood: SLShopper Ads: 1 SL Join Date: 12-Oct-2003
Business: Psyke's Defence Systems Blog Entries: 3 | I guess I had better update my OpenSim |
| | |
![]() |
| Tags |
| divergence, lsl, opensim, ossl, secondlife |
| Thread Tools | |
| Display Modes | |
| |