blob: 91dbfd4f0e14456e5645930a9e14aa302a1df0e3 [file] [log] [blame]
// Copyright (c) 2020, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
// @dart = 2.9
import "package:expect/expect.dart";
main() {
// In legacy Dart 2 and null safety weak mode the error handlers can
// return null.
Expect.equals(null, int.parse("foo", onError: (_) => null));
Expect.equals(null, double.parse("foo", (_) => null));
}