Add 'soong_config_variable' selection

This commit is contained in:
Bruno BELANYI 2024-04-08 01:25:09 +01:00
parent 64c29499e7
commit dea4120ece
5 changed files with 1440 additions and 1003 deletions

View file

@ -92,7 +92,7 @@ module.exports = grammar({
select_expression: ($) => seq(
"select",
"(",
$.select_value,
choice($.select_value, $.soong_config_variable),
",",
$.select_cases,
")",
@ -108,6 +108,20 @@ module.exports = grammar({
")",
),
soong_config_variable: ($) => seq(
field("type", alias("soong_config_variable", $.selection_type)),
"(",
field(
"condition",
seq(
field("namespace", $._string_literal),
",",
field("variable", $._string_literal),
),
),
")",
),
select_cases: ($) => seq(
"{",
optional(trailingCommaSeparated($.select_case)),