Skip to content

history expansion: history comment character stops line from being processed #513

Description

@jghub
v=foo
print ${#v}

does not print anything (but should print "3"). also, the print line does not make it into the history file which looks like a "silent crash" of the ${#v} evaluation or similar, no? same thing with

len=${#v}

(len is empty and the assignment statement does not make it into the history).

is this me or is this a bug?

thanks,
joerg

ps: Version AJM 93u+m/1.1.0-alpha+9067bb3c/MOD 2022-08-06

edit: I now put those two lines in an executable script tmp: that works as
tmp
ksh tmp
source tmp

it only fails when issuing the commands interactively in ksh93u+m. no idea how this can come about, especially the last observation, that source succeeds.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething is not working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions