assignFinal method

  1. @Deprecated('Use `declareFinal(name).assign(expression)`')
Expression assignFinal(
  1. String name, [
  2. Reference? type
])
inherited

Return final {name} = {this}.

Implementation

@Deprecated('Use `declareFinal(name).assign(expression)`')
Expression assignFinal(String name, [Reference? type]) => BinaryExpression._(
      type == null
          ? const LiteralExpression._('final')
          : BinaryExpression._(
              const LiteralExpression._('final'),
              type.expression,
              '',
            ),
      this,
      '$name =',
    );