currentMatch method

bool currentMatch(
  1. dynamic exp
)

Implementation

bool currentMatch(exp) {
  if (exp is String && parameters.isNotEmpty) {
    for (var key in parameters.keys) {
      if ((RegExp('#\\(.+\\)', multiLine: true).hasMatch(exp) &&
              exp.contains('\$$key')) ||
          exp == key ||
          exp.startsWith('\$($key') ||
          exp.startsWith('#(\${$key') ||
          exp.startsWith('^($key)')) {
        return true;
      }
    }
  }
  return false;
}