Perl Text Balance extract bracketed returns null 没有错误
Perl Text Balance extract bracketed returns null no error
我正在尝试调试一个 Perl 脚本,它对一些用花括号括起来的文本使用文本平衡提取括号函数。
很遗憾,函数returns什么都没有,不是在提取或取余,而是有错误。
有没有办法找出失败的原因?它是否有可能抛出异常,例如,由于数据结构而无法提取。目前不知为何,无法真正解决问题
请参阅文档的 Diagnostics 部分。
In addition, on failure in any context, the $@
variable is set. Accessing $@->{error}
returns one of the error diagnostics listed below. Accessing $@->{pos}
returns the offset into the original string at which the error was detected (although not necessarily where it occurred!) Printing $@
directly produces the error message, with the offset appended. On success, the $@
variable is guaranteed to be undef
.
我正在尝试调试一个 Perl 脚本,它对一些用花括号括起来的文本使用文本平衡提取括号函数。
很遗憾,函数returns什么都没有,不是在提取或取余,而是有错误。
有没有办法找出失败的原因?它是否有可能抛出异常,例如,由于数据结构而无法提取。目前不知为何,无法真正解决问题
请参阅文档的 Diagnostics 部分。
In addition, on failure in any context, the
$@
variable is set. Accessing$@->{error}
returns one of the error diagnostics listed below. Accessing$@->{pos}
returns the offset into the original string at which the error was detected (although not necessarily where it occurred!) Printing$@
directly produces the error message, with the offset appended. On success, the$@
variable is guaranteed to beundef
.