2 * @fileoverview Rule to flag when using constructor without parentheses
8 //------------------------------------------------------------------------------
10 //------------------------------------------------------------------------------
12 module.exports = function(context) {
16 "NewExpression": function(node) {
17 var tokens = context.getTokens(node);
18 var prenticesTokens = tokens.filter(function(token) {
19 return token.value === "(" || token.value === ")";
21 if (prenticesTokens.length < 2) {
22 context.report(node, "Missing '()' invoking a constructor");