poky/bitbake/lib/bb/parse/parse_py
Nikolai Merinov b65452bda3 bitbake: parse: Forbid ambiguous assignments to ${.}, ${+}, and ${:} variables
Old code that parse variable names in assignment commands behave differently for
variables that ends with special symbol for single-character variable names and
multi-character variable names. For example:

  A+="1"   # Change variable ${A}, '+' glued to '='
  A+ = "1" # Change variable ${A+}

  +="1"    # Change variable ${+}, the '+' symbol not part of assignment operator
  + = "1"  # Change variable ${+}

New code would always assume that '.=', '+=', and ':=' is assignment operator.
As result code like the following would raise parsing error

  +="value"

While code with extra spaces would work as before

  + = "value" # Change variable ${+}

This change allow to catch issues in code that generate bitbake configuration
files in a manner like "echo ${VARNAME}+=${VALUE} >> conf/local.conf"

(Bitbake rev: 93059aad13a12cd69d86368795c88e5349197d5d)

Signed-off-by: Nikolai Merinov <n.merinov@inango-systems.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2025-02-05 12:11:01 +00:00
..
__init__.py bitbake: bitbake: lib: Cleanup /usr/bin/env python 2019-06-28 13:29:04 +01:00
BBHandler.py bitbake: BBHandler/ast: Improve addtask handling 2024-08-13 15:47:55 +01:00
ConfHandler.py bitbake: parse: Forbid ambiguous assignments to ${.}, ${+}, and ${:} variables 2025-02-05 12:11:01 +00:00