bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

wrong word tokenization in case of arithmetic expressions


From: Milana
Subject: wrong word tokenization in case of arithmetic expressions
Date: Tue, 24 Sep 2024 00:32:56 +0200

Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS: -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection         -fno-om it-frame-pointer -mno-omit-leaf-frame-pointer -flto=auto -DDEFAULT_PATH_VALUE='/usr/local/sbin:/usr/local/bin:/usr/bin' -DSTANDARD_UTILS_PATH='/usr/bin' -DSYS_BASHRC='/etc/bash.bashrc' -DSYS_BASH_LOGOUT='/etc/b
ash.bash_logout' -DNON_INTERACTIVE_LOGIN_SHELLS
uname output: Linux milana-laptop 6.1.103-1-MANJARO #1 SMP PREEMPT_DYNAMIC Sat Aug  3 10:06:55 UTC 2024 x86_64 GNU/Linux
Machine Type: x86_64-pc-linux-gnu

Bash Version: 5.2
Patch Level: 26
Release Status: release

Description:
       simple arithmetic expressions tokenized incorrectly when referred by history expansion

Repeat-By:
       try to enter a simple command with one of arguments is an arithmetic expression, for instance `echo $((1+2))`. Then enter anything with history substitution of !!:1 (or the word designator of the arithm etic expression). Insted of printing $((1+2)) as expected it prints $((1+2) as the word 1, and ) as the word 2


reply via email to

[Prev in Thread] Current Thread [Next in Thread]