<commit_before>"use strict";

const Value = require('./Value');

const NAME = '[a-z_]\\w*';
const itemRe = new RegExp('^\\s*(?:' +
            '(?:\\[' +
                '(' + NAME + ')' +   // [1]
                '(?:[:](' + NAME + ')(\\[\\])?)?' +  // [2] optional ":type[]" [3]
            ')' +
            '(?:\\[' +
                '(' + NAME + ')' +   // [4]
                '(?:[:](' + NAME + ')(\\[\\])?)?' +  // [5] optional ":type[]" [6]
                '(?:[=]([^\\]]+))?' +       // [7] optional "=value"
            '\\])' +
        ')\\s*$', 'i');

//const shortHandRe = /^(\[)?([a-z]+[0-9\-_]*)(:(\w+)(=([\w._\-]+))?)?(])?$/i;<commit_msg>Allow "..." or "[]" to indicate array/vararg parameter<commit_after>"use strict";

const Value = require('./Value');

const NAME = '[a-z_]\\w*';
const VARARG = '((?:\\.\\.\\.)|(?:\\[\\]))?';  // match "type..." or "type[]"
const itemRe = new RegExp('^\\s*(?:' +
            '(?:\\[' +
                '(' + NAME + ')' +   // [1]
                '(?:[:](' + NAME + ')'+VARARG+')?' +  // [2] optional ":type..." [3]
            ')' +
            '(?:\\[' +
                '(' + NAME + ')' +   // [4]
                '(?:[:](' + NAME + ')'+VARARG+')?' +  // [5] optional ":type..." [6]
                '(?:[=]([^\\]]+))?' +       // [7] optional "=value"
            '\\])' +
        ')\\s*$', 'i');

//const shortHandRe = /^(\[)?([a-z]+[0-9\-_]*)(:(\w+)(=([\w._\-]+))?)?(])?$/i;
{'fraction_non_alphanumeric': 0.3857442348008386, 'fraction_numerical': 0.012578616352201259, 'mean_word_length': 1.452054794520548, 'pattern_counts': {'":': 4, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5644196', 'n_tokens_mistral': 571, 'n_tokens_neox': 544, 'n_words': 80}