In Automic Automation v24 and higher, the STR_LEN() script function evaluates UC_CRLF (a combination of a Carriage Return and a Line Feed) as a single character rather than two. This change results from the implementation of full Multi-Language Unicode / UTF-8 support, which strictly adheres to the Unicode Standard Annex #29 (UAX #29) — Grapheme Cluster Boundaries.
The following symptoms may occur:
STR_LEN(), STR_FIND(), and REPLACE() behave differently when processing CRLF sequences.STR_LEN(UC_CRLF) returns 1 instead of 2.CRLF as a single grapheme cluster.Automic Automation Engine v24.0.0 and higher.
This is an intentional design change to ensure compliance with Unicode Standard Annex #29 (UAX #29), specifically Rule GB3. The sequence of a Carriage Return (CR) and a Line Feed (LF) is defined as a single grapheme cluster (a single user-perceived character) in Unicode, and the Automic Unicode library counts grapheme clusters rather than raw bytes or code points.
This behavior is expected and is not a software defect. If scripts rely on processing Carriage Return (CR) and Line Feed (LF) as separate, individual characters, UC_CRLF() will no longer meet this requirement.
Instead, derive the carriage return and line feed individually using the HEX_2_STRING() function:
HEX_2_STRING() function to define the characters individually: :SET &cr# = HEX_2_STRING("0D") :SET &lf# = HEX_2_STRING("0A")UC_CRLF in your script with the concatenated &cr#&lf# string where individual character evaluation is required.For further details, refer to the Automic Automation Incompatibilities Guide and the HEX_2_STRING Reference.