Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0005905opensim[REGION] Scripting Enginepublic2012-02-22 11:432012-02-22 11:52
ReporterDigi Fly 
Assigned To 
PrioritylowSeverityminorReproducibilityalways
StatusnewResolutionopen 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0005905: Incorrect LSL syntax code dont trigger LSL error.
DescriptionIf i use the following example program in opensim:

string message = "Colors-256";

default
{
    touch_end(integer num_detected)
    {
        if (llStringLength(llGetSubString(message, 0, 6))=="Colors-")
        {
            llSay(0,message);
        }
    }
}

everything works fine. If i copy the same lsl program to Secondlife i get a
(6 , 68 ) : ERROR : Type Mismatch.
That error is complete correct. because the right code would be

string message = "Colors-256";

default
{
    touch_end(integer num_detected)
    {
        if (llGetSubString(message, 0, 6)=="Colors-")
        {
            llSay(0,message);
        }
    }
}

The problem is (user error) i try to compare integer with string.
other words " Function: integer llStringLength( string str ); "
Opensim seems to be relaxed with this code mistake , it works fine. but SL tels you that its wrong, and that make more sense, you cant compare integer with string i the IF line.
TagsNo tags attached.
Git Revision or version numbera27e5a9c956be2150d52340543b5eec74a76f28d
Run Mode Grid (1 Region per Sim)
Physics EngineODE
Script Engine
EnvironmentMono / Linux64
Mono Version2.10
Viewer
Attached Files

- Relationships

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2012-02-22 11:43 Digi Fly New Issue


Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker