Simplify FilterExpression.args_check

Simplify the template parser code which verifies the number of arguments passed to filters.