Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
WCCL
Manage
Activity
Members
Labels
Plan
Issues
4
Issue boards
Milestones
Wiki
Redmine
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Analysers
WCCL
Commits
9c67745d
Commit
9c67745d
authored
13 years ago
by
ilor
Browse files
Options
Downloads
Patches
Plain Diff
use vector::erase(std::remove instead of a hand-crafted loop. Fix confusing } positioning
parent
fab01c5a
Branches
Branches containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libmwereader/mwereader.cpp
+2
-12
2 additions, 12 deletions
libmwereader/mwereader.cpp
with
2 additions
and
12 deletions
libmwereader/mwereader.cpp
+
2
−
12
View file @
9c67745d
...
@@ -71,22 +71,12 @@ bool MWEReader::registered = TokenReader::register_path_reader<MWEReader>(
...
@@ -71,22 +71,12 @@ bool MWEReader::registered = TokenReader::register_path_reader<MWEReader>(
tok
->
set_orth_utf8
(
new_orth_utf8
);
tok
->
set_orth_utf8
(
new_orth_utf8
);
foreach
(
Lexeme
&
lex
,
tok
->
lexemes
())
foreach
(
Lexeme
&
lex
,
tok
->
lexemes
())
{
{
if
(
lex
.
is_disamb
()){
if
(
lex
.
is_disamb
()){
lex
.
set_lemma_utf8
(
pLU
->
get_base
());
lex
.
set_lemma_utf8
(
pLU
->
get_base
());
}
}
}
}
tokens
.
erase
(
std
::
remove
(
tokens
.
begin
(),
tokens
.
end
(),
NULL
),
tokens
.
end
());
std
::
vector
<
Token
*>::
iterator
del_iter
=
tokens
.
begin
();
}
while
(
del_iter
!=
tokens
.
end
())
{
if
(
(
*
del_iter
)
==
NULL
)
del_iter
=
tokens
.
erase
(
del_iter
);
else
++
del_iter
;
}
}
}
}
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment