The language version must be >=2.12.0. Try removing the language version override and migrating the code.
Looking for the solution for the above error.Illegal_language_version_override
//@dart=2.9
import 'dart:io';
import 'package:firebase_core/firebase_core.dart';
Error-
Illegal_language_version_override
Download Flutter and Dart with the required versions for your codebase, and update the path in system environment; this will resolve the mentioned issues.