mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 13:07:46 +00:00
parent
2eb0a8f3d2
commit
aa73a7c961
1 changed files with 4 additions and 0 deletions
|
@ -1425,6 +1425,10 @@ ErrorOr<void> Heredoc::dump(int level) const
|
||||||
|
|
||||||
ErrorOr<RefPtr<Value>> Heredoc::run(RefPtr<Shell> shell)
|
ErrorOr<RefPtr<Value>> Heredoc::run(RefPtr<Shell> shell)
|
||||||
{
|
{
|
||||||
|
if (shell && shell->posix_mode() && !m_contents) {
|
||||||
|
m_contents = make_ref_counted<StringLiteral>(position(), ""_string, StringLiteral::EnclosureType::None);
|
||||||
|
}
|
||||||
|
|
||||||
if (!m_contents) {
|
if (!m_contents) {
|
||||||
if (shell)
|
if (shell)
|
||||||
shell->raise_error(Shell::ShellError::EvaluatedSyntaxError, "Attempt to evaluate an unresolved heredoc"sv, position());
|
shell->raise_error(Shell::ShellError::EvaluatedSyntaxError, "Attempt to evaluate an unresolved heredoc"sv, position());
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue