Skip to content

Conversation

Kimundi
Copy link
Contributor

@Kimundi Kimundi commented May 25, 2014

This patch changes the internals of Regex and regex!() such that

static RE: Regex = regex!(...);

is valid. It doesn't change anything about the actual regex implementation, it just changes the type to something that can be constructed as a const expression.


#[doc(hidden)]
#[allow(visible_private_types)]
pub fn names_iter<'a>(&'a self) -> NamesIter<'a> {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In addition to doc(hidden), can you make this #[experimental]?

@alexcrichton
Copy link
Member

This looks pretty awesome to me, nice work! Just a minor nit, otherwise r=me

@Kimundi
Copy link
Contributor Author

Kimundi commented May 25, 2014

Nit resolved ;)

bors added a commit that referenced this pull request May 25, 2014
This patch changes the internals of `Regex` and `regex!()` such that

```rust
static RE: Regex = regex!(...);
```

is valid. It doesn't change anything about the actual regex implementation, it just changes the type to something that can be constructed as a const expression.
@bors bors closed this May 26, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants