Skip to content

nu script.nu '"' fails #5371

@uasi

Description

@uasi

Describe the bug

nu script.nu '"' fails.

How to reproduce

bash-3.2$ cat script.nu
def main [x: any] {
  echo $x
}

bash-3.2$ nu script.nu hello
hello

bash-3.2$ nu script.nu '"'
Error: nu::parser::unexpected_eof (https://docs.rs/nu-parser/0.61.0/nu_parser/enum.ParseError.html#variant.UnexpectedEof)

  × Unexpected end of code.
   ╭─[<commandline>:1:1]
 1 │ main "
   ·       ▲
   ·       ╰── expected closing "
   ╰────

Expected behavior

bash-3.2$ nu script.nu '"'
"

Screenshots

No response

Configuration

key value
version 0.61.0
branch
tag
build_os macos-x86_64
rust_version rustc 1.59.0
cargo_version cargo 1.59.0
pkg_version 0.61.0
build_time 2022-04-12 20:38:15 +00:00
build_rust_channel release
features dataframe, default, trash, which, zip
installed_plugins

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions