code: function(attr, model, subIndices) {
        var i, attrName, remainder, subAttrs, newIndices,
          firstBracket = attr.indexOf('[]');
        if (_.isEmpty(subIndices)) {
          subIndices = [];
        }
        if (firstBracket === -1) {
          return {attr: attr, index: subIndices};
        } else {
          attrName = attr.substring(0, firstBracket);
          remainder = attr.substring(firstBracket + 2);
          subAttrs = [];
          var valueArray = model.get(attrName);
          _.each(valueArray, function(value, i) {
            newIndices = subIndices.slice();
            newIndices.push(i);
            subAttrs.push(generateSubAttributes(attrName + '[' + i + ']' + remainder, model, newIndices));
          });
          return subAttrs;
        }
      }
docs: Generates an array of all the possible field accessors and their indices when using the "open" array notation foo[] -> [{attr: 'foo[0]', index: [0]}, {attr: 'foo[1]', index: [1]}].  Will also perform nested arrays: foo[][] -> [[{attr: 'foo[0][0]', index: [0][0]}], [{attr: 'foo[1][0]', index: [1][0]}]]