So using gcc the error you see will look something like so:
error: expected primary-expression before ‘{’ token It is expecting an expression but {}s are not an expression, they are just usable for list initialization in some places as specified by section 8.5.4 of the draft standard, which says:
... List-initialization can be used
— as the initializer in a variable definition (8.5)
— as the initializer in a new expression (5.3.4)
— in a return statement (6.6.3)
....
It does not list the conditional operator. As others have said an alternative is to use an if statement. Although as James points out this may not be the ideal substitution, so if you feel that the conditional operator works better in your context then as James suggests just use the following:
arrnode.push_back( arr[j] == '(' ? node( 1, 1 ) : node( -1, -1 ) );