Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0007257opensim[REGION] Scripting Enginepublic2014-07-08 20:452014-07-08 20:45
Reporterlee+ 
Assigned To 
PrioritynormalSeverityblockReproducibilityalways
StatusnewResolutionopen 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0007257: scripts do not compile
DescriptionScripts with a statement like

(status += 32 * !(status & 32));

do not compile. A statement like this comes from the expansion of a preprocessor macro. The macro is called 'SetStatus' in this case. I need it in my scripts --- which run through cpp --- for status handling.

The brackets around the statement are not required in above example. They are required because the macro can be used in an expression like

var1 = var2 * SetStatus(stSOMESTATUS) + var3;

The same goes for other macros that expand to assignments, like replacing elements of a list, for example. The result of an assignment can be used itself as a value, like

var1 = var2 = var3 = 25;

Using macros introduces brackets which are not needed in all instances. However:

+ these brackets don't hurt anything
+ the scripts compile just fine in second life

The syntax check that prevents scripts as described from compiling breaks compatibility with sl for no advantage at all. It should be removed, or changed so that the scripts compile.

It breaks pretty much all my scritps.
Additional InformationI tried this on some sims of Metropolis. I haven't tried other grids; the scripts compile without issues in sl.

I don't know what run mode etc. is used with the Metropolis grid.
TagsNo tags attached.
Git Revision or version number
Run ModeStandalone (1 Region)
Physics EngineBasicPhysics
Script Engine
EnvironmentUnknown
Mono VersionOther
Viewer
Attached Files

- Relationships

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2014-07-08 20:45 lee+ New Issue


Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker