isBool function

bool isBool(
  1. AST expression,
  2. AnalyzedClass analyzedClass
)

Returns whether the type expression is bool.

Implementation

bool isBool(ast.AST expression, AnalyzedClass analyzedClass) {
  final type = getExpressionType(expression, analyzedClass);
  return type.isDartCoreBool;
}