Opened 4 years ago

Last modified 4 years ago

#3797 closed Feature Request

PCRE update to recent PCRE-8.44 or even to PCRE2-10.36 — at Initial Version

Reported by: mLipok Owned by:
Milestone: Component: AutoIt
Version: Severity: None
Keywords: Cc:

Description

In fact there was recently closed ticket:
https://www.autoitscript.com/trac/autoit/ticket/3656

In fact @Melba23 said:

PCRE updated for 3.3.16.0

But even using recent Alpha version (candidate for Beta which include PCRE-8.41) .... AutoIt still have problem with this simple example:

#include <Array.au3>
#include <StringConstants.au3>

_Example(0, '(?i)[\W]((\w)[\s\xA0]*?\d+[a-z]{0,3}\/\d\d)')

Func _Example($sTitle, $sPattern)
        Local $sText = _
                        'Dąbrowskiego43/45' & @CRLF & _
                        'Dąbrowskiego43/45' & @CRLF & _
                        'Kordeckiego1/11' & @CRLF & _
                        'Kordeckiego 1/11' & @CRLF & _
                        'm2/11' & @CRLF & _
                        'm2/12' & @CRLF & _
                        'p      3/12' & @CRLF & _
                        ''
        ConsoleWrite('>>>>>>>>>>> $sTitle = ' & $sTitle & @CRLF)
        Local $aTest = StringRegExp($sText, $sPattern, $STR_REGEXPARRAYGLOBALFULLMATCH)
        ConsoleWrite('! ---> @error=' & @error & '  @extended=' & @extended & @CRLF)
        If UBound($aTest) Then
                For $iOuter_id = 0 To UBound($aTest) - 1
                        ConsoleWrite('MATCH ' & $iOuter_id + 1 & @CRLF)
                        ConsoleWrite(_ArrayToString($aTest[$iOuter_id]) & @CRLF)
                Next
        EndIf
        ConsoleWrite('>>>>>>>>>>> END ' & @CRLF)
        ConsoleWrite(@CRLF)
        ConsoleWrite(@CRLF)
EndFunc   ;==>_Example

Proper behavior was saved be me in this link:
https://regex101.com/r/C7h5ML/3

So please consider update to PCRE-8.44 or even switch to PCRE2-10.36
https://ftp.pcre.org/pub/pcre/

Change History (0)

Note: See TracTickets for help on using tickets.