You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "song (JIRA)" <ji...@apache.org> on 2017/11/10 02:18:00 UTC
[jira] [Created] (LUCENE-8046) Redundant assign values to one
variable continuously, which makes the first assignment redundant and
useless
song created LUCENE-8046:
----------------------------
Summary: Redundant assign values to one variable continuously, which makes the first assignment redundant and useless
Key: LUCENE-8046
URL: https://issues.apache.org/jira/browse/LUCENE-8046
Project: Lucene - Core
Issue Type: Improvement
Components: modules/analysis
Affects Versions: 7.0.1
Environment: Ubuntu 14.04.5 LTS
Reporter: song
Our static code analysis tool has scanned the codebase of Lucene 7.0.1, and find 29 cases, that developers reassigned values to a variable continuously.
For example, the following code from file: `analysis/common/src/java/org/tartarus/snowball/ext/CatalanStemmer.java`
{code:java}
cursor=limit - v_5;
cursor=limit_backward;
{code}
In the above code snippet, the second statement makes the first one redundant and useless.
There are 29 cases in total in the codebase of Lucene.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org