Skip Menu | will be shut down on March 1st, 2021.

This queue is for tickets about the Text-Balanced CPAN distribution.

Report information
The Basics
Id: 74714
Status: new
Priority: 0/
Queue: Text-Balanced

Owner: Nobody in particular
Requestors: jtbraun [...]

Bug Information
Severity: Important
Broken in: v2.0.0
Fixed in: (no value)

Subject: extract_codeblock can't distinguish '<<' the operator from '<<' the here-doc starter
MIME-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 701
Download (untitled) / with headers
text/plain 701b
These work: extract_codeblock("{1<<2}"); extract_codeblock("{1<<2}\n"); This does not: extract_codeblock("{1<<2}\n\n"); The problem string diverges from the others on a call to _match_quotelike at position 2 (the '<<'). _match_quotelike begins to interpret this as a heredoc with the implicit label "", when extract_quoteblock probably should have known to expect an expression operator like left shift, rather than a here-doc/string. Unfortunately, it doesn't look like _match_codeblock really knows if it's in an expression or not, and adding that sort of state is probably fraught with peril. At the very least, this should be noted in the BUGS section of the documentation. Jeremy

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to