Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 181749 Details for
Bug 328744
Removed warnings related to fix for 185682
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Proposed fix
patch_328744.txt (text/plain), 17.80 KB, created by
Olivier Thomann
on 2010-10-26 13:23:00 EDT
(
hide
)
Description:
Proposed fix
Filename:
MIME Type:
Creator:
Olivier Thomann
Created:
2010-10-26 13:23:00 EDT
Size:
17.80 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core >Index: batch/org/eclipse/jdt/internal/compiler/batch/Main.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/batch/org/eclipse/jdt/internal/compiler/batch/Main.java,v >retrieving revision 1.355 >diff -u -r1.355 Main.java >--- batch/org/eclipse/jdt/internal/compiler/batch/Main.java 29 Sep 2010 16:43:28 -0000 1.355 >+++ batch/org/eclipse/jdt/internal/compiler/batch/Main.java 26 Oct 2010 17:22:11 -0000 >@@ -605,7 +605,6 @@ > public void loggingExtraProblems(Main currentMain) { > ArrayList problems = currentMain.extraProblems; > final int count = problems.size(); >- int localErrorCount = 0; > int localProblemCount = 0; > if (count != 0) { > int errors = 0; >@@ -617,7 +616,6 @@ > logExtraProblem(problem, localProblemCount, currentMain.globalProblemsCount); > localProblemCount++; > if (problem.isError()) { >- localErrorCount++; > errors++; > currentMain.globalErrorsCount++; > } else if (problem.isWarning()) { >Index: codeassist/org/eclipse/jdt/internal/codeassist/CompletionEngine.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/codeassist/org/eclipse/jdt/internal/codeassist/CompletionEngine.java,v >retrieving revision 1.419 >diff -u -r1.419 CompletionEngine.java >--- codeassist/org/eclipse/jdt/internal/codeassist/CompletionEngine.java 22 Sep 2010 06:32:16 -0000 1.419 >+++ codeassist/org/eclipse/jdt/internal/codeassist/CompletionEngine.java 26 Oct 2010 17:22:11 -0000 >@@ -6950,21 +6950,14 @@ > > boolean foundSomeFields = false; > >- boolean staticsOnly = false; > Scope currentScope = scope; > > done : while (true) { // done when a COMPILATION_UNIT_SCOPE is found > > switch (currentScope.kind) { > >- case Scope.METHOD_SCOPE : >- // handle the error case inside an explicit constructor call (see MethodScope>>findField) >- MethodScope methodScope = (MethodScope) currentScope; >- staticsOnly |= methodScope.isStatic | methodScope.isConstructorCall; >- break; > case Scope.CLASS_SCOPE : > ClassScope classScope = (ClassScope) currentScope; >- SourceTypeBinding enclosingType = classScope.referenceContext.binding; > if(!insideTypeAnnotation) { > > FieldDeclaration[] fields = classScope.referenceContext.fields; >@@ -6986,7 +6979,6 @@ > } > } > } >- staticsOnly |= enclosingType.isStatic(); > insideTypeAnnotation = false; > break; > case Scope.COMPILATION_UNIT_SCOPE : >@@ -7004,21 +6996,14 @@ > InvocationSite invocationSite, > boolean insideTypeAnnotation) { > >- boolean staticsOnly = false; > Scope currentScope = scope; > > done : while (true) { // done when a COMPILATION_UNIT_SCOPE is found > > switch (currentScope.kind) { > >- case Scope.METHOD_SCOPE : >- // handle the error case inside an explicit constructor call (see MethodScope>>findField) >- MethodScope methodScope = (MethodScope) currentScope; >- staticsOnly |= methodScope.isStatic | methodScope.isConstructorCall; >- break; > case Scope.CLASS_SCOPE : > ClassScope classScope = (ClassScope) currentScope; >- SourceTypeBinding enclosingType = classScope.referenceContext.binding; > if(!insideTypeAnnotation) { > > AbstractMethodDeclaration[] methods = classScope.referenceContext.methods; >@@ -7072,7 +7057,6 @@ > } > } > } >- staticsOnly |= enclosingType.isStatic(); > insideTypeAnnotation = false; > break; > case Scope.COMPILATION_UNIT_SCOPE : >Index: formatter/org/eclipse/jdt/internal/formatter/Scribe.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/formatter/org/eclipse/jdt/internal/formatter/Scribe.java,v >retrieving revision 1.220 >diff -u -r1.220 Scribe.java >--- formatter/org/eclipse/jdt/internal/formatter/Scribe.java 25 Oct 2010 00:05:14 -0000 1.220 >+++ formatter/org/eclipse/jdt/internal/formatter/Scribe.java 26 Oct 2010 17:22:12 -0000 >@@ -3973,9 +3973,6 @@ > > // Compute indentation if necessary > boolean clearBlankLines = this.formatter.preferences.comment_clear_blank_lines_in_javadoc_comment; >- boolean headerLine = block.isHeaderLine() && this.lastNumberOfNewLines == 0; >- int firstColumn = 1 + this.indentationLevel + BLOCK_LINE_PREFIX_LENGTH; >- if (headerLine) firstColumn++; > > // Local variables init > int textStart = text.sourceStart; >Index: model/org/eclipse/jdt/internal/core/util/Util.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/util/Util.java,v >retrieving revision 1.143 >diff -u -r1.143 Util.java >--- model/org/eclipse/jdt/internal/core/util/Util.java 9 Apr 2010 13:38:05 -0000 1.143 >+++ model/org/eclipse/jdt/internal/core/util/Util.java 26 Oct 2010 17:22:12 -0000 >@@ -3280,7 +3280,6 @@ > char[][] signatures = new char[10][]; > int signaturesCount = 0; > // int[] lengthes = new int [10]; >- int typeArgsCount = 0; > int paramOpening = 0; > > // Scan each signature character >@@ -3292,18 +3291,10 @@ > if (signaturesCount == signatures.length) { > System.arraycopy(signatures, 0, signatures = new char[signaturesCount+10][], 0, signaturesCount); > } >- typeArgsCount = 0; > } > break; > case '<': > paramOpening++; >- if (paramOpening == 1) { >- typeArgsCount = 1; >- } >- break; >- case '*': >- case ';': >- if (paramOpening == 1) typeArgsCount++; > break; > case '.': > if (paramOpening == 0) { >Index: search/org/eclipse/jdt/internal/core/index/DiskIndex.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/search/org/eclipse/jdt/internal/core/index/DiskIndex.java,v >retrieving revision 1.71 >diff -u -r1.71 DiskIndex.java >--- search/org/eclipse/jdt/internal/core/index/DiskIndex.java 7 May 2010 16:38:52 -0000 1.71 >+++ search/org/eclipse/jdt/internal/core/index/DiskIndex.java 26 Oct 2010 17:22:12 -0000 >@@ -279,7 +279,6 @@ > > // find out if the memory index has any new or deleted documents, if not then the names & positions are the same > int numDeletedDocNames = 0; >- int numReindexedDocNames = 0; > nextPath : for (int i = 0, l = docNames.length; i < l; i++) { > String docName = (String) docNames[i]; > if (docName != null) { >@@ -290,7 +289,6 @@ > numDeletedDocNames++; > } else { > positions[j] = RE_INDEXED; >- numReindexedDocNames++; > } > continue nextPath; > } >Index: search/org/eclipse/jdt/internal/core/search/StringOperation.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/search/org/eclipse/jdt/internal/core/search/StringOperation.java,v >retrieving revision 1.5 >diff -u -r1.5 StringOperation.java >--- search/org/eclipse/jdt/internal/core/search/StringOperation.java 14 Apr 2009 17:07:36 -0000 1.5 >+++ search/org/eclipse/jdt/internal/core/search/StringOperation.java 26 Oct 2010 17:22:12 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2009 IBM Corporation and others. >+ * Copyright (c) 2000, 2010 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -317,7 +317,6 @@ > if (nameEnd < 0) > nameEnd = name.length(); > int questions = 0; >- int stars = 0; > int parts = 0; > char previous = 0; > for (int i=patternStart; i<patternEnd; i++) { >@@ -327,7 +326,6 @@ > questions++; > break; > case '*': >- stars++; > break; > default: > switch (previous) { >#P org.eclipse.jdt.core.tests.compiler >Index: src/org/eclipse/jdt/core/tests/compiler/regression/ScannerTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/ScannerTest.java,v >retrieving revision 1.33 >diff -u -r1.33 ScannerTest.java >--- src/org/eclipse/jdt/core/tests/compiler/regression/ScannerTest.java 12 Nov 2009 20:24:53 -0000 1.33 >+++ src/org/eclipse/jdt/core/tests/compiler/regression/ScannerTest.java 26 Oct 2010 17:22:12 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2009 IBM Corporation and others. >+ * Copyright (c) 2000, 2010 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -267,10 +267,9 @@ > char[] source = "0xaapaf".toCharArray(); //$NON-NLS-1$ > scanner.setSource(source); > scanner.resetTo(0, source.length - 1); >- int counter = 0; > try { > while (scanner.getNextToken() != ITerminalSymbols.TokenNameEOF) { >- counter++; >+ // ignore > } > } catch (InvalidInputException e) { > assertTrue(true); >@@ -287,10 +286,9 @@ > char[] source = "0xaap.1f".toCharArray(); //$NON-NLS-1$ > scanner.setSource(source); > scanner.resetTo(0, source.length - 1); >- int counter = 0; > try { > while (scanner.getNextToken() != ITerminalSymbols.TokenNameEOF) { >- counter++; >+ // ignore > } > } catch (InvalidInputException e) { > assertTrue(true); >@@ -383,10 +381,9 @@ > char[] source = "0x".toCharArray(); //$NON-NLS-1$ > scanner.setSource(source); > scanner.resetTo(0, source.length - 1); >- int counter = 0; > try { > while (scanner.getNextToken() != ITerminalSymbols.TokenNameEOF) { >- counter++; >+ // ignore > } > } catch (InvalidInputException e) { > assertTrue(true); >@@ -403,10 +400,9 @@ > char[] source = "0x".toCharArray(); //$NON-NLS-1$ > scanner.setSource(source); > scanner.resetTo(0, source.length - 1); >- int counter = 0; > try { > while (scanner.getNextToken() != ITerminalSymbols.TokenNameEOF) { >- counter++; >+ // ignore > } > } catch (InvalidInputException e) { > assertTrue(true); >Index: src/org/eclipse/jdt/core/tests/eval/SimpleTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/eval/SimpleTest.java,v >retrieving revision 1.20 >diff -u -r1.20 SimpleTest.java >--- src/org/eclipse/jdt/core/tests/eval/SimpleTest.java 27 Jun 2008 16:04:47 -0000 1.20 >+++ src/org/eclipse/jdt/core/tests/eval/SimpleTest.java 26 Oct 2010 17:22:12 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2008 IBM Corporation and others. >+ * Copyright (c) 2000, 2010 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -174,7 +174,6 @@ > int begin = problem.getSourceStart() >= source.length ? source.length - 1 : problem.getSourceStart(); > int relativeStart = 0; > int end = problem.getSourceEnd() >= source.length ? source.length - 1 : problem.getSourceEnd(); >- int relativeEnd = 0; > label : for (relativeStart = 0;; relativeStart++) { > if (begin == 0) > break label; >@@ -182,7 +181,7 @@ > break label; > begin--; > } >- label : for (relativeEnd = 0;; relativeEnd++) { >+ label : for (;;) { > if ((end + 1) >= source.length) > break label; > if ((source[end + 1] == '\r') || (source[end + 1] == '\n')) { >#P org.eclipse.jdt.core.tests.model >Index: src/org/eclipse/jdt/core/tests/dom/ASTConverterBindingsTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/dom/ASTConverterBindingsTest.java,v >retrieving revision 1.8 >diff -u -r1.8 ASTConverterBindingsTest.java >--- src/org/eclipse/jdt/core/tests/dom/ASTConverterBindingsTest.java 28 Apr 2009 17:49:27 -0000 1.8 >+++ src/org/eclipse/jdt/core/tests/dom/ASTConverterBindingsTest.java 26 Oct 2010 17:22:13 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2009 IBM Corporation and others. >+ * Copyright (c) 2000, 2010 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -507,7 +507,6 @@ > final int length = compilationUnitscollector.size(); > ICompilationUnit[] units = new ICompilationUnit[length]; > compilationUnitscollector.toArray(units); >- long totalTime = 0; > for (int j = 0; j < length; j++) { > ICompilationUnit currentUnit = units[j]; > ASTNode result = runConversion(AST.JLS3, currentUnit, true); >@@ -538,7 +537,6 @@ > unit2.accept(collector2); > List bindings2 = collector2.getBindings(); > assertEquals("Wrong size", bindings1.size(), bindings2.size()); >- long time = System.currentTimeMillis(); > for (int i = 0, max = bindings1.size(); i < max; i++) { > final Object object = bindings1.get(i); > assertTrue("not a binding", object instanceof IBinding); >@@ -549,10 +547,6 @@ > final boolean equalTo = binding.isEqualTo(binding2); > assertTrue("not equals", equalTo); > } >- totalTime += (System.currentTimeMillis() - time); >- } >- if (DEBUG) { >- System.out.println("Total time = " + totalTime + "ms"); > } > } > } >Index: src/org/eclipse/jdt/core/tests/dom/ASTConverterTest2.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/dom/ASTConverterTest2.java,v >retrieving revision 1.197 >diff -u -r1.197 ASTConverterTest2.java >--- src/org/eclipse/jdt/core/tests/dom/ASTConverterTest2.java 28 Apr 2009 17:46:04 -0000 1.197 >+++ src/org/eclipse/jdt/core/tests/dom/ASTConverterTest2.java 26 Oct 2010 17:22:13 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2009 IBM Corporation and others. >+ * Copyright (c) 2000, 2010 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -300,10 +300,8 @@ > ASTNodesCollectorVisitor nodesCollector = new ASTNodesCollectorVisitor(); > compilationUnit.accept(nodesCollector); > Set detachedNodes = nodesCollector.getDetachedAstNodes(); >- int counter = 0; > for (Iterator iterator = detachedNodes.iterator(); iterator.hasNext(); ) { > ASTNode detachedNode = (ASTNode) iterator.next(); >- counter++; > IBinding binding = (IBinding) bindingsMap.get(detachedNode); > assertNotNull(binding); > switch(detachedNode.getNodeType()) { >Index: src/org/eclipse/jdt/core/tests/dom/ASTConverterTestAST3_2.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/dom/ASTConverterTestAST3_2.java,v >retrieving revision 1.176 >diff -u -r1.176 ASTConverterTestAST3_2.java >--- src/org/eclipse/jdt/core/tests/dom/ASTConverterTestAST3_2.java 14 Sep 2010 11:49:11 -0000 1.176 >+++ src/org/eclipse/jdt/core/tests/dom/ASTConverterTestAST3_2.java 26 Oct 2010 17:22:13 -0000 >@@ -377,10 +377,8 @@ > ASTNodesCollectorVisitor nodesCollector = new ASTNodesCollectorVisitor(); > compilationUnit.accept(nodesCollector); > Set detachedNodes = nodesCollector.getDetachedAstNodes(); >- int counter = 0; > for (Iterator iterator = detachedNodes.iterator(); iterator.hasNext(); ) { > ASTNode detachedNode = (ASTNode) iterator.next(); >- counter++; > IBinding binding = (IBinding) bindingsMap.get(detachedNode); > assertNotNull(binding); > switch(detachedNode.getNodeType()) { >Index: src/org/eclipse/jdt/core/tests/dom/ProfilingASTConvertionTest.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/dom/ProfilingASTConvertionTest.java,v >retrieving revision 1.14 >diff -u -r1.14 ProfilingASTConvertionTest.java >--- src/org/eclipse/jdt/core/tests/dom/ProfilingASTConvertionTest.java 28 Apr 2009 17:49:27 -0000 1.14 >+++ src/org/eclipse/jdt/core/tests/dom/ProfilingASTConvertionTest.java 26 Oct 2010 17:22:13 -0000 >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2009 IBM Corporation and others. >+ * Copyright (c) 2000, 2010 IBM Corporation and others. > * All rights reserved. This program and the accompanying materials > * are made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -237,7 +237,6 @@ > final int apiLevel = AST.JLS3; > ASTParser parser = ASTParser.newParser(apiLevel); > parser.setResolveBindings(RESOLVE_BINDINGS); >- long totalTime = 0; > int length = this.compilationUnits.length; > long[] times = new long[length]; > ArrayList arrayList = new ArrayList(length); >@@ -247,7 +246,6 @@ > long time = System.currentTimeMillis(); > ASTNode node = parser.createAST(null); > times[i] = System.currentTimeMillis() - time; >- totalTime += times[i]; > assertNotNull("No node", node); > assertEquals("Wrong type", ASTNode.COMPILATION_UNIT, node.getNodeType()); > CompilationUnit unit = (CompilationUnit) node;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 328744
: 181749