Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions lib/elixir/lib/regex.ex
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ defmodule Regex do

A Regex is represented internally as the `Regex` struct. Therefore,
`%Regex{}` can be used whenever there is a need to match on them.
Keep in mind that all of the structs fields are private. And since
Keep in mind that all struct's fields are private. And since
regexes are compiled, there is no guarantee two regular expressions
from the same source are equal, for example:

Expand Down Expand Up @@ -284,10 +284,10 @@ defmodule Regex do

## Examples

Regex.import(~r/foo/E)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think we'll need to drop OTP28.0- support in the CI for this to work.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

so, revert this part to how it was?

iex> Regex.import(~r/foo/E)
~r/foo/

Regex.import(~r/foo/)
iex> Regex.import(~r/foo/)
~r/foo/

"""
Expand Down Expand Up @@ -491,6 +491,7 @@ defmodule Regex do
and will raise an exception unless the `:strict` option is false.

## Examples

iex> Regex.to_embed(~r/foo/)
"(?-imsx:foo)"

Expand Down
Loading