buildBody method

  1. @override
BuildBodyResult buildBody(
  1. BuildContext context,
  2. bool hasResult
)
override

Builds a parser function body and returns the source code of the function body.

Implementation

@override
BuildBodyResult buildBody(BuildContext context, bool hasResult) {
  if (chars.isEmpty) {
    throw ArgumentError.value('', chars, 'Must not be empty');
  }

  final ranges = chars.runes.map((e) => (e, e)).toList();
  return Satisfy(InRange(ranges)).buildBody(context, hasResult);
}