Nevermind, I am blind. I can't read version numbers. Please close.

I am getting an error "undefined class required" when using the required keyword in a constructor as follows:

class DropdownValue<T> {
  final String name;
  final T value;
  DropdownValue({required this.name, required this.value});
}

I found this question with the same problem: I am getting error: Undefined class 'required'. when trying to use required keyword

However, after checking my pubspec.yaml, I already have the setting that, going by that answer, should be correct: enter image description here

What's going on?