Comma-separated expressions

  • Updated

Individual irScript expressions may be grouped into a single statement by separating each expression with a comma:

var x = 10, y = true, z = [ 1, 3, 5 ];

var isCollection = x.Class == 'ScriptCollection'; // isCollection == true

The value of a comma-separated expression is equal to the value of the last sub-expression.

Was this article helpful?

0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.