From 8b4d81c16d1ffc59c9633022df669beb0f10d79f Mon Sep 17 00:00:00 2001 From: Jason Simmons Date: Tue, 28 Apr 2020 13:45:47 -0700 Subject: [PATCH] Disable the import_internal_library analyzer check for dart:ui (flutter/engine#18009) The latest version of dartanalyzer does not support disabling this for a specific line of code. --- engine/src/flutter/analysis_options.yaml | 2 ++ engine/src/flutter/lib/ui/ui.dart | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/engine/src/flutter/analysis_options.yaml b/engine/src/flutter/analysis_options.yaml index c125e1d52f..b9b2f6a708 100644 --- a/engine/src/flutter/analysis_options.yaml +++ b/engine/src/flutter/analysis_options.yaml @@ -28,6 +28,8 @@ analyzer: native_function_body_in_non_sdk_code: ignore # allow having TODOs in the code todo: ignore + # allow dart:ui to import dart:_internal + import_internal_library: ignore # `flutter analyze` (without `--watch`) just ignores directories # that contain a .dartignore file, and this file does not have any # effect on what files are actually analyzed. diff --git a/engine/src/flutter/lib/ui/ui.dart b/engine/src/flutter/lib/ui/ui.dart index 2d46db0404..f765f1db69 100644 --- a/engine/src/flutter/lib/ui/ui.dart +++ b/engine/src/flutter/lib/ui/ui.dart @@ -12,7 +12,7 @@ // @dart = 2.6 library dart.ui; -import 'dart:_internal' hide Symbol; // ignore: import_internal_library, unused_import +import 'dart:_internal' hide Symbol; // ignore: unused_import import 'dart:async'; import 'dart:collection' as collection; import 'dart:convert';