private static Expression inlineReferences(Expression expression, Assignments assignments) {
    Function<Symbol, Expression> mapping =
        symbol -> {
          Expression result = assignments.get(symbol);
          if (result != null) {
            return result;
          }

          return symbol.toSymbolReference();
        };

    return inlineSymbols(mapping, expression);
  }
Inlines expressions from a child project node into a parent project node as long as they are
simple constants, or they are referenced only once (to avoid introducing duplicate computation)
and the references don't appear within a TRY block (to avoid changing semantics).
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/relational/planner/iterative/rule/InlineProjections.java