FINAL_INITIALIZED_MULTIPLE_TIMES constant

CompileTimeErrorCode const FINAL_INITIALIZED_MULTIPLE_TIMES

5 Variables: It is a compile-time error if a final instance variable that has is initialized by means of an initializing formal of a constructor is also initialized elsewhere in the same constructor.

Parameters: 0: the name of the field in question

Implementation

static const CompileTimeErrorCode FINAL_INITIALIZED_MULTIPLE_TIMES =
    CompileTimeErrorCode('FINAL_INITIALIZED_MULTIPLE_TIMES',
        "'{0}' is a final field and so can only be set once.",
        correction: "Try removing all but one of the initializations.")