Redmine 6327 - Interpret failing function calls in ifvarclass as class not set

This is a back port of a07d3b2362de3de1c5f8a43d29c3bcea87b96a3f to 3.6.x.
and:
```
"ok" and => { "variable_with_set_class", "!fail" };
```
which you should test in place of !fail below.