Allow /* C-style comments */ in LSL scripts.
This fixes Mantis #3199. opensim-libs SVN r87 contains the corresponding changes.GenericGridServerConcept
parent
6515d8be0e
commit
64c14d2475
|
@ -368,6 +368,35 @@ default
|
|||
Assert.AreEqual(expected, output);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestCStyleComments()
|
||||
{
|
||||
string input = @"/* this test tests comments
|
||||
of the C variety
|
||||
*/
|
||||
default
|
||||
{
|
||||
touch_start(integer num_detected) /* this should be stripped */
|
||||
{
|
||||
/*
|
||||
* fill
|
||||
* in
|
||||
* code
|
||||
* here...
|
||||
*/
|
||||
}
|
||||
}
|
||||
";
|
||||
string expected =
|
||||
"\n public void default_event_touch_start(LSL_Types.LSLInteger num_detected)" +
|
||||
"\n {" +
|
||||
"\n }\n";
|
||||
|
||||
CSCodeGenerator cg = new CSCodeGenerator();
|
||||
string output = cg.Convert(input);
|
||||
Assert.AreEqual(expected, output);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestGlobalDefinedFunctions()
|
||||
{
|
||||
|
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue