How has support for here-docs changed across recent Perl versions?

Perl has evolved over the years, with various changes in syntax and features, including how here-docs are handled. Here-docs, or heredocs, provide a way to define multi-line strings. As Perl versions have progressed, support for several delimiters, including the ability to use a variable to define the end of a here-doc, has been enhanced.
Perl, here-docs, heredocs, multi-line strings, Perl versions, syntax changes
# Example of a here-doc in Perl my $str = <<'EOF'; This is an example of a here-doc in Perl. It can span multiple lines without using concatenation. EOF print $str;

Perl here-docs heredocs multi-line strings Perl versions syntax changes