From 43e4536ebbfa03be27763dddea612646f91b3658 Mon Sep 17 00:00:00 2001 From: Sam Rawlins Date: Wed, 3 Feb 2021 21:53:59 +0000 Subject: [PATCH] analyzer: Fix documentation for TypeProvider Text like "Future" turns into an HTML tag. Referencing the elements with [] escapes the HTML and creates links for the user. Change-Id: Ib20020f879ec1eef4a5d98e896f72b00242deac7 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/182481 Reviewed-by: Konstantin Shcheglov Reviewed-by: Brian Wilkerson Commit-Queue: Samuel Rawlins --- .../lib/dart/element/type_provider.dart | 96 +++++++++---------- 1 file changed, 47 insertions(+), 49 deletions(-) diff --git a/pkg/analyzer/lib/dart/element/type_provider.dart b/pkg/analyzer/lib/dart/element/type_provider.dart index f263c27be17..17b41010776 100644 --- a/pkg/analyzer/lib/dart/element/type_provider.dart +++ b/pkg/analyzer/lib/dart/element/type_provider.dart @@ -10,159 +10,157 @@ import 'package:analyzer/dart/element/type.dart'; /// /// Clients may not extend, implement or mix-in this class. abstract class TypeProvider { - /// Return the element representing the built-in class 'bool'. + /// Return the element representing the built-in class `bool`. ClassElement get boolElement; - /// Return the type representing the built-in type 'bool'. + /// Return the type representing the built-in type `bool`. InterfaceType get boolType; - /// Return the type representing the type 'bottom'. + /// Return the type representing the type `bottom`. DartType get bottomType; - /// Return the type representing the built-in type 'Deprecated'. + /// Return the type representing the built-in type `Deprecated`. InterfaceType get deprecatedType; - /// Return the element representing the built-in class 'double'. + /// Return the element representing the built-in class `double`. ClassElement get doubleElement; - /// Return the type representing the built-in type 'double'. + /// Return the type representing the built-in type `double`. InterfaceType get doubleType; - /// Return the type representing the built-in type 'dynamic'. + /// Return the type representing the built-in type `dynamic`. DartType get dynamicType; - /// Return the type representing the built-in type 'Function'. + /// Return the type representing the built-in type `Function`. InterfaceType get functionType; - /// Return the type representing 'Future'. + /// Return the type representing `Future`. InterfaceType get futureDynamicType; - /// Return the element representing the built-in class 'Future'. + /// Return the element representing the built-in class `Future`. ClassElement get futureElement; - /// Return the type representing 'Future'. + /// Return the type representing `Future`. InterfaceType get futureNullType; - /// Return the element representing the built-in class 'FutureOr'. + /// Return the element representing the built-in class `FutureOr`. ClassElement get futureOrElement; - /// Return the type representing 'FutureOr'. + /// Return the type representing `FutureOr`. InterfaceType get futureOrNullType; - /// Return the element representing the built-in class 'int'. + /// Return the element representing the built-in class `int`. ClassElement get intElement; - /// Return the type representing the built-in type 'int'. + /// Return the type representing the built-in type `int`. InterfaceType get intType; - /// Return the type representing the type 'Iterable'. + /// Return the type representing the type `Iterable`. InterfaceType get iterableDynamicType; - /// Return the element representing the built-in class 'Iterable'. + /// Return the element representing the built-in class `Iterable`. ClassElement get iterableElement; - /// Return the type representing the type 'Iterable'. + /// Return the type representing the type `Iterable`. InterfaceType get iterableObjectType; - /// Return the element representing the built-in class 'List'. + /// Return the element representing the built-in class `List`. ClassElement get listElement; - /// Return the element representing the built-in class 'Map'. + /// Return the element representing the built-in class `Map`. ClassElement get mapElement; - /// Return the type representing 'Map'. + /// Return the type representing `Map`. InterfaceType get mapObjectObjectType; - /// Return the type representing the built-in type 'Never'. + /// Return the type representing the built-in type `Never`. DartType get neverType; /// Return a list containing all of the types that cannot be either extended /// or implemented. Set get nonSubtypableClasses; - /// Return the element representing the built-in class 'null'. + /// Return the element representing the built-in class `Null`. ClassElement get nullElement; - /// Return the type representing the built-in type 'Null'. + /// Return the type representing the built-in type `Null`. InterfaceType get nullType; - /// Return the element representing the built-in class 'num'. + /// Return the element representing the built-in class `num`. ClassElement get numElement; - /// Return the type representing the built-in type 'num'. + /// Return the type representing the built-in type `num`. InterfaceType get numType; - /// Return the type representing the built-in type 'Object'. + /// Return the type representing the built-in type `Object`. InterfaceType get objectType; - /// Return the element representing the built-in class 'Set'. + /// Return the element representing the built-in class `Set`. ClassElement get setElement; - /// Return the type representing the built-in type 'StackTrace'. + /// Return the type representing the built-in type `StackTrace`. InterfaceType get stackTraceType; - /// Return the type representing 'Stream'. + /// Return the type representing `Stream`. InterfaceType get streamDynamicType; - /// Return the element representing the built-in class 'Stream'. + /// Return the element representing the built-in class `Stream`. ClassElement get streamElement; - /// Return the element representing the built-in class 'String'. + /// Return the element representing the built-in class `String`. ClassElement get stringElement; - /// Return the type representing the built-in type 'String'. + /// Return the type representing the built-in type `String`. InterfaceType get stringType; - /// Return the element representing the built-in class 'Symbol'. + /// Return the element representing the built-in class `Symbol`. ClassElement get symbolElement; - /// Return the type representing the built-in type 'Symbol'. + /// Return the type representing the built-in type `Symbol`. InterfaceType get symbolType; - /// Return the type representing the built-in type 'Type'. + /// Return the type representing the built-in type `Type`. InterfaceType get typeType; /// Return the type representing the built-in type `void`. VoidType get voidType; - /// Return the instantiation of the built-in class 'FutureOr' with the + /// Return the instantiation of the built-in class `FutureOr` with the /// given [valueType]. The type has the nullability suffix of this provider. InterfaceType futureOrType2(DartType valueType); - /// Return the instantiation of the built-in class 'Future' with the + /// Return the instantiation of the built-in class `Future` with the /// given [valueType]. The type has the nullability suffix of this provider. InterfaceType futureType2(DartType valueType); - /// Return 'true' if [id] is the name of a getter on - /// the Object type. + /// Return 'true' if [id] is the name of a getter on the Object type. bool isObjectGetter(String id); - /// Return 'true' if [id] is the name of a method or getter on - /// the Object type. + /// Return 'true' if [id] is the name of a method or getter on the Object + /// type. bool isObjectMember(String id); - /// Return 'true' if [id] is the name of a method on - /// the Object type. + /// Return 'true' if [id] is the name of a method on the Object type. bool isObjectMethod(String id); - /// Return the instantiation of the built-in class 'Iterable' with the + /// Return the instantiation of the built-in class `Iterable` with the /// given [elementType]. The type has the nullability suffix of this provider. InterfaceType iterableType2(DartType elementType); - /// Return the instantiation of the built-in class 'List' with the + /// Return the instantiation of the built-in class `List` with the /// given [elementType]. The type has the nullability suffix of this provider. InterfaceType listType2(DartType elementType); - /// Return the instantiation of the built-in class 'List' with the + /// Return the instantiation of the built-in class `List` with the /// given [keyType] and [valueType]. The type has the nullability suffix of /// this provider. InterfaceType mapType2(DartType keyType, DartType valueType); - /// Return the instantiation of the built-in class 'Set' with the + /// Return the instantiation of the built-in class `Set` with the /// given [elementType]. The type has the nullability suffix of this provider. InterfaceType setType2(DartType elementType); - /// Return the instantiation of the built-in class 'Stream' with the + /// Return the instantiation of the built-in class `Stream` with the /// given [elementType]. The type has the nullability suffix of this provider. InterfaceType streamType2(DartType elementType); }