Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
magicseteditor
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
magicseteditor
Commits
015b5a16
Commit
015b5a16
authored
Dec 07, 2010
by
twanvl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
compatibility with wxWdigets 2.9+: use wxString::const_iterator instead of raw Char*
parent
7b8b5a12
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
src/util/regex.hpp
src/util/regex.hpp
+4
-4
No files found.
src/util/regex.hpp
View file @
015b5a16
...
...
@@ -38,7 +38,7 @@
*/
class
Regex
{
public:
struct
Results
:
public
boost
::
match_results
<
const
Char
*
>
{
struct
Results
:
public
boost
::
match_results
<
String
::
const_iterator
>
{
/// Get a sub match
inline
String
str
(
int
sub
=
0
)
const
{
const_reference
v
=
(
*
this
)[
sub
];
...
...
@@ -48,7 +48,7 @@
inline
String
format
(
const
String
&
format
)
const
{
std
::
basic_string
<
Char
>
fmt
(
format
.
begin
(),
format
.
end
());
String
output
;
boost
::
match_results
<
const
Char
*
>::
format
(
boost
::
match_results
<
String
::
const_iterator
>::
format
(
insert_iterator
<
String
>
(
output
,
output
.
end
()),
fmt
,
boost
::
format_sed
);
return
output
;
}
...
...
@@ -62,9 +62,9 @@
return
regex_search
(
str
.
begin
(),
str
.
end
(),
regex
);
}
inline
bool
matches
(
Results
&
results
,
const
String
&
str
)
const
{
return
regex_search
(
str
.
begin
(),
str
.
end
(),
results
,
regex
);
return
matches
(
results
,
str
.
begin
(),
str
.
end
()
);
}
inline
bool
matches
(
Results
&
results
,
const
Char
*
begin
,
const
Char
*
end
)
const
{
inline
bool
matches
(
Results
&
results
,
const
String
::
const_iterator
&
begin
,
const
String
::
const_iterator
&
end
)
const
{
return
regex_search
(
begin
,
end
,
results
,
regex
);
}
void
replace_all
(
String
*
input
,
const
String
&
format
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment