Lines Matching refs:group

98 /// Returns true if the given character is a valid in a capture group name.
101 /// group name (which must be alphabetic or underscore).
281 /// This state is pushed whenever an opening group is found.
283 /// The concatenation immediately preceding the opening group.
285 /// The group that has been opened. Its sub-AST is always empty.
286 group: ast::Group,
287 /// Whether this group has the `x` flag enabled or not.
505 /// a group or a set of flags.
664 /// Parse and push a group AST (and its parent concatenation) on to the
666 /// to the group's sub-AST.
668 /// If a set of flags was found (with no group), then the concatenation
675 /// If there was a problem parsing the start of the group, then an error
690 Either::Right(group) => {
692 let new_ignore_whitespace = group
699 group,
709 /// Pop a group AST from the parser's internal stack and set the group's
711 /// the group.
716 /// If no such group could be popped, then an unopened group error is
724 let (mut prior_concat, mut group, ignore_whitespace, alt) = match stack
727 Some(Group { concat, group, ignore_whitespace }) => {
728 (concat, group, ignore_whitespace, None)
731 Some(Group { concat, group, ignore_whitespace }) => {
732 (concat, group, ignore_whitespace, Some(alt))
749 group.span.end = self.pos();
754 group.ast = Box::new(alt.into_ast());
757 group.ast = Box::new(group_concat.into_ast());
760 prior_concat.asts.push(Ast::Group(group));
781 Some(GroupState::Group { group, .. }) => {
783 self.error(group.span, ast::ErrorKind::GroupUnclosed)
799 Some(GroupState::Group { group, .. }) => {
800 Err(self.error(group.span, ast::ErrorKind::GroupUnclosed))
1167 /// Parse a group (which contains a sub-expression) or a set of flags.
1169 /// If a group was found, then it is returned with an empty AST. If a set
1175 /// sub-expression (in the case of a group) or to the closing parenthesis
1246 /// Parses a capture group name. Assumes that the parser is positioned at
1251 /// The caller must provide the capture index of the group for this name.
2450 /// Create a capturing group with the given span.
2451 fn group(range: Range<usize>, index: u32, ast: Ast) -> Ast {
3060 ast: Box::new(group(
3426 Ok(group(
3456 Ok(group(
3471 Ok(group(
3478 group(
3488 group(
3533 Ok(group(
3544 Ok(group(
3552 Ok(group(