09d661e1e5b151ea7168e3f99f97df4bcc0d8947,textacy/extract.py,,_make_pattern_from_string,#Any#,426

Before Change


                    int_match = constants.RE_MATCHER_INT_ATTR_VAL.match(attr_val)
                    if int_match:
                        attr_val = int(int_match.group(1))
            if len(parts) == 2:
                pattern.append({attr: attr_val})
            else:
                op_val = parts[2]
                if op_val in constants.MATCHER_VALID_OPS:

After Change


            attr_val = parts[1]
            // handle special bool and int attribute values
            spcial_val = constants.RE_MATCHER_SPECIAL_VAL.match(attr_val)
            if spcial_val:
                attr_val = eval(spcial_val.group(0))
            // handle quantifier ops
            try:
                op_val = parts[2]
                if op_val in constants.MATCHER_VALID_OPS:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: chartbeat-labs/textacy
Commit Name: 09d661e1e5b151ea7168e3f99f97df4bcc0d8947
Time: 2019-05-19
Author: burtdewilde@gmail.com
File Name: textacy/extract.py
Class Name:
Method Name: _make_pattern_from_string


Project Name: gyoisamurai/GyoiThon
Commit Name: 2fcde9fa889d6b9c52f9c9721943082a27236e87
Time: 2018-11-13
Author: gyoiler3@gmail.com
File Name: modules/Gyoi_ErrorChecker.py
Class Name: ErrorChecker
Method Name: get_error_message


Project Name: gyoisamurai/GyoiThon
Commit Name: b6f335e75cbc1a07d32c914d4629a25cf31cb964
Time: 2018-11-13
Author: gyoiler3@gmail.com
File Name: modules/Gyoi_CommentChecker.py
Class Name: CommentChecker
Method Name: get_bad_comment