--- eclipse-pydev-1.2.5.orig/debian/README.Debian +++ eclipse-pydev-1.2.5/debian/README.Debian @@ -0,0 +1,8 @@ +eclipse-pydev for Ubuntu +------------------------ + +Since Ubuntu uses GCJ-4.1 to compile java code, the sources had to be backported to use Java 1.4. + +Both Jython and Python interpreter have to be set up correctly in order to be able to use the Jython plugin. + + -- Vladimir Lapacek , Sat, 11 Nov 2006 20:32:14 +0200 --- eclipse-pydev-1.2.5.orig/debian/eclipse-pydev-gcj.postinst +++ eclipse-pydev-1.2.5/debian/eclipse-pydev-gcj.postinst @@ -0,0 +1,14 @@ +#!/bin/sh + +set -e + +if [ -x /usr/sbin/update-gcj-classmaps-eclipse ]; then + /usr/sbin/update-gcj-classmaps-eclipse +fi + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 --- eclipse-pydev-1.2.5.orig/debian/copyright +++ eclipse-pydev-1.2.5/debian/copyright @@ -0,0 +1,237 @@ +This package was debianized by Vladimír Lapáček on +Sun, 11 Dec 2005 20:32:14 -0700. + +It was downloaded from CVS :pserver:anonymous@cvs.sf.net:/cvsroot/pydev + +Copyright Holder: Fabio Zadrozny + +License: + +Common Public License - v 1.0 + +THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS COMMON +PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF +THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. + +1. DEFINITIONS + +"Contribution" means: + + a) in the case of the initial Contributor, the initial code and +documentation distributed under this Agreement, and + b) in the case of each subsequent Contributor: + + i) changes to the Program, and + + ii) additions to the Program; + + where such changes and/or additions to the Program originate from +and are distributed by that particular Contributor. A Contribution +'originates' from a Contributor if it was added to the Program by such +Contributor itself or anyone acting on such Contributor's behalf. +Contributions do not include additions to the Program which: (i) are +separate modules of software distributed in conjunction with the Program +under their own license agreement, and (ii) are not derivative works of +the Program. + +"Contributor" means any person or entity that distributes the Program. + +"Licensed Patents " mean patent claims licensable by a Contributor which +are necessarily infringed by the use or sale of its Contribution alone +or when combined with the Program. + +"Program" means the Contributions distributed in accordance with this +Agreement. + +"Recipient" means anyone who receives the Program under this Agreement, +including all Contributors. + +2. GRANT OF RIGHTS + + a) Subject to the terms of this Agreement, each Contributor hereby +grants Recipient a non-exclusive, worldwide, royalty-free copyright +license to reproduce, prepare derivative works of, publicly display, +publicly perform, distribute and sublicense the Contribution of such +Contributor, if any, and such derivative works, in source code and +object code form. + + b) Subject to the terms of this Agreement, each Contributor hereby +grants Recipient a non-exclusive, worldwide, royalty-free patent license +under Licensed Patents to make, use, sell, offer to sell, import and +otherwise transfer the Contribution of such Contributor, if any, in +source code and object code form. This patent license shall apply to the +combination of the Contribution and the Program if, at the time the +Contribution is added by the Contributor, such addition of the +Contribution causes such combination to be covered by the Licensed +Patents. The patent license shall not apply to any other combinations +which include the Contribution. No hardware per se is licensed +hereunder. + + c) Recipient understands that although each Contributor grants the +licenses to its Contributions set forth herein, no assurances are +provided by any Contributor that the Program does not infringe the +patent or other intellectual property rights of any other entity. Each +Contributor disclaims any liability to Recipient for claims brought by +any other entity based on infringement of intellectual property rights +or otherwise. As a condition to exercising the rights and licenses +granted hereunder, each Recipient hereby assumes sole responsibility to +secure any other intellectual property rights needed, if any. For +example, if a third party patent license is required to allow Recipient +to distribute the Program, it is Recipient's responsibility to acquire +that license before distributing the Program. + + d) Each Contributor represents that to its knowledge it has +sufficient copyright rights in its Contribution, if any, to grant the +copyright license set forth in this Agreement. + +3. REQUIREMENTS + +A Contributor may choose to distribute the Program in object code form +under its own license agreement, provided that: + + a) it complies with the terms and conditions of this Agreement; +and + + b) its license agreement: + + i) effectively disclaims on behalf of all Contributors all +warranties and conditions, express and implied, including warranties or +conditions of title and non-infringement, and implied warranties or +conditions of merchantability and fitness for a particular purpose; + + ii) effectively excludes on behalf of all Contributors all +liability for damages, including direct, indirect, special, incidental +and consequential damages, such as lost profits; + + iii) states that any provisions which differ from this Agreement +are offered by that Contributor alone and not by any other party; and + + iv) states that source code for the Program is available from such +Contributor, and informs licensees how to obtain it in a reasonable +manner on or through a medium customarily used for software exchange. + +When the Program is made available in source code form: + + a) it must be made available under this Agreement; and + + b) a copy of this Agreement must be included with each copy of the +Program. + +Contributors may not remove or alter any copyright notices contained +within the Program. + +Each Contributor must identify itself as the originator of its +Contribution, if any, in a manner that reasonably allows subsequent +Recipients to identify the originator of the Contribution. + +4. COMMERCIAL DISTRIBUTION + +Commercial distributors of software may accept certain responsibilities +with respect to end users, business partners and the like. While this +license is intended to facilitate the commercial use of the Program, the +Contributor who includes the Program in a commercial product offering +should do so in a manner which does not create potential liability for +other Contributors. Therefore, if a Contributor includes the Program in +a commercial product offering, such Contributor ("Commercial +Contributor") hereby agrees to defend and indemnify every other +Contributor ("Indemnified Contributor") against any losses, damages and +costs (collectively "Losses") arising from claims, lawsuits and other +legal actions brought by a third party against the Indemnified +Contributor to the extent caused by the acts or omissions of such +Commercial Contributor in connection with its distribution of the +Program in a commercial product offering. The obligations in this +section do not apply to any claims or Losses relating to any actual or +alleged intellectual property infringement. In order to qualify, an +Indemnified Contributor must: a) promptly notify the Commercial +Contributor in writing of such claim, and b) allow the Commercial +Contributor to control, and cooperate with the Commercial Contributor +in, the defense and any related settlement negotiations. The Indemnified +Contributor may participate in any such claim at its own expense. + +For example, a Contributor might include the Program in a commercial +product offering, Product X. That Contributor is then a Commercial +Contributor. If that Commercial Contributor then makes performance +claims, or offers warranties related to Product X, those performance +claims and warranties are such Commercial Contributor's responsibility +alone. Under this section, the Commercial Contributor would have to +defend claims against the other Contributors related to those +performance claims and warranties, and if a court requires any other +Contributor to pay any damages as a result, the Commercial Contributor +must pay those damages. + +5. NO WARRANTY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED +ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, +EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES +OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR +A PARTICULAR PURPOSE. Each Recipient is solely responsible for +determining the appropriateness of using and distributing the Program +and assumes all risks associated with its exercise of rights under this +Agreement, including but not limited to the risks and costs of program +errors, compliance with applicable laws, damage to or loss of data, +programs or equipment, and unavailability or interruption of operations. + +6. DISCLAIMER OF LIABILITY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR +ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING +WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR +DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED +HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +7. GENERAL + +If any provision of this Agreement is invalid or unenforceable under +applicable law, it shall not affect the validity or enforceability of +the remainder of the terms of this Agreement, and without further action +by the parties hereto, such provision shall be reformed to the minimum +extent necessary to make such provision valid and enforceable. + +If Recipient institutes patent litigation against a Contributor with +respect to a patent applicable to software (including a cross-claim or +counterclaim in a lawsuit), then any patent licenses granted by that +Contributor to such Recipient under this Agreement shall terminate as of +the date such litigation is filed. In addition, if Recipient institutes +patent litigation against any entity (including a cross-claim or +counterclaim in a lawsuit) alleging that the Program itself (excluding +combinations of the Program with other software or hardware) infringes +such Recipient's patent(s), then such Recipient's rights granted under +Section 2(b) shall terminate as of the date such litigation is filed. + +All Recipient's rights under this Agreement shall terminate if it fails +to comply with any of the material terms or conditions of this Agreement +and does not cure such failure in a reasonable period of time after +becoming aware of such noncompliance. If all Recipient's rights under +this Agreement terminate, Recipient agrees to cease use and distribution +of the Program as soon as reasonably practicable. However, Recipient's +obligations under this Agreement and any licenses granted by Recipient +relating to the Program shall continue and survive. + +Everyone is permitted to copy and distribute copies of this Agreement, +but in order to avoid inconsistency the Agreement is copyrighted and may +only be modified in the following manner. The Agreement Steward reserves +the right to publish new versions (including revisions) of this +Agreement from time to time. No one other than the Agreement Steward has +the right to modify this Agreement. IBM is the initial Agreement +Steward. IBM may assign the responsibility to serve as the Agreement +Steward to a suitable separate entity. Each new version of the Agreement +will be given a distinguishing version number. The Program (including +Contributions) may always be distributed subject to the version of the +Agreement under which it was received. In addition, after a new version +of the Agreement is published, Contributor may elect to distribute the +Program (including its Contributions) under the new version. Except as +expressly stated in Sections 2(a) and 2(b) above, Recipient receives no +rights or licenses to the intellectual property of any Contributor under +this Agreement, whether expressly, by implication, estoppel or +otherwise. All rights in the Program not expressly granted under this +Agreement are reserved. + +This Agreement is governed by the laws of the State of New York and the +intellectual property laws of the United States of America. No party to +this Agreement will bring a legal action under this Agreement more than +one year after the cause of action arose. Each party waives its rights +to a jury trial in any resulting litigation. --- eclipse-pydev-1.2.5.orig/debian/compat +++ eclipse-pydev-1.2.5/debian/compat @@ -0,0 +1 @@ +4 --- eclipse-pydev-1.2.5.orig/debian/aot-compile +++ eclipse-pydev-1.2.5/debian/aot-compile @@ -0,0 +1,210 @@ +#!/usr/bin/env python + +import copy +import os +import string +import sys +import zipfile + +GCJ = "/usr/bin/gcj-4.3" +GCJFLAGS = [ "-O2", "-fPIC", "-findirect-dispatch", "-fjni"] +LDFLAGS = ["-Wl,-Bsymbolic"] + +class Error(Exception): + pass + +class JarFile(zipfile.ZipFile): + def isSubsetOf(self, other): + """Returns True if identical copies of all classes in this + jarfile exist in the other.""" + for other_item in other.infolist(): + if not other_item.filename.endswith(".class"): + continue + try: + self_item = self.getinfo(other_item.filename) + except KeyError: + return False + if self_item.CRC != other_item.CRC: + return False + return True + + def numClasses(self): + """Return the number of classfiles within this jarfile.""" + return len([ + item for item in self.namelist() if item.endswith(".class")]) + + def classPrefix(self): + """Return the longest prefix common to all classes.""" + return os.path.commonprefix([ + item for item in self.namelist() if item.endswith(".class")]) + +def strip_exclusions(jars, exclusions): + """Remove user-excluded jars from the list. We're really strict + about this to ensure that dead options don't get left in + specfiles.""" + jars = copy.copy(jars) + for exclusion in exclusions: + for jar in jars: + if jar.filename == exclusion: + jars.remove(jar) + break + else: + raise Error, "%s: file does not exist or is not a jar" % exclusion + return jars + +def weed_jars(jars): + """Remove any jarfiles that are completely contained within + another. This is more common than you'd think, and we only + need one nativified copy of each class after all.""" + jars = copy.copy(jars) + while True: + for jar1 in jars: + for jar2 in jars: + if jar1 is jar2: + continue + if jar1.isSubsetOf(jar2): + msg = "subsetted %s" % jar2.filename + if jar2.isSubsetOf(jar1): + msg += " (identical)" + warn(msg) + jars.remove(jar2) + break + else: + continue + break + else: + break + continue + return jars + +def set_basenames(jars): + """Ensure that each jarfile has a different basename.""" + names = {} + for jar in jars: + name = os.path.basename(jar.filename) + if not names.has_key(name): + names[name] = [] + names[name].append(jar) + for name, set in names.items(): + if len(set) == 1: + set[0].basename = name + continue + # prefix the jar filenames to make them unique + # XXX will not work in most cases -- needs generalising + set = [(jar.filename.split(os.sep), jar) for jar in set] + minlen = min([len(bits) for bits, jar in set]) + set = [(bits[-minlen:], jar) for bits, jar in set] + bits = apply(zip, [bits for bits, jar in set]) + while True: + row = bits[-2] + for bit in row[1:]: + if bit != row[0]: + break + else: + del bits[-2] + continue + break + set = zip( + ["_".join(name) for name in apply(zip, bits[-2:])], + [jar for bits, jar in set]) + for name, jar in set: + warn("building %s as %s" % (jar.filename, name)) + jar.basename = name + # XXX keep this check until we're properly general + names = {} + for jar in jars: + name = jar.basename + if names.has_key(name): + raise Error, "%s: duplicate jarname" % name + names[name] = 1 + +def aot_compile_jar(name, jar, soname, max_classes_per_jar = 1000): + """Generate the shared library and class mapping for one jarfile. + If the shared library already exists then it will not be + overwritten. This is to allow optimizer failures and the like to + be worked around.""" + dir = soname[:soname.rfind('/')] + if os.path.exists(soname): + warn("not recreating %s" % soname) + else: + cleanup = [] + # prepare + if jar.numClasses() > max_classes_per_jar: + warn("splitting %s" % jar.filename) + sources = split_jarfile(jar, dir, max_classes_per_jar) + cleanup.extend(sources) + elif jar.filename.endswith(".jar"): + sources = [jar.filename] + else: + sources = [symlink_jarfile(jar.filename, dir)] + cleanup.extend(sources) + # compile and link + if len(sources) == 1: + system([GCJ, "-shared"] + + GCJFLAGS + LDFLAGS + + [sources[0], "-o", soname]) + else: + objects = [] + for source in sources: + object = os.path.join(dir, os.path.basename(source) + ".o") + system([GCJ, "-c"] + + GCJFLAGS + + [source, "-o", object]) + objects.append(object) + cleanup.append(object) + system([GCJ, "-shared"] + + GCJFLAGS + LDFLAGS + + objects + ["-o", soname]) + # clean up + for item in cleanup: + os.unlink(item) + # dbtool +# dbname = soname[:soname.rfind(".")] + ".db" +# soname = os.path.join(libdir, os.path.basename(soname)) +# system([PATHS["dbtool"], "-n", dbname, "64"]) +# system([PATHS["dbtool"], "-f", dbname, jar.filename, soname]) + +def split_jarfile(src, dir, split): + """Split large jarfiles to avoid huge assembler files.""" + jarfiles, dst = [], None + for item in src.infolist(): + if (dst is None or item.filename.endswith(".class") and size >= split): + if dst is not None: + dst.close() + path = os.path.join(dir, "%s.%d.jar" % ( + os.path.basename(src.filename), len(jarfiles) + 1)) + jarfiles.append(path) + dst = zipfile.ZipFile(path, "w", zipfile.ZIP_STORED) + size = 0 + dst.writestr(item, src.read(item.filename)) + size += 1 + dst.close() + return jarfiles + +def symlink_jarfile(src, dir): + """Symlink a jarfile with a '.jar' extension so gcj knows what it is.""" + dst = os.path.join(dir, os.path.basename(src) + ".jar") + os.symlink(src, dst) + return dst + +def system(command): + """Execute a command.""" + prefix = os.environ.get("PS4", "+ ") + prefix = prefix[0] + prefix + print >>sys.stderr, prefix + " ".join(command) + + status = os.spawnv(os.P_WAIT, command[0], command) + if status > 0: + raise Error, "%s exited with code %d" % (command[0], status) + elif status < 0: + raise Error, "%s killed by signal %d" % (command[0], -status) + +def warn(msg): + """Print a warning message.""" + print >>sys.stderr, "%s: warning: %s" % ( + os.path.basename(sys.argv[0]), msg) + +if __name__ == "__main__": + jarpath = sys.argv[1] + jarname = jarpath[jarpath.rfind(os.sep)+1:] + aot_compile_jar(jarname, JarFile(jarpath, "r"), sys.argv[2]) --- eclipse-pydev-1.2.5.orig/debian/rules +++ eclipse-pydev-1.2.5/debian/rules @@ -0,0 +1,177 @@ +#!/usr/bin/make -f + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +export LC_ALL=C +CURDIR=$(shell pwd) +RELENGDIR=org.python.pydev.releng +DOCDIR=org.python.pydev.help/pydev.sf.net +BUILD_TREE=$(CURDIR)/build_tree +DEBIAN_TMP=$(CURDIR)/debian/tmp + +# GCJ configuration +# GCJ_RUN command line to launch gcj +# AOT_COMPILE command line to AOT compile jars to native +GCJ_VERSION=4.3 +GCJ_RUN=/usr/bin/gcj-$(GCJ_VERSION) +GCJ_DBTOOL=/usr/bin/gcj-dbtool-$(GCJ_VERSION) +GCJ_JARDIR=/usr/lib/gcj-$(GCJ_VERSION) +AOT_COMPILE=python $(CURDIR)/debian/aot-compile +PYDEV_VERSION=1.2.5 +PYDEV_BUILD_ID=1_2_5 + +# Virtual machine configuration +ECLIPSE_HOME=/usr/lib/eclipse +ECLIPSE_ARCH=usr/lib/eclipse +JAVA_RUN=/usr/lib/jvm/default-java/bin/java +JAVA_CLASSPATH=$(ECLIPSE_HOME)/startup.jar + +PACKAGE = eclipse-pydev +enable_native = yes + +include /usr/share/dpatch/dpatch.make + +build: patch build-java +build-java: build-java-stamp +#build-doc: build-doc-stamp + +build-java-stamp: + dh_testdir + + cd $(RELENGDIR) && \ + $(JAVA_RUN) \ + --noverify \ + -cp $(JAVA_CLASSPATH) \ + org.eclipse.core.launcher.Main \ + -application org.eclipse.ant.core.antRunner \ + -buildfile build.xml \ + -Dpde.build.scripts=$(ECLIPSE_HOME)/plugins/org.eclipse.pde.build_3.2.1.r321_v20060823/scripts \ + -DjavacFailOnError=True \ + -DEC_HOME=$(ECLIPSE_HOME) \ + -DEC_WORKSPACE=$(CURDIR) \ + -DbaseLocation=$(ECLIPSE_HOME) \ + -DbuildDirectory=$(BUILD_TREE) \ + -DeclipseResults=$(BUILD_TREE) \ + -DPYDEV_VERSION=$(PYDEV_VERSION) \ + -DBUILD_ID=$(PYDEV_BUILD_ID) \ + -DdontFetchAnything=True \ + -DcleanAfter=True + + touch build-java-stamp + +build-gcj: build-gcj-stamp +build-gcj-stamp: install-stamp + dh_testdir +ifeq ($(enable_native),yes) + : # Generate gcj native libraries for every Jar in Eclipse. These get + : # placed into the ECLIPSE_ARCH structure which mirrors that of + : # ECLIPSE_HOME: by plugin. + mkdir -p debian/$(PACKAGE)/$(GCJ_JARDIR) && \ + cd debian/$(PACKAGE)/$(ECLIPSE_HOME)/plugins && \ + for jar in $$(find . -name '*.jar' | sort); do \ + echo "$$jar" && \ + mkdir -p $(CURDIR)/debian/$(PACKAGE)-gcj/$(GCJ_JARDIR)/$$(dirname $$jar) && \ + $(AOT_COMPILE) $$jar $(CURDIR)/debian/$(PACKAGE)-gcj/$(GCJ_JARDIR)/$$jar.so || exit $$?; \ + done + + : # Remove these native plugins for one reason or another. + for so in \ + org.eclipse.jface.text \ + org.eclipse.ui.workbench \ + org.eclipse.ui.forms; \ + do \ + find debian/$(PACKAGE)-gcj/$(GCJ_JARDIR) -name "$$so_\*.jar.so" -exec \ + rm '{}' ';' || true; \ + done +endif + touch build-gcj-stamp + +#build-doc-stamp: +# dh_testdir +# +# cd $(BUILD_TREE)/tmp/eclipse/plugins/org.python.pydev.help_$(PYDEV_VERSION)/pydev.sf.net && \ +# python build.py +# +# touch build-doc-stamp + +install: install-stamp +install-stamp: build-java-stamp + dh_testdir + dh_testroot + pwd + dh_clean -k + dh_installdirs + dh_install + dh_link + dh_python + + # fix file permissions to comply with debian package policy + find debian/$(PACKAGE) -name '*.py' -a ! -perm +a+x -print | xargs grep -l '^#!' | xargs chmod a+x + # remove included bicyclerepair files included in the original sources + rm -rf debian/$(PACKAGE)/usr/lib/eclipse/plugins/org.python.pydev_$(PYDEV_VERSION)/PySrc/ThirdParty + + touch install-stamp + +# Build architecture-independent files here. +binary-indep: build install + dh_testdir -i + dh_testroot -i + dh_installdocs -i + dh_installchangelogs -i + dh_python -i + dh_compress -i + dh_fixperms -i + dh_installdeb -i + dh_gencontrol -i + dh_md5sums -i + dh_builddeb -i + +# Build architecture-dependent files here. +binary-arch: build install build-gcj + dh_testdir -a + dh_testroot -a +ifeq ($(enable_native),yes) + echo "generating classmaps for $(PACKAGE) ... "; \ + mkdir -p debian/$(PACKAGE)-gcj/usr/share/gcj/classmap.d + if test -d debian/$(PACKAGE)/$(ECLIPSE_HOME)/plugins; then \ + ( cd debian/$(PACKAGE)/$(ECLIPSE_HOME)/plugins && \ + for jar in $$(find . -name '*.jar' -type f); do \ + echo ' ' $(PACKAGE)/$(ECLIPSE_HOME)/plugins/$${jar} '->' $(GCJ_JARDIR)/$${jar}.so; \ + $(GCJ_DBTOOL) \ + -f $(CURDIR)/debian/$(PACKAGE)-gcj/usr/share/gcj/classmap.d/$(PACKAGE).db \ + $${jar} $(GCJ_JARDIR)/$${jar}.so || exit 1; \ + done ); \ + fi +endif + dh_installdocs -a + dh_installexamples -a + dh_installmenu -a + dh_installman -a + dh_installinfo -a + dh_installchangelogs -a + dh_link -a + dh_fixperms -a + dh_strip -a + dh_compress -a + dh_shlibdeps -a + dh_makeshlibs -a + dh_installdeb -a + dh_gencontrol -a + dh_md5sums -a + dh_builddeb -a + +binary: binary-indep binary-arch + +clean: clean-patched unpatch +clean-patched: + dh_testdir + dh_testroot + dh_clean -k + + rm -f *-stamp + rm -rf $(BUILD_TREE) + rm -rf $(RELENGDIR)/{workspace,results} + rm -rf debian/files + +.PHONY: build build-java install binary-indep binary-arch binary clean clean-patched --- eclipse-pydev-1.2.5.orig/debian/changelog +++ eclipse-pydev-1.2.5/debian/changelog @@ -0,0 +1,80 @@ +eclipse-pydev (1.2.5-4) unstable; urgency=low + + * Expilictely use gcj-4.3 instead of gcj-4.1. + + -- Matthias Klose Sun, 11 May 2008 20:40:07 +0200 + +eclipse-pydev (1.2.5-3) unstable; urgency=low + + * debian/control: Remove duplicate attributes. Closes: #477375. + * Don't build on alpha, arm, hppa and hurd-i386. Closes: #477856. + * Build using recent gcj. Closes: #432539. + * Depend on eclipse instead of eclipse-sdk. Closes: #433409. + + -- Matthias Klose Sat, 10 May 2008 10:38:52 +0200 + +eclipse-pydev (1.2.5-2) unstable; urgency=low + + * Upload Ubuntu package to Debian. Closes: #316731. + + -- Matthias Klose Sat, 13 Jan 2007 22:27:43 +0100 + +eclipse-pydev (1.2.5-1ubuntu1) feisty; urgency=low + + * New upstream release + * Removed Jython code from the sources + * Patched to work when configured to use system Jython + + -- Vladimír Lapáček Sat, 06 Nov 2006 22:00:01 +0200 + +eclipse-pydev (1.2.0-1ubuntu3) edgy; urgency=low + + * Changed the installation directory to /usr/lib/eclipse + * Use new eclipse 3.2.1 for build + + -- Vladimír Lapáček Wed, 18 Oct 2006 23:29:37 +0200 + +eclipse-pydev (1.2.0-1ubuntu2) edgy; urgency=low + + * rebuild for libgcj7 -> libgcj7-0 + + -- Michael Bienia Fri, 25 Aug 2006 18:05:43 +0200 + +eclipse-pydev (1.2.0-1ubuntu1) edgy; urgency=low + + * New upstram version + * Used backport patches from linux-distros-dev@eclipse.org + * Removed debian/pydev.links.disabled + * Removed ${python:Depends} from dependency list + + -- Vladimír Lapáček Sat, 24 Jun 2006 21:26:11 +0100 + +eclipse-pydev (1.0.3-1ubuntu1) dapper; urgency=low + + * New upstream version + + -- Vladimír Lapáček Fri, 31 Mar 2006 20:32:14 +0100 + +eclipse-pydev (0.9.8.3-1ubuntu2) dapper; urgency=low + + * debian/control: s/Build-Depends-Indep/Build-Depends/. + + -- Matthias Klose Thu, 23 Mar 2006 15:28:46 +0100 + +eclipse-pydev (0.9.8.3-1ubuntu1) dapper; urgency=low + + * Build using java-gcj-compat-dev. + * debian/rules: Updates for eclipse-3.1.2. + * debian/control: Require eclipse-3.1.2. + * eclipse-pydev-gcj: New native package. + * Remove retroweaver jar's from the source package. + + -- Matthias Klose Wed, 22 Mar 2006 23:17:02 +0100 + +eclipse-pydev (0.9.8.3-1) dapper; urgency=low + + * Initial release. + * Backport to use only Java 1.4 compatible code. The free runtimes don't + support 1.5 yet very well. + + -- Vladimír Lapáček Sun, 11 Dec 2005 20:32:14 -0700 --- eclipse-pydev-1.2.5.orig/debian/eclipse-pydev.debhelper.log +++ eclipse-pydev-1.2.5/debian/eclipse-pydev.debhelper.log @@ -0,0 +1,26 @@ +dh_installdirs +dh_install +dh_link +dh_python +dh_installdocs +dh_installchangelogs +dh_pycentral +dh_compress +dh_fixperms +dh_installdeb +dh_gencontrol +dh_md5sums +dh_builddeb +dh_installdirs +dh_install +dh_link +dh_python +dh_installdocs +dh_installchangelogs +dh_python +dh_compress +dh_fixperms +dh_installdeb +dh_gencontrol +dh_md5sums +dh_builddeb --- eclipse-pydev-1.2.5.orig/debian/eclipse-pydev.install +++ eclipse-pydev-1.2.5/debian/eclipse-pydev.install @@ -0,0 +1,2 @@ +build_tree/tmp/eclipse/features/* usr/lib/eclipse/features +build_tree/tmp/eclipse/plugins/* usr/lib/eclipse/plugins --- eclipse-pydev-1.2.5.orig/debian/eclipse-pydev-gcj.debhelper.log +++ eclipse-pydev-1.2.5/debian/eclipse-pydev-gcj.debhelper.log @@ -0,0 +1,24 @@ +dh_installdirs +dh_install +dh_link +dh_python +dh_installdirs +dh_install +dh_link +dh_python +dh_installdocs +dh_installexamples +dh_installmenu +dh_installman +dh_installinfo +dh_installchangelogs +dh_link +dh_fixperms +dh_strip +dh_compress +dh_shlibdeps +dh_makeshlibs +dh_installdeb +dh_gencontrol +dh_md5sums +dh_builddeb --- eclipse-pydev-1.2.5.orig/debian/eclipse-pydev-gcj.postrm +++ eclipse-pydev-1.2.5/debian/eclipse-pydev-gcj.postrm @@ -0,0 +1,46 @@ +#!/bin/sh -e + +db_update() +{ + # Merges per-package classmap databases into the system-wide classmap database. + + gccversion=4.3 + + gcjdbtool=/usr/bin/gcj-dbtool-${gccversion} + classmapd=/usr/share/gcj/classmap.d + classmaps=/var/lib/gcj-${gccversion}/classmap.db + + if [ ! -x $gcjdbtool ]; then + echo >&2 "skip classmap deregistration, $gcjdbtool not found". + return 0 + fi + + set +x + + # Move into a temporary file to avoid editing the existing file. The existing + # file could be mmap()ed by gij processes. + find ${classmapd} -name '*.db' -print0 | ${gcjdbtool} -0 -m ${classmaps}.tmp + if [ $? -ne 0 ]; then + echo "error merging classmaps" >&2 + set -x + return 1 + fi + + mv ${classmaps}.tmp ${classmaps} + if [ $? -ne 0 ]; then + echo "could not replace existing classmap database" >&2 + set -x + return 1 + fi + set -x +} + +db_update + + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 --- eclipse-pydev-1.2.5.orig/debian/control +++ eclipse-pydev-1.2.5/debian/control @@ -0,0 +1,28 @@ +Source: eclipse-pydev +Section: devel +Priority: optional +Maintainer: Debian Java Maintainers +Uploaders: Matthias Klose +Build-Depends: debhelper (>= 4.0.0), eclipse-pde (>= 3.2.1), default-jdk-builddep, libcommons-codec-java, dpatch, python, jython +Standards-Version: 3.7.3 + +Package: eclipse-pydev +Architecture: all +Depends: eclipse (>= 3.2.1), python-dev, bicyclerepair, libcommons-codec-java, python, jython +Recommends: eclipse-platform-gcj, eclipse-pydev-gcj +Description: Python development plug-in for Eclipse + PyDev is a plugin that enables users to use Eclipse for Python and Jython + development. It comes with many goodies such as code completion, syntax + highlighting, syntax analysis, refactor, debug and many others. + . + This package contains the plugin itself. + +Package: eclipse-pydev-gcj +Architecture: any +Depends: eclipse-pydev (>= ${Source-Version}), eclipse-platform-gcj, ${shlibs:Depends} +Description: Python development plug-in for Eclipse (GCJ version) + PyDev is a plugin that enables users to use Eclipse for Python and Jython + development. It comes with many goodies such as code completion, syntax + highlighting, syntax analysis, refactor, debug and many others. + . + This package contains native GCJ-compiled plugins. --- eclipse-pydev-1.2.5.orig/debian/patches/eclipse-pydev-remove-jython.dpatch +++ eclipse-pydev-1.2.5/debian/patches/eclipse-pydev-remove-jython.dpatch @@ -0,0 +1,53 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 99-unnamed.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ + +diff -ruN eclipse-pydev-1.2.4/org.python.pydev.jython/META-INF/MANIFEST.MF eclipse-pydev-1.2.4-patched/org.python.pydev.jython/META-INF/MANIFEST.MF +--- eclipse-pydev-1.2.4/org.python.pydev.jython/META-INF/MANIFEST.MF 2006-10-28 22:21:38.000000000 +0200 ++++ eclipse-pydev-1.2.4-patched/org.python.pydev.jython/META-INF/MANIFEST.MF 2006-10-29 08:42:13.000000000 +0100 +@@ -4,7 +4,7 @@ + Bundle-SymbolicName: org.python.pydev.jython; singleton:=true + Bundle-Version: 1.2.4 + Bundle-ClassPath: pydev-jython.jar, +- jython.jar ++ external:/usr/share/java/jython.jar + Bundle-Activator: org.python.pydev.jython.JythonPlugin + Bundle-Vendor: Fabio Zadrozny + Bundle-Localization: plugin +@@ -16,12 +16,6 @@ + org.eclipse.jface.text, + org.junit + Eclipse-AutoStart: true +-Export-Package: org.python.compiler, +- org.python.core, +- org.python.modules, +- org.python.modules.sre, +- org.python.parser, +- org.python.pydev.jython, +- org.python.pydev.jython.ui, +- org.python.rmi, +- org.python.util ++Export-Package: org.python.pydev.jython, ++ org.python.pydev.jython.ui ++ +diff -ruN eclipse-pydev-1.2.4/org.python.pydev.jython/src/org/python/pydev/jython/JythonPlugin.java eclipse-pydev-1.2.4-patched/org.python.pydev.jython/src/org/python/pydev/jython/JythonPlugin.java +--- eclipse-pydev-1.2.4/org.python.pydev.jython/src/org/python/pydev/jython/JythonPlugin.java 2006-10-29 21:12:21.000000000 +0100 ++++ eclipse-pydev-1.2.4-patched/org.python.pydev.jython/src/org/python/pydev/jython/JythonPlugin.java 2006-10-29 21:19:19.000000000 +0100 +@@ -218,12 +218,7 @@ + } + + public static File getJythonLibDir(){ +- try { +- IPath relative = new Path("Lib"); +- return getBundleInfo().getRelativePath(relative); +- } catch (Exception e) { +- throw new RuntimeException(e); +- } ++ return new File("/usr/share/jython/Lib"); + } + public static File getFileWithinJySrc(String f){ + try { --- eclipse-pydev-1.2.5.orig/debian/patches/eclipse-pydev-releng.dpatch +++ eclipse-pydev-1.2.5/debian/patches/eclipse-pydev-releng.dpatch @@ -0,0 +1,134 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 99-unnamed.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ + +diff -ruN eclipse-pydev-1.2.0/org.python.pydev.releng/build.xml eclipse-pydev-1.2.0-patched/org.python.pydev.releng/build.xml +--- eclipse-pydev-1.2.0/org.python.pydev.releng/build.xml 2006-06-07 15:25:28.000000000 +0200 ++++ eclipse-pydev-1.2.0-patched/org.python.pydev.releng/build.xml 2006-06-25 10:31:20.000000000 +0200 +@@ -2,7 +2,7 @@ + + + +- ++ + + + +@@ -17,8 +17,8 @@ + + + +- +- ++ ++ + + + +@@ -27,7 +27,7 @@ + + + +- ++ + + + +@@ -95,17 +95,6 @@ + + + +- +- +- +- +- +- +- +- +- +- +- + + + +diff -ru eclipse-pydev-1.2.0/org.python.pydev.releng/customTargets.xml eclipse-pydev-1.2.0-patched/org.python.pydev.releng/customTargets.xml +--- eclipse-pydev-1.2.0/org.python.pydev.releng/customTargets.xml 2006-06-25 12:10:26.000000000 +0200 ++++ eclipse-pydev-1.2.0-patched/org.python.pydev.releng/customTargets.xml 2006-06-25 10:33:35.000000000 +0200 +@@ -1,13 +1,5 @@ + + +- +- +- +- +- +- +- + + + +@@ -146,25 +138,6 @@ + + + +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- + + + +@@ -213,32 +186,6 @@ + + + +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- + + + --- eclipse-pydev-1.2.5.orig/debian/patches/eclipse-pydev-remove-brm.dpatch +++ eclipse-pydev-1.2.5/debian/patches/eclipse-pydev-remove-brm.dpatch @@ -0,0 +1,24 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 99-unnamed.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ + +diff -ruN eclipse-pydev-1.2.0/org.python.pydev/PySrc/refactoring.py eclipse-pydev-1.2.0-patched/org.python.pydev/PySrc/refactoring.py +--- eclipse-pydev-1.2.0/org.python.pydev/PySrc/refactoring.py 2006-06-25 10:18:49.000000000 +0200 ++++ eclipse-pydev-1.2.0-patched/org.python.pydev/PySrc/refactoring.py 2006-06-25 09:53:46.000000000 +0200 +@@ -5,11 +5,7 @@ + import traceback + import StringIO + import urllib +- +-#kind of hack to get the bicicle repair man without having it in the pythonpath. +-sys.path.insert(1, os.path.join(os.path.dirname(sys.argv[0]), +- "ThirdParty", "brm")) +-import ThirdParty.brm.bike as bike ++import bike + + + --- eclipse-pydev-1.2.5.orig/debian/patches/eclipse-pydev-remove-commons-codec.dpatch +++ eclipse-pydev-1.2.5/debian/patches/eclipse-pydev-remove-commons-codec.dpatch @@ -0,0 +1,34 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 99-unnamed.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ + +diff -ruN eclipse-pydev-1.2.0/org.python.pydev.core/META-INF/MANIFEST.MF eclipse-pydev-1.2.0-patched/org.python.pydev.core/META-INF/MANIFEST.MF +--- eclipse-pydev-1.2.0/org.python.pydev.core/META-INF/MANIFEST.MF 2006-06-25 09:49:01.000000000 +0200 ++++ eclipse-pydev-1.2.0-patched/org.python.pydev.core/META-INF/MANIFEST.MF 2006-06-25 10:26:08.000000000 +0200 +@@ -4,7 +4,7 @@ + Bundle-SymbolicName: org.python.pydev.core; singleton:=true + Bundle-Version: 0.9.7.1 + Bundle-ClassPath: core.jar, +- commons-codec.jar ++ external:/usr/share/java/commons-codec.jar + Bundle-Activator: org.python.pydev.core.CorePlugin + Bundle-Vendor: Fabio Zadrozny + Bundle-Localization: plugin +@@ -16,12 +16,7 @@ + org.eclipse.ui.workbench.texteditor, + org.eclipse.core.filebuffers + Eclipse-AutoStart: true +-Export-Package: org.apache.commons.codec, +- org.apache.commons.codec.binary, +- org.apache.commons.codec.digest, +- org.apache.commons.codec.language, +- org.apache.commons.codec.net, +- org.python.pydev.core, ++Export-Package: org.python.pydev.core, + org.python.pydev.core.bundle, + org.python.pydev.core.cache, + org.python.pydev.core.docutils, --- eclipse-pydev-1.2.5.orig/debian/patches/00list +++ eclipse-pydev-1.2.5/debian/patches/00list @@ -0,0 +1,6 @@ +eclipse-pydev-1.2.5-backport-megapatch.dpatch +eclipse-pydev-remove-brm.dpatch +eclipse-pydev-remove-commons-codec.dpatch +eclipse-pydev-remove-jython.dpatch +eclipse-pydev-releng.dpatch +eclipse-pydev-setup-jython.dpatch --- eclipse-pydev-1.2.5.orig/debian/patches/eclipse-pydev-setup-jython.dpatch +++ eclipse-pydev-1.2.5/debian/patches/eclipse-pydev-setup-jython.dpatch @@ -0,0 +1,141 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 99-unnamed.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimpleJythonRunner.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimpleJythonRunner.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimpleJythonRunner.java 2006-11-12 07:54:54.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimpleJythonRunner.java 2006-11-12 08:27:26.000000000 +0100 +@@ -26,13 +26,28 @@ + try { + String javaLoc = JavaVmLocationFinder.findDefaultJavaExecutable().getCanonicalPath(); + +- String[] s = new String[]{ +- javaLoc, +- "-classpath", +- jythonJar, +- "org.python.util.jython" +- ,script +- }; ++ String [] s; ++ if (jythonJar.contains("/usr/share/jython/jython") || jythonJar.contains("/usr/share/java/jython")) { ++ s = new String [] { ++ javaLoc, ++ "-Djava.library.path=/usr/lib/jni", ++ "-Dpython.home=/usr/share/jython", ++ "-Dpython.path=/usr/share/jython/Lib:/usr/share/jython/Lib-cpython", ++ "-Dpython.cachedir=/tmp", ++ "-classpath", ++ jythonJar + ":/usr/share/java/libreadline-java.jar", ++ "org.python.util.jython", ++ script ++ }; ++ } else { ++ s = new String[]{ ++ javaLoc, ++ "-classpath", ++ jythonJar, ++ "org.python.util.jython" ++ ,script ++ }; ++ } + String executionString = getCommandLineAsString(s, new String [] {}); + + return runAndGetOutput(executionString, workingDir, project, monitor); +@@ -102,16 +117,35 @@ + if(cacheDir != null){ + cacheDir = "-Dpython.cachedir="+ cacheDir.trim(); + ++ } else { ++ cacheDir = "-Dpython.cachedir=/tmp"; ++ } ++ ++ String [] s; ++ if (jythonJar.contains("/usr/share/jython/jython") || jythonJar.contains("/usr/share/java/jython")) { ++ s = new String [] { ++ javaLoc, ++ cacheDir, ++ "-Djava.library.path=/usr/lib/jni", ++ "-Dpython.home=/usr/share/jython", ++ "-Dpython.path=" + jythonPath.toString(), ++ "-classpath", ++ jythonJar + ":/usr/share/java/libreadline-java.jar:" + jythonPath, ++ "org.python.util.jython", ++ script ++ }; ++ ++ } else { ++ s = new String[]{ ++ javaLoc , ++ cacheDir, ++ "-Dpython.path="+ jythonPath.toString(), ++ "-classpath", ++ jythonJar+pathSeparator+jythonPath, ++ "org.python.util.jython", ++ script ++ }; + } +- String[] s = new String[]{ +- javaLoc , +- cacheDir, +- "-Dpython.path="+ jythonPath.toString(), +- "-classpath", +- jythonJar+pathSeparator+jythonPath, +- "org.python.util.jython", +- script +- }; + String executionString = getCommandLineAsString(s, new String [] {}); + + return executionString; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunnerConfig.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunnerConfig.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunnerConfig.java 2006-11-12 07:54:54.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunnerConfig.java 2006-11-12 08:32:23.000000000 +0100 +@@ -410,20 +410,31 @@ + } + cmdArgs.add(javaLoc); + +- //some nice things on the classpath config: http://mindprod.com/jgloss/classpath.html +- cmdArgs.add("-classpath"); +- String cpath; +- +- //TODO: add some option in the project so that the user can choose to use the +- //classpath specified in the java project instead of the pythonpath itself +- +-// if (project.getNature(Constants.JAVA_NATURE) != null){ +-// cpath = getClasspath(JavaCore.create(project)); +-// } else { +- cpath = interpreter + SimpleRunner.getPythonPathSeparator() + pythonpathUsed; +-// } +- cmdArgs.add(cpath); +- cmdArgs.add("-Dpython.path="+pythonpathUsed); //will be added to the env variables in the run (check if this works on all platforms...) ++ if (interpreter.toString().contains("/usr/share/jython/jython") || interpreter.toString().contains("/usr/share/java/jython")) { ++ cmdArgs.add("-Djava.library.path=/usr/lib/jni"); ++ cmdArgs.add("-Dpython.home=/usr/share/jython"); ++ cmdArgs.add("-Dpython.path="+pythonpathUsed); ++ cmdArgs.add("-Dpython.cachedir=/tmp"); ++ cmdArgs.add("-classpath"); ++ cmdArgs.add(interpreter + ":/usr/share/java/libreadline-java.jar:" + pythonpathUsed); ++ ++ } else { ++ ++ //some nice things on the classpath config: http://mindprod.com/jgloss/classpath.html ++ cmdArgs.add("-classpath"); ++ String cpath; ++ ++ //TODO: add some option in the project so that the user can choose to use the ++ //classpath specified in the java project instead of the pythonpath itself ++ ++ // if (project.getNature(Constants.JAVA_NATURE) != null){ ++ // cpath = getClasspath(JavaCore.create(project)); ++ // } else { ++ cpath = interpreter + SimpleRunner.getPythonPathSeparator() + pythonpathUsed; ++ // } ++ cmdArgs.add(cpath); ++ cmdArgs.add("-Dpython.path="+pythonpathUsed); //will be added to the env variables in the run (check if this works on all platforms...) ++ } + + addVmArgs(cmdArgs); + --- eclipse-pydev-1.2.5.orig/debian/patches/eclipse-pydev-1.2.5-backport-megapatch.dpatch +++ eclipse-pydev-1.2.5/debian/patches/eclipse-pydev-1.2.5-backport-megapatch.dpatch @@ -0,0 +1,11019 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 99-unnamed.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: No description. + +@DPATCH@ + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/.classpath eclipse-pydev-1.2.5-patched/org.python.pydev/.classpath +--- eclipse-pydev-1.2.5/org.python.pydev/.classpath 2005-07-18 15:04:04.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/.classpath 2006-11-05 20:59:42.000000000 +0100 +@@ -1,7 +1,6 @@ + + + +- + + + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/copiedfromeclipsesrc/JavaVmLocationFinder.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/copiedfromeclipsesrc/JavaVmLocationFinder.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/copiedfromeclipsesrc/JavaVmLocationFinder.java 2005-08-13 16:36:24.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/copiedfromeclipsesrc/JavaVmLocationFinder.java 2006-11-05 20:59:42.000000000 +0100 +@@ -89,8 +89,8 @@ + /** + * @return the default java jars (rt.jar ... ) + */ +- public static List findDefaultJavaJars(){ +- return (List) callbackJavaJars.call(null); ++ public static List findDefaultJavaJars(){ ++ return (List) callbackJavaJars.call(null); + } + + /** +@@ -102,10 +102,13 @@ + IVMInstall defaultVMInstall = JavaRuntime.getDefaultVMInstall(); + LibraryLocation[] libraryLocations = JavaRuntime.getLibraryLocations(defaultVMInstall); + +- ArrayList jars = new ArrayList(); +- for (LibraryLocation location : libraryLocations) { +- jars.add(location.getSystemLibraryPath().toFile()); +- } ++ ArrayList jars = new ArrayList(); ++ for (int i = 0; i < libraryLocations.length; i++) { ++ LibraryLocation location = libraryLocations[i]; ++ jars.add(location.getSystemLibraryPath().toFile()); ++ ++ } ++ + return jars; + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/copiedfromeclipsesrc/PythonPairMatcher.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/copiedfromeclipsesrc/PythonPairMatcher.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/copiedfromeclipsesrc/PythonPairMatcher.java 2006-03-16 01:29:59.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/copiedfromeclipsesrc/PythonPairMatcher.java 2006-11-05 20:59:42.000000000 +0100 +@@ -260,11 +260,11 @@ + try { + fReader.configureBackwardReader(document, offset, true, true); + +- Map stack = new HashMap(); ++ Map stack = new HashMap(); + + for (int i = 0; i < fPairs.length; i++) { + if(i %2 == 0){ +- stack.put(fPairs[i], 1); ++ stack.put(new Character(fPairs[i]), new Integer(1)); + } + } + +@@ -272,16 +272,16 @@ + while (c != PythonCodeReader.EOF) { + if (c == ')' || c == ']' || c == '}' ){ + char peer = DocUtils.getPeer((char)c); +- Integer iStack = stack.get((char)peer); +- iStack++; +- stack.put(peer, iStack); ++ Integer iStack = (Integer) stack.get(new Character((char)peer)); ++ iStack = new Integer(iStack.intValue() + 1); ++ stack.put(new Character(peer), iStack); + + }else if (c == '(' || c == '[' || c == '{'){ +- Integer iStack = stack.get((char)c); +- iStack--; +- stack.put((char) c, iStack); ++ Integer iStack = (Integer) stack.get(new Character((char)c)); ++ iStack = new Integer (iStack.intValue() - 1); ++ stack.put(new Character((char) c), iStack); + +- if (iStack == 0){ ++ if (iStack.intValue() == 0){ + return fReader.getOffset(); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pychecker/PyCheckerLauncher.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pychecker/PyCheckerLauncher.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pychecker/PyCheckerLauncher.java 2006-01-31 14:04:39.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pychecker/PyCheckerLauncher.java 2006-11-05 20:59:42.000000000 +0100 +@@ -154,7 +154,7 @@ + + String contents = ""; + try { +- contents = new SimplePythonRunner().runAndGetOutput(pycheckerLocation, new String[]{resourceLocation}, new File(pycheckerLocation).getParentFile()).o1; ++ contents = (String) new SimplePythonRunner().runAndGetOutput(pycheckerLocation, new String[]{resourceLocation}, new File(pycheckerLocation).getParentFile()).o1; + } catch (RuntimeException e) { + System.err.println("Exception during process creation of pychecker on resource: " + resourceLocation + "."); + throw e; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pychecker/PyCheckerVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pychecker/PyCheckerVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pychecker/PyCheckerVisitor.java 2005-10-05 13:15:12.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pychecker/PyCheckerVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -30,5 +30,5 @@ + */ + public void visitRemovedResource(IResource resource, IDocument document, IProgressMonitor monitor) { + } +- ++ + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pycremover/PycRemoverBuilderVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pycremover/PycRemoverBuilderVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pycremover/PycRemoverBuilderVisitor.java 2006-06-07 18:54:43.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pycremover/PycRemoverBuilderVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -19,7 +19,6 @@ + + public class PycRemoverBuilderVisitor extends PyDevBuilderVisitor{ + +- @Override + public void visitChangedResource(IResource resource, IDocument document, IProgressMonitor monitor) { + String loc = resource.getLocation().toOSString(); + if(loc != null && loc.length() > 3){ +@@ -48,7 +47,6 @@ + } + } + +- @Override + public void visitRemovedResource(IResource resource, IDocument document, IProgressMonitor monitor) { + String loc = resource.getLocation().toOSString()+"c"; //.py+c = .pyc + treatPycFile(loc); +@@ -69,12 +67,14 @@ + } + + //remove all: file and links +- for(final IFile workspaceFile : files){ ++ for (int i = 0; i < files.length; i++) { ++ final IFile workspaceFile = files[i]; ++ + if (workspaceFile != null && workspaceFile.exists()) { + + new Job("Deleting File"){ + +- @Override ++ + protected IStatus run(IProgressMonitor monitor) { + monitor.beginTask("Delete .pyc file: "+workspaceFile.getName(), 1); + try { +@@ -96,4 +96,5 @@ + } + } + ++ + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/PyDevBuilder.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/PyDevBuilder.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/PyDevBuilder.java 2006-06-08 20:15:22.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/PyDevBuilder.java 2006-11-05 20:59:42.000000000 +0100 +@@ -46,9 +46,8 @@ + * + * @return a list of visitors for building the application. + */ +- @SuppressWarnings("unchecked") +- public List getVisitors() { +- List list = new ArrayList(); ++ public List getVisitors() { ++ List list = new ArrayList(); + list.add(new PyTodoVisitor()); + list.add(new PyLintVisitor()); + list.add(new PyCodeCompletionVisitor()); +@@ -89,7 +88,7 @@ + PyDevDeltaCounter counterVisitor = new PyDevDeltaCounter(); + delta.accept(counterVisitor); + +- List visitors = getVisitors(); ++ List visitors = getVisitors(); + + //sort by priority + Collections.sort(visitors); +@@ -120,9 +119,9 @@ + + //and the nature... + if (nature != null){ +- List resourcesToParse = new ArrayList(); ++ List resourcesToParse = new ArrayList(); + +- List visitors = getVisitors(); ++ List visitors = getVisitors(); + notifyVisitingWillStart(visitors, monitor, true, nature); + + monitor.beginTask("Building...", (visitors.size() * 100) + 30); +@@ -145,10 +144,10 @@ + //if it is a folder, let's get all python files that are beneath it + //the heuristics to know if we have to analyze them are the same we have + //for a single file +- List l = PydevPlugin.getAllIFilesBelow((IFolder) member); ++ List l = PydevPlugin.getAllIFilesBelow((IFolder) member); + +- for (Iterator iter = l.iterator(); iter.hasNext();) { +- IFile element = iter.next(); ++ for (Iterator iter = l.iterator(); iter.hasNext();) { ++ IFile element = (IFile) iter.next(); + if (element != null) { + addToResourcesToParse(resourcesToParse, element, nature); + } +@@ -172,14 +171,18 @@ + + } + +- private void notifyVisitingWillStart(List visitors, IProgressMonitor monitor, boolean isFullBuild, IPythonNature nature) { +- for (PyDevBuilderVisitor visitor : visitors) { ++ private void notifyVisitingWillStart(List visitors, IProgressMonitor monitor, boolean isFullBuild, IPythonNature nature) { ++ for (Iterator iter = visitors.iterator(); iter.hasNext();) { ++ PyDevBuilderVisitor visitor = (PyDevBuilderVisitor) iter.next(); ++ + visitor.visitingWillStart(monitor, isFullBuild, nature); + } + } + +- private void notifyVisitingEnded(List visitors, IProgressMonitor monitor) { +- for (PyDevBuilderVisitor visitor : visitors) { ++ private void notifyVisitingEnded(List visitors, IProgressMonitor monitor) { ++ for (Iterator iter = visitors.iterator(); iter.hasNext();) { ++ PyDevBuilderVisitor visitor = (PyDevBuilderVisitor) iter.next(); ++ + visitor.visitingEnded(monitor); + } + } +@@ -192,7 +195,7 @@ + * @param member the resource we are adding + * @param nature the nature associated to the resource + */ +- private void addToResourcesToParse(List resourcesToParse, IFile member, IPythonNature nature) { ++ private void addToResourcesToParse(List resourcesToParse, IFile member, IPythonNature nature) { + //analyze it only if it is a valid source file + String fileExtension = member.getFileExtension(); + if(DEBUG){ +@@ -216,7 +219,7 @@ + * @param monitor + * @param visitors + */ +- public void buildResources(List resourcesToParse, IProgressMonitor monitor, List visitors) { ++ public void buildResources(List resourcesToParse, IProgressMonitor monitor, List visitors) { + + // we have 100 units here + double inc = (visitors.size() * 100) / (double) resourcesToParse.size(); +@@ -225,10 +228,10 @@ + int totalResources = resourcesToParse.size(); + int i = 0; + +- for (Iterator iter = resourcesToParse.iterator(); iter.hasNext() && monitor.isCanceled() == false;) { ++ for (Iterator iter = resourcesToParse.iterator(); iter.hasNext() && monitor.isCanceled() == false;) { + i += 1; + total += inc; +- IFile r = iter.next(); ++ IFile r = (IFile) iter.next(); + if(!PythonNature.isResourceInPythonpath(r)){ + continue; // we only analyze resources that are in the pythonpath + } +@@ -238,8 +241,8 @@ + } + IDocument doc = REF.getDocFromResource(r); + +- HashMap memo = new HashMap(); +- memo.put(PyDevBuilderVisitor.IS_FULL_BUILD, true); //mark it as full build ++ HashMap memo = new HashMap(); ++ memo.put(PyDevBuilderVisitor.IS_FULL_BUILD, new Boolean(true)); //mark it as full build + + if(doc != null){ //might be out of synch + for (Iterator it = visitors.iterator(); it.hasNext() && monitor.isCanceled() == false;) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/PyDevBuilderVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/PyDevBuilderVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/PyDevBuilderVisitor.java 2006-06-07 21:55:04.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/PyDevBuilderVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -32,7 +32,7 @@ + * + * @author Fabio Zadrozny + */ +-public abstract class PyDevBuilderVisitor implements Comparable{ ++public abstract class PyDevBuilderVisitor implements Comparable{ + + public static final int MAX_TO_VISIT_INFINITE = -1; + +@@ -67,9 +67,13 @@ + * Compares them by priority (they are ordered before visiting by priority, so, this can + * be useful if some visitor needs to run only after some other visitor was executed). + */ +- public int compareTo(PyDevBuilderVisitor o) { ++ public int compareTo(Object o) { + int priority = getPriority(); +- int otherPriority = o.getPriority(); ++ if (! (o instanceof PyDevBuilderVisitor)) ++ throw new ClassCastException(); ++ ++ PyDevBuilderVisitor v = (PyDevBuilderVisitor) o; ++ int otherPriority = v.getPriority(); + if(priority < otherPriority){ + return -1; + } +@@ -96,7 +100,7 @@ + * In this way, we can keep from having to recreate some info (such as the ast) each time over and over + * for each visitor. + */ +- public HashMap memo; ++ public HashMap memo; + + /** + * Constant indicating value in memory to represent a ful build. +@@ -226,12 +230,11 @@ + */ + protected IResource[] getInitDependents(IResource initResource){ + +- List toRet = new ArrayList(); ++ List toRet = new ArrayList(); + IContainer parent = initResource.getParent(); +- + try { + fillWithMembers(toRet, parent); +- return toRet.toArray(new IResource[0]); ++ return (IResource []) toRet.toArray(new IResource[0]); + } catch (CoreException e) { + //that's ok, it might not exist anymore + return new IResource[0]; +@@ -243,7 +246,7 @@ + * @param parent + * @throws CoreException + */ +- private void fillWithMembers(List toRet, IContainer parent) throws CoreException { ++ private void fillWithMembers(List toRet, IContainer parent) throws CoreException { + IResource[] resources = parent.members(); + + for (int i = 0; i < resources.length; i++) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/PydevGrouperVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/PydevGrouperVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/PydevGrouperVisitor.java 2006-05-04 14:23:38.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/PydevGrouperVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -5,6 +5,7 @@ + + import java.util.ArrayList; + import java.util.HashMap; ++import java.util.Iterator; + import java.util.List; + + import org.eclipse.core.resources.IResource; +@@ -21,15 +22,18 @@ + */ + public class PydevGrouperVisitor extends PydevInternalResourceDeltaVisitor { + +- private List visitors; ++ private List visitors; + +- public PydevGrouperVisitor(List _visitors, IProgressMonitor monitor, int totalResources) { ++ public PydevGrouperVisitor(List _visitors, IProgressMonitor monitor, int totalResources) { + super(monitor, totalResources); + //make a copy - should be already sorted at this point +- this.visitors = new ArrayList(_visitors); ++ this.visitors = new ArrayList(_visitors); + } +- +- /** ++ ++ ++ ++ ++ /** + * @param name determines the name of the method to visit (added removed or changed) + * @param isAddOrChange true if it is an add or change + * @param resource the resource to visit +@@ -43,17 +47,20 @@ + if(!PythonNature.isResourceInPythonpath(resource)){ + return; // we only analyze resources that are in the pythonpath + } +- HashMap memo = new HashMap(); +- memo.put(PyDevBuilderVisitor.IS_FULL_BUILD, false); //mark it as a delta build ++ HashMap memo = new HashMap(); ++ memo.put(PyDevBuilderVisitor.IS_FULL_BUILD, new Boolean(false)); //mark it as a delta build + +- for (PyDevBuilderVisitor visitor : visitors) { ++ for (Iterator iter = visitors.iterator(); iter.hasNext();) { ++ PyDevBuilderVisitor visitor = (PyDevBuilderVisitor) iter.next(); ++ + // some visitors cannot visit too many elements because they do a lot of processing + if (visitor.maxResourcesToVisit() == PyDevBuilderVisitor.MAX_TO_VISIT_INFINITE || visitor.maxResourcesToVisit() >= totalResources) { + visitor.memo = memo; //setting the memo must be the first thing. + try { + //communicate progress for each visitor + PyDevBuilder.communicateProgress(monitor, totalResources, currentResourcesVisited, resource, visitor); +- REF.invoke(visitor, name, resource, document, monitor); ++ REF.invoke(visitor, name, new Object[]{ ++ resource, document, monitor}); + + //ok, standard visiting ended... now, we have to check if we should visit the other + //resources if it was an __init__.py file that changed +@@ -61,7 +68,10 @@ + IResource[] initDependents = getInitDependents(resource); + + for (int i = 0; i < initDependents.length; i++) { +- REF.invoke(visitor, name, initDependents[i], REF.getDocFromResource(initDependents[i]), monitor); ++ REF.invoke(visitor, name, new Object[] { ++ initDependents[i], ++ REF.getDocFromResource(initDependents[i]), ++ monitor}); + } + } + } catch (Exception e) { +@@ -72,19 +82,17 @@ + + } + +- @Override + public void visitAddedResource(IResource resource, IDocument document, IProgressMonitor monitor) { + visitWith("visitAddedResource", true, resource, document, monitor); + } + +- @Override + public void visitChangedResource(IResource resource, IDocument document, IProgressMonitor monitor) { + visitWith("visitChangedResource", true, resource, document, monitor); + } + +- @Override + public void visitRemovedResource(IResource resource, IDocument document, IProgressMonitor monitor) { + visitWith("visitRemovedResource", false, resource, document, monitor); + } + ++ + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/PydevMarkerUtils.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/PydevMarkerUtils.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/PydevMarkerUtils.java 2006-06-05 15:56:32.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/PydevMarkerUtils.java 2006-11-05 20:59:42.000000000 +0100 +@@ -3,8 +3,10 @@ + */ + package org.python.pydev.builder; + ++import java.awt.Image; + import java.util.ArrayList; + import java.util.HashMap; ++import java.util.Iterator; + import java.util.List; + import java.util.Map; + +@@ -25,11 +27,13 @@ + /** + * Checks pre-existance of marker. + */ +- public static IMarker markerExists(IResource resource, String message, int charStart, int charEnd, String type, List existingMarkers) { ++ public static IMarker markerExists(IResource resource, String message, int charStart, int charEnd, String type, List existingMarkers) { + existingMarkers = checkExistingMarkers(resource, type, existingMarkers); + + try { +- for (IMarker task : existingMarkers) { ++ for (Iterator iter = existingMarkers.iterator(); iter.hasNext();) { ++ IMarker task = (IMarker) iter.next(); ++ + Object msg = task.getAttribute(IMarker.MESSAGE); + Object start = task.getAttribute(IMarker.CHAR_START); + Object end = task.getAttribute(IMarker.CHAR_END); +@@ -39,8 +43,8 @@ + return null; + } + boolean eqMessage = msg.equals(message); +- boolean eqCharStart = (Integer) start == charStart; +- boolean eqCharEnd = (Integer) end == charEnd; ++ boolean eqCharStart = ((Integer) start).intValue() == charStart; ++ boolean eqCharEnd = ((Integer) end).intValue() == charEnd; + + if (eqMessage && eqCharStart && eqCharEnd) { + return task; +@@ -64,12 +68,13 @@ + * @param lineNumber line number where marker should exist + * @return pre-existance of marker + */ +- public static IMarker markerExists(IResource resource, String message, int lineNumber, String type, List existingMarkers) { ++ public static IMarker markerExists(IResource resource, String message, int lineNumber, String type, List existingMarkers) { + existingMarkers = checkExistingMarkers(resource, type, existingMarkers); + + try { +- for (IMarker task : existingMarkers) { +- boolean eqLineNumber = (Integer)task.getAttribute(IMarker.LINE_NUMBER) == lineNumber; ++ for (Iterator iter = existingMarkers.iterator(); iter.hasNext();) { ++ IMarker task = (IMarker) iter.next(); ++ boolean eqLineNumber = ((Integer)task.getAttribute(IMarker.LINE_NUMBER)).intValue() == lineNumber; + boolean eqMessage = task.getAttribute(IMarker.MESSAGE).equals(message); + if (eqLineNumber && eqMessage){ + return task; +@@ -90,13 +95,13 @@ + + public static IMarker createMarker(IResource resource, IDocument doc, String message, + int lineStart, int colStart, int lineEnd, int colEnd, +- String markerType, int severity, Map additionalInfo) { ++ String markerType, int severity, Map additionalInfo) { + return createMarker(resource, doc, message, lineStart, colStart, lineEnd, colEnd, markerType, severity, additionalInfo, null); + } + + public static IMarker createMarker(IResource resource, IDocument doc, String message, + int lineStart, int colStart, int lineEnd, int colEnd, +- String markerType, int severity, Map additionalInfo, List existingMarkers) { ++ String markerType, int severity, Map additionalInfo, List existingMarkers) { + synchronized (resource) { + + existingMarkers = checkExistingMarkers(resource, markerType, existingMarkers); +@@ -140,7 +145,7 @@ + try { + + +- HashMap map = new HashMap(); ++ HashMap map = new HashMap(); + map.put(IMarker.MESSAGE, message); + map.put(IMarker.LINE_NUMBER, new Integer(lineStart)); + map.put(IMarker.CHAR_START, new Integer(startAbsolute)); +@@ -149,7 +154,10 @@ + + //add the additional info + if(additionalInfo != null){ +- for (Map.Entry entry : additionalInfo.entrySet()) { ++ for (Iterator iter = additionalInfo.entrySet().iterator(); iter ++ .hasNext();) { ++ Map.Entry entry = (Map.Entry) iter.next(); ++ + map.put(entry.getKey(), entry.getValue()); + } + } +@@ -162,12 +170,12 @@ + //to check if it exists, we don't check all attributes, so, let's update those that we don't check (if needed). + try { + final Object lN = marker.getAttribute(IMarker.LINE_NUMBER); +- if(lN == null || ((Integer)lN) != lineStart){ ++ if(lN == null || ((Integer)lN).intValue() != lineStart){ + marker.setAttribute(IMarker.LINE_NUMBER, new Integer(lineStart)); + } + + final Object mS = marker.getAttribute(IMarker.SEVERITY); +- if(mS == null || ((Integer)mS) != severity){ ++ if(mS == null || ((Integer)mS).intValue() != severity){ + marker.setAttribute(IMarker.SEVERITY, new Integer(severity)); + } + +@@ -185,17 +193,19 @@ + * @param existingMarkers + * @return + */ +- private static List checkExistingMarkers(IResource resource, String markerType, List existingMarkers) { ++ private static List checkExistingMarkers(IResource resource, String markerType, List existingMarkers) { + synchronized (resource) { + if(existingMarkers == null){ + try { +- existingMarkers = new ArrayList(); ++ existingMarkers = new ArrayList(); + IMarker[] markers = resource.findMarkers(markerType, true, IResource.DEPTH_ZERO); +- for (IMarker marker : markers) { ++ for (int i = 0; i < markers.length; i++) { ++ IMarker marker = markers[i]; ++ + existingMarkers.add(marker); + } + } catch (CoreException e) { +- existingMarkers = new ArrayList(); ++ existingMarkers = new ArrayList(); + PydevPlugin.log(e); + } + } +@@ -205,9 +215,9 @@ + + + +- public static IMarker createMarker(IResource resource, IDocument doc, String message, int lineNumber, String markerType, int severity, boolean userEditable, boolean istransient, List existingMarkers) { ++ public static IMarker createMarker(IResource resource, IDocument doc, String message, int lineNumber, String markerType, int severity, boolean userEditable, boolean istransient, List existingMarkers) { + synchronized (resource) { +- HashMap map = new HashMap(); ++ HashMap map = new HashMap(); + map.put(IMarker.USER_EDITABLE, new Boolean(userEditable)); + map.put(IMarker.TRANSIENT, new Boolean(istransient)); + return createMarker(resource, doc, message, lineNumber, 0, lineNumber, 0, markerType, severity, map, existingMarkers); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pylint/PyLintPrefInitializer.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pylint/PyLintPrefInitializer.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pylint/PyLintPrefInitializer.java 2006-01-31 14:04:39.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pylint/PyLintPrefInitializer.java 2006-11-05 20:59:42.000000000 +0100 +@@ -10,7 +10,6 @@ + + public class PyLintPrefInitializer extends AbstractPreferenceInitializer{ + +- @Override + public void initializeDefaultPreferences() { + Preferences node = new DefaultScope().getNode(PydevPlugin.DEFAULT_PYDEV_SCOPE); + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pylint/PyLintVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pylint/PyLintVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/builder/pylint/PyLintVisitor.java 2006-06-12 16:07:49.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/builder/pylint/PyLintVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -184,7 +184,7 @@ + File script = new File(PyLintPrefPage.getPyLintLocation()); + File arg = new File(location.toOSString()); + +- ArrayList list = new ArrayList(); ++ ArrayList list = new ArrayList(); + list.add("--include-ids=y"); + + //user args +@@ -199,15 +199,15 @@ + IProject project = resource.getProject(); + + String scriptToExe = REF.getFileAbsolutePath(script); +- String[] paramsToExe = list.toArray(new String[0]); ++ String[] paramsToExe = (String []) list.toArray(new String[0]); + String cmdLineToExe = SimplePythonRunner.makeExecutableCommandStr(scriptToExe, paramsToExe); + write("Pylint: Executing command line:'"+cmdLineToExe+"'", out); + +- Tuple outTup = new SimplePythonRunner().runAndGetOutput(cmdLineToExe, script.getParentFile(), project); ++ Tuple outTup = new SimplePythonRunner().runAndGetOutput(cmdLineToExe, script.getParentFile(), project); + write("Pylint: The stdout of the command line is: "+outTup.o1, out); + write("Pylint: The stderr of the command line is: "+outTup.o2, out); + +- String output = outTup.o1; ++ String output = (String) outTup.o1; + + StringTokenizer tokenizer = new StringTokenizer(output, "\r\n"); + +@@ -222,7 +222,7 @@ + PydevPlugin.log(new RuntimeException("PyLint ERROR: \n"+output)); + return; + } +- if(outTup.o2.indexOf("Traceback (most recent call last):") != -1){ ++ if(((String)outTup.o2).indexOf("Traceback (most recent call last):") != -1){ + PydevPlugin.log(new RuntimeException("PyLint ERROR: \n"+outTup.o2)); + return; + } +@@ -377,4 +377,6 @@ + } + return i; + } ++ ++ + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyBackspace.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyBackspace.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyBackspace.java 2006-04-29 20:43:01.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyBackspace.java 2006-11-05 20:59:42.000000000 +0100 +@@ -292,13 +292,13 @@ + forceTabs == null|| + tabWidth != PydevPrefs.getPreferences().getInt(PydevPrefs.TAB_WIDTH) || + useSpaces != PydevPrefs.getPreferences().getBoolean(PydevPrefs.SUBSTITUTE_TABS) || +- forceTabs != pyEdit.getIndentPrefs().getForceTabs()) { ++ forceTabs.booleanValue() != pyEdit.getIndentPrefs().getForceTabs()) { + + tabWidth = PydevPrefs.getPreferences().getInt(PydevPrefs.TAB_WIDTH); + useSpaces = PydevPrefs.getPreferences().getBoolean(PydevPrefs.SUBSTITUTE_TABS); +- forceTabs = pyEdit.getIndentPrefs().getForceTabs(); ++ forceTabs = new Boolean(pyEdit.getIndentPrefs().getForceTabs()); + +- if (useSpaces && !forceTabs){ ++ if (useSpaces && !forceTabs.booleanValue()){ + identString = createSpaceString(tabWidth); + }else{ + identString = "\t"; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyComment.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyComment.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyComment.java 2006-08-23 00:07:08.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyComment.java 2006-11-05 20:59:42.000000000 +0100 +@@ -6,6 +6,7 @@ + + package org.python.pydev.editor.actions; + ++import java.util.Iterator; + import java.util.List; + + import org.eclipse.jface.action.IAction; +@@ -30,10 +31,10 @@ + // Select from text editor + PySelection ps = new PySelection(getTextEditor()); + // Perform the action +- Tuple repRegion = perform(ps); ++ Tuple repRegion = perform(ps); + + // Put cursor at the first area of the selection +- getTextEditor().selectAndReveal(repRegion.o1, repRegion.o2); ++ getTextEditor().selectAndReveal(((Integer) repRegion.o1).intValue(), ((Integer) repRegion.o2).intValue()); + } catch (Exception e) { + beep(e); + } +@@ -46,7 +47,7 @@ + * @return the new selection + * @throws BadLocationException + */ +- public Tuple perform(PySelection ps) throws BadLocationException { ++ public Tuple perform(PySelection ps) throws BadLocationException { + // What we'll be replacing the selected text with + StringBuffer strbuf = new StringBuffer(); + +@@ -54,9 +55,10 @@ + ps.selectCompleteLine(); + + String selectedText = ps.getSelectedText(); +- List ret = StringUtils.splitInLines(selectedText); ++ List ret = StringUtils.splitInLines(selectedText); + +- for(String line: ret){ ++ for (Iterator i = ret.iterator(); i.hasNext(); ) { ++ String line = (String) i.next(); + strbuf.append('#'); + strbuf.append(line); + } +@@ -68,6 +70,6 @@ + String replacement = strbuf.toString(); + // Replace the text with the modified information + ps.getDoc().replace(start, len, replacement); +- return new Tuple(start, replacement.length()); ++ return new Tuple(new Integer(start), new Integer(replacement.length())); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyGoToDefinition.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyGoToDefinition.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyGoToDefinition.java 2006-04-17 20:59:31.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyGoToDefinition.java 2006-11-05 20:59:42.000000000 +0100 +@@ -75,16 +75,17 @@ + final PyEdit pyEdit = getPyEdit(); + if(areRefactorPreconditionsOK(getRefactoringRequest())){ + +- HashSet set = new HashSet(); ++ HashSet set = new HashSet(); + ItemPointer[] defs = findDefinition(pyEdit); + if(defs == null){ + shell.getDisplay().beep(); + return; + } +- for (ItemPointer pointer : defs) { ++ for (int i = 0; i < defs.length; i++) { ++ ItemPointer pointer = defs[i]; + set.add(pointer); + } +- final ItemPointer[] where = set.toArray(new ItemPointer[0]); ++ final ItemPointer[] where = (ItemPointer[]) set.toArray(new ItemPointer[0]); + + if (where == null) { + shell.getDisplay().beep(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyNextMethod.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyNextMethod.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyNextMethod.java 2006-06-21 19:31:48.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyNextMethod.java 2006-11-05 20:59:42.000000000 +0100 +@@ -23,9 +23,9 @@ + */ + public ASTEntry getSelect(SimpleNode ast, int line) { + EasyASTIteratorVisitor visitor = EasyASTIteratorVisitor.create(ast); +- Iterator classesAndMethodsIterator = visitor.getClassesAndMethodsIterator(); ++ Iterator classesAndMethodsIterator = visitor.getClassesAndMethodsIterator(); + while(classesAndMethodsIterator.hasNext()){ +- ASTEntry entry = classesAndMethodsIterator.next(); ++ ASTEntry entry = (ASTEntry) classesAndMethodsIterator.next(); + SimpleNode nameNode = getNameNode(entry); + if(nameNode.beginLine-1 > line ){ + return entry; +@@ -34,12 +34,10 @@ + return null; + } + +- @Override + protected boolean goToEndOfFile() { + return true; + } + +- @Override + protected boolean goToStartOfFile() { + return false; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyOrganizeImports.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyOrganizeImports.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyOrganizeImports.java 2006-05-20 19:47:31.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyOrganizeImports.java 2006-11-05 20:59:42.000000000 +0100 +@@ -32,7 +32,6 @@ + /** + * @see org.eclipse.ui.IActionDelegate#run(org.eclipse.jface.action.IAction) + */ +- @SuppressWarnings("unchecked") + public void run(IAction action) { + try + { +@@ -44,10 +43,10 @@ + try { + if (ps.getStartLineIndex() == ps.getEndLineIndex()) { + //let's see if someone wants to make a better implementation in another plugin... +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_ORGANIZE_IMPORTS); ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_ORGANIZE_IMPORTS); + if (participants.size() == 1) { + PyEdit pyEdit = getPyEdit(); +- participants.get(0).performArrangeImports(ps, pyEdit); ++ ((IOrganizeImports)participants.get(0)).performArrangeImports(ps, pyEdit); + } else { + if (participants.size() > 1) { + //let's issue a warning... this extension can only have 1 plugin implementing it +@@ -90,27 +89,26 @@ + * @param doc + * @param endLineDelim + */ +- @SuppressWarnings("unchecked") + public static void performArrangeImports(IDocument doc, String endLineDelim){ + ArrayList list = new ArrayList(); + + int firstImport = -1; + PyDocIterator it = new PyDocIterator(doc, false); + while(it.hasNext()){ +- String str = it.next(); ++ String str = (String) it.next(); + + if((str.startsWith("import ") || str.startsWith("from "))){ + int iToAdd = it.getLastReturnedLine(); + if(str.indexOf('(') != -1){ //we have something like from os import (pipe,\nfoo) + while(it.hasNext() && str.indexOf(')') == -1){ +- String str1 = it.next(); ++ String str1 = (String) it.next(); + str += endLineDelim+str1; + } + } + if(WordUtils.endsWith(str, '\\')){ + while(it.hasNext() && WordUtils.endsWith(str, '\\')){ + //we have to get all until there are no more back-slashes +- String str1 = it.next(); ++ String str1 = (String) it.next(); + str += endLineDelim+str1; + } + } +@@ -178,7 +176,6 @@ + * @param startLine + * @param endLine + */ +- @SuppressWarnings("unchecked") + public static void performSimpleSort(IDocument doc, String endLineDelim, int startLine, int endLine) { + try { + ArrayList list = new ArrayList(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyPreviousMethod.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyPreviousMethod.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyPreviousMethod.java 2006-06-21 19:31:48.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyPreviousMethod.java 2006-11-05 20:59:42.000000000 +0100 +@@ -21,11 +21,11 @@ + // me is the last node w + public ASTEntry getSelect(SimpleNode ast, int line) { + EasyASTIteratorVisitor visitor = EasyASTIteratorVisitor.create(ast); +- Iterator classesAndMethodsIterator = visitor.getClassesAndMethodsIterator(); ++ Iterator classesAndMethodsIterator = visitor.getClassesAndMethodsIterator(); + ASTEntry last = null; + + while(classesAndMethodsIterator.hasNext()){ +- ASTEntry entry = classesAndMethodsIterator.next(); ++ ASTEntry entry = (ASTEntry) classesAndMethodsIterator.next(); + SimpleNode nameNode = getNameNode(entry); + if(nameNode.beginLine-1 < line ){ + last = entry; +@@ -34,12 +34,10 @@ + return last; + } + +- @Override + protected boolean goToEndOfFile() { + return false; + } + +- @Override + protected boolean goToStartOfFile() { + return true; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PySelectWord.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PySelectWord.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PySelectWord.java 2006-06-01 19:45:01.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PySelectWord.java 2006-11-05 20:59:42.000000000 +0100 +@@ -12,11 +12,11 @@ + PyEdit pyEdit = getPyEdit(); + PySelection ps = new PySelection(pyEdit); + try { +- Tuple currToken = ps.getCurrToken(); ++ Tuple currToken = ps.getCurrToken(); + if(currToken.o1 != null){ +- int len = currToken.o1.length(); ++ int len = ((String) currToken.o1).length(); + if(len > 0){ +- pyEdit.selectAndReveal(currToken.o2, len); ++ pyEdit.selectAndReveal(((Integer)currToken.o2).intValue(), len); + } + } + } catch (Exception e) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyShowBrowser.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyShowBrowser.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyShowBrowser.java 2006-02-21 20:27:37.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyShowBrowser.java 2006-11-05 20:59:42.000000000 +0100 +@@ -7,7 +7,6 @@ + */ + public class PyShowBrowser extends PyShowOutline{ + +- @Override + protected String getExtensionName() { + return ExtensionHelper.PYDEV_GLOBALS_BROWSER; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyShowOutline.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyShowOutline.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyShowOutline.java 2006-02-21 20:27:37.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyShowOutline.java 2006-11-05 20:59:42.000000000 +0100 +@@ -35,7 +35,6 @@ + } + } + +- @Override + public void selectionChanged(IAction action, ISelection selection) { + IEditorActionDelegate participant = getParticipant(); + if(participant != null){ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyUncomment.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyUncomment.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/PyUncomment.java 2006-08-23 00:07:08.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/PyUncomment.java 2006-11-05 20:59:42.000000000 +0100 +@@ -25,7 +25,7 @@ + * @return the new selection + * @throws BadLocationException + */ +- public Tuple perform(PySelection ps) throws BadLocationException { ++ public Tuple perform(PySelection ps) throws BadLocationException { + // What we'll be replacing the selected text with + StringBuffer strbuf = new StringBuffer(); + +@@ -47,7 +47,7 @@ + String replacement = strbuf.toString(); + // Replace the text with the modified information + ps.getDoc().replace(start, ps.getSelLength(), replacement); +- return new Tuple(start, replacement.length()); ++ return new Tuple(new Integer(start), new Integer(replacement.length())); + } + + /** +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/refactoring/PyRefactorAction.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/refactoring/PyRefactorAction.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/actions/refactoring/PyRefactorAction.java 2006-06-10 01:44:41.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/actions/refactoring/PyRefactorAction.java 2006-11-05 20:59:42.000000000 +0100 +@@ -110,7 +110,7 @@ + IPyRefactoring pyRefactoring = AbstractPyRefactoring.getPyRefactoring(); + //check if it is able to do the method by checking its pre-condition + try { +- if ((Boolean) REF.invoke(pyRefactoring, conditionalMethod, new Object[0])) { ++ if (((Boolean) REF.invoke(pyRefactoring, conditionalMethod, new Object[0])).booleanValue()) { + return pyRefactoring; + } + } catch (Exception e) { +@@ -251,7 +251,6 @@ + //pyrefactoring instance in the perform action + new Job("Performing: "+action.getClass().getName()){ + +- @Override + protected IStatus run(IProgressMonitor monitor) { + try{ + Operation o = new Operation(null, action); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/autoedit/PyAutoIndentStrategy.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/autoedit/PyAutoIndentStrategy.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/autoedit/PyAutoIndentStrategy.java 2006-09-18 01:25:49.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/autoedit/PyAutoIndentStrategy.java 2006-11-05 20:59:42.000000000 +0100 +@@ -51,7 +51,7 @@ + /** + * Set indentation automatically after newline. + */ +- private Tuple autoIndentNewline(IDocument document, int length, String text, int offset) ++ private Tuple autoIndentNewline(IDocument document, int length, String text, int offset) + throws BadLocationException { + + if (offset > 0) { +@@ -59,9 +59,9 @@ + + String lineWithoutComments = selection.getLineContentsToCursor(true, true); + +- Tuple tup = determineSmartIndent(document, offset, selection); +- int smartIndent = tup.o1; +- boolean isInsidePar = tup.o2; ++ Tuple tup = determineSmartIndent(document, offset, selection); ++ int smartIndent = ((Integer)tup.o1).intValue(); ++ boolean isInsidePar = ((Boolean)tup.o2).booleanValue(); + + if(lineWithoutComments.length() > 0){ + //ok, now let's see the auto-indent +@@ -90,25 +90,25 @@ + int first = PySelection.getFirstCharPosition(openingBracketLineStr); + String initial = getCharsBeforeNewLine(text); + text = initial + openingBracketLineStr.substring(0, first); +- return new Tuple(text, isInsidePar); ++ return new Tuple(text, new Boolean(isInsidePar)); + } + } + } else if (smartIndent == -1 && lastChar == ':') { + //we have to check if smartIndent is -1 because otherwise we are in a dict + //ok, not inside brackets + text = indentBasedOnStartingScope(text, selection, false); +- return new Tuple(text, isInsidePar); ++ return new Tuple(text, new Boolean(isInsidePar)); + } + } + + String trimmedLine = lineWithoutComments.trim(); + + if(smartIndent >= 0 && (DocUtils.hasOpeningBracket(trimmedLine) || DocUtils.hasClosingBracket(trimmedLine))){ +- return new Tuple(makeSmartIndent(text, smartIndent), isInsidePar); ++ return new Tuple(makeSmartIndent(text, smartIndent), new Boolean(isInsidePar)); + } + //let's check for dedents... + if(PySelection.startsWithDedentToken(trimmedLine)){ +- return new Tuple(dedent(text),isInsidePar); ++ return new Tuple(dedent(text),new Boolean(isInsidePar)); + } + + boolean indentBasedOnStartingScope = false; +@@ -122,27 +122,27 @@ + } + + if(indentBasedOnStartingScope && selection.getLineContentsToCursor().trim().length() == 0){ +- return new Tuple(indentBasedOnStartingScope(text, selection, true), isInsidePar); ++ return new Tuple(indentBasedOnStartingScope(text, selection, true), new Boolean(isInsidePar)); + } + + } +- return new Tuple(text, false); ++ return new Tuple(text, new Boolean(false)); + } + + /** + * @return the text for the indent + */ + private String indentBasedOnStartingScope(String text, PySelection selection, boolean checkForLowestBeforeNewScope) { +- Tuple3 previousIfLine = selection.getPreviousLineThatStartsScope(); ++ Tuple3 previousIfLine = selection.getPreviousLineThatStartsScope(); + if(previousIfLine != null){ + String initial = getCharsBeforeNewLine(text); + + if(previousIfLine.o2 == null){ //no dedent was found +- String indent = PySelection.getIndentationFromLine(previousIfLine.o1); ++ String indent = PySelection.getIndentationFromLine((String) previousIfLine.o1); + + if(checkForLowestBeforeNewScope && previousIfLine.o3 != null){ + +- indent = PySelection.getIndentationFromLine(previousIfLine.o3); ++ indent = PySelection.getIndentationFromLine((String) previousIfLine.o3); + text = initial + indent; + + }else{ +@@ -152,7 +152,7 @@ + } + + }else{ //some dedent was found +- String indent = PySelection.getIndentationFromLine(previousIfLine.o2); ++ String indent = PySelection.getIndentationFromLine((String) previousIfLine.o2); + String indentationString = prefs.getIndentationString(); + + final int i = indent.length() - indentationString.length(); +@@ -267,12 +267,12 @@ + } + return text; + } +- private Tuple removeFirstIndent(String text) { ++ private Tuple removeFirstIndent(String text) { + String indentationString = prefs.getIndentationString(); + if(text.startsWith(indentationString)){ +- return new Tuple(text.substring(indentationString.length()), indentationString.length()); ++ return new Tuple(text.substring(indentationString.length()), new Integer(indentationString.length())); + } +- return new Tuple(text, 0); ++ return new Tuple(text, new Integer(0)); + } + + /** +@@ -304,7 +304,7 @@ + if(prefs.getSmartIndentPar()){ + PySelection selection = new PySelection(document, command.offset); + if(selection.getCursorLineContents().trim().length() > 0){ +- command.text = autoIndentNewline(document, command.length, command.text, command.offset).o1; ++ command.text = (String) autoIndentNewline(document, command.length, command.text, command.offset).o1; + if(PySelection.containsOnlyWhitespaces(selection.getLineContentsToCursor())){ + command.caretOffset = command.offset + selection.countSpacesAfter(command.offset); + } +@@ -328,8 +328,8 @@ + int prevLineEndOffset = prevLineInfo.getOffset()+prevLineInfo.getLength(); + String prevExpectedIndent = autoIndentSameAsPrevious(document, prevLineEndOffset, "\n", false); + String txt = prevExpectedIndent; +- Tuple prevLineTup = autoIndentNewline(document, 0, txt, prevLineEndOffset); +- txt = prevLineTup.o1; ++ Tuple prevLineTup = autoIndentNewline(document, 0, txt, prevLineEndOffset); ++ txt = (String) prevLineTup.o1; + txt = txt.substring(1);//remove the newline + prevExpectedIndent = prevExpectedIndent.substring(1); + +@@ -343,7 +343,7 @@ + if(currSize >= sizeExpected){ + //do nothing (we already passed what we expected from the indentation) + int len = sizeApplied-sizeExpected; +- if(prevLineTup.o2){ ++ if(((Boolean)prevLineTup.o2).booleanValue()){ + if(prevExpectedIndent.length() > len){ + command.text = prevExpectedIndent.substring(len); + } +@@ -502,7 +502,7 @@ + * @return the new indent and the number of chars it has been dedented (so, that has to be considered as a shift to the left + * on subsequent things). + */ +- public Tuple autoDedentElse(IDocument document, DocumentCommand command, String tok) throws BadLocationException { ++ public Tuple autoDedentElse(IDocument document, DocumentCommand command, String tok) throws BadLocationException { + if(getIndentPrefs().getAutoDedentElse()){ + PySelection ps = new PySelection(document, command.offset); + String lineContents = ps.getCursorLineContents(); +@@ -515,9 +515,9 @@ + + String indent = prefs.getIndentationString(); + if(lineIndent.length() == ifIndent.length()+indent.length()){ +- Tuple dedented = removeFirstIndent(lineContents); +- ps.replaceLineContentsToSelection(dedented.o1); +- command.offset = command.offset - dedented.o2; ++ Tuple dedented = removeFirstIndent(lineContents); ++ ps.replaceLineContentsToSelection((String) dedented.o1); ++ command.offset = command.offset - ((Integer)dedented.o2).intValue(); + return dedented; + } + } +@@ -526,7 +526,7 @@ + return null; + } + +- public Tuple autoDedentElse(IDocument document, DocumentCommand command) throws BadLocationException { ++ public Tuple autoDedentElse(IDocument document, DocumentCommand command) throws BadLocationException { + return autoDedentElse(document, command, "else"); + } + +@@ -535,7 +535,7 @@ + * @return the new indent and the number of chars it has been dedented (so, that has to be considered as a shift to the left + * on subsequent things). + */ +- public Tuple autoDedentElif(IDocument document, DocumentCommand command) throws BadLocationException { ++ public Tuple autoDedentElif(IDocument document, DocumentCommand command) throws BadLocationException { + return autoDedentElse(document, command, "elif"); + } + +@@ -715,20 +715,20 @@ + * @return indent, or -1 if smart indent could not be determined (fall back to default) + * and a boolean indicating if we're inside a parenthesis + */ +- private Tuple determineSmartIndent(IDocument document, int offset, PySelection ps) ++ private Tuple determineSmartIndent(IDocument document, int offset, PySelection ps) + throws BadLocationException { + + PythonPairMatcher matcher = new PythonPairMatcher(DocUtils.BRACKETS); + int openingPeerOffset = matcher.searchForAnyOpeningPeer(offset, document); + if(openingPeerOffset == -1){ +- return new Tuple(-1, false); ++ return new Tuple(new Integer(-1), new Boolean(false)); + } + + //ok, now, if the opening peer is not on the line we're currently, we do not want to make + //an 'auto-indent', but keep the current indentation level + final IRegion lineInformationOfOffset = document.getLineInformationOfOffset(openingPeerOffset); + if(!PySelection.isInside(offset, lineInformationOfOffset)){ +- return new Tuple(-1, true); ++ return new Tuple(new Integer(-1), new Boolean(true)); + } + + int len = -1; +@@ -771,7 +771,7 @@ + len += prefs.getTabWidth() - 1; + } + } +- return new Tuple(len, true); ++ return new Tuple(new Integer(len), new Boolean(true)); + + } + } +\ No newline at end of file +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/CompletionRequest.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/CompletionRequest.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/CompletionRequest.java 2006-07-15 19:02:18.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/CompletionRequest.java 2006-11-05 20:59:42.000000000 +0100 +@@ -114,7 +114,6 @@ + */ + public boolean alreadyHasParams; + +- @Override + public String toString() { + StringBuffer buffer = new StringBuffer(); + buffer.append("CompletionRequest["); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletionInitializer.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletionInitializer.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletionInitializer.java 2006-09-26 02:46:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletionInitializer.java 2006-11-05 20:59:42.000000000 +0100 +@@ -10,7 +10,6 @@ + + public class PyCodeCompletionInitializer extends AbstractPreferenceInitializer{ + +- @Override + public void initializeDefaultPreferences() { + Preferences node = new DefaultScope().getNode(PydevPlugin.DEFAULT_PYDEV_SCOPE); + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletion.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletion.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletion.java 2006-09-26 02:46:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletion.java 2006-11-05 20:59:42.000000000 +0100 +@@ -174,7 +174,6 @@ + * (This is where we do the "REAL" work). + * @throws BadLocationException + */ +- @SuppressWarnings("unchecked") + public List getCodeCompletionProposals(ITextViewer viewer, CompletionRequest request) throws CoreException, BadLocationException { + if(DEBUG_CODE_COMPLETION){ + Log.toLogFile(this,"Starting getCodeCompletionProposals"); +@@ -270,7 +269,7 @@ + theList.addAll(getGlobalsFromParticipants(request, state)); + } + +- Set alreadyChecked = new HashSet(); ++ Set alreadyChecked = new HashSet(); + + for(ListIterator it=theList.listIterator(); it.hasNext();){ + Object o = it.next(); +@@ -308,7 +307,6 @@ + return ret; + } + +- @SuppressWarnings("unchecked") + private Collection getGlobalsFromParticipants(CompletionRequest request, ICompletionState state) { + ArrayList ret = new ArrayList(); + +@@ -344,7 +342,7 @@ + */ + public static IToken[] getSelfCompletions(CompletionRequest request, List theList, CompletionState state, boolean getOnlySupers) { + IToken[] comps = new IToken[0]; +- SimpleNode s = PyParser.reparseDocument(new PyParser.ParserInfo(request.doc, true, request.nature, state.line)).o1; ++ SimpleNode s = (SimpleNode) PyParser.reparseDocument(new PyParser.ParserInfo(request.doc, true, request.nature, state.line)).o1; + if(s != null){ + FindScopeVisitor visitor = new FindScopeVisitor(state.line, 0); + try { +@@ -360,7 +358,6 @@ + /** + * Get self completions when you already have a scope + */ +- @SuppressWarnings("unchecked") + public static IToken[] getSelfCompletions(LocalScope scope, CompletionRequest request, List theList, CompletionState state, boolean getOnlySupers) throws BadLocationException { + IToken[] comps = new IToken[0]; + while(scope.scope.size() > 0){ +@@ -421,7 +418,7 @@ + * tokens to actual completions as requested by the Eclipse infrastructure. + * @param lookingForInstance if looking for instance, we should not add the 'self' as parameter. + */ +- private void changeItokenToCompletionPropostal(ITextViewer viewer, CompletionRequest request, List convertedProposals, List iTokenList, boolean importsTip, boolean lookingForInstance) { ++ private void changeItokenToCompletionPropostal(ITextViewer viewer, CompletionRequest request, List convertedProposals, List iTokenList, boolean importsTip, boolean lookingForInstance) { + for (Iterator iter = iTokenList.iterator(); iter.hasNext();) { + + Object obj = iter.next(); +@@ -749,7 +746,6 @@ + * @param onlyForCalltips if we should filter having in mind that we're going to show it for a calltip + * @return the completions to show to the user + */ +- @SuppressWarnings("unchecked") + public ICompletionProposal[] onlyValidSorted(List pythonAndTemplateProposals, String qualifier, boolean onlyForCalltips) { + //FOURTH: Now, we have all the proposals, only thing is deciding wich ones are valid (depending on + //qualifier) and sorting them correctly. +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletionPreferencesPage.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletionPreferencesPage.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletionPreferencesPage.java 2006-09-25 02:03:07.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyCodeCompletionPreferencesPage.java 2006-11-05 20:59:42.000000000 +0100 +@@ -81,7 +81,6 @@ + + } + +- @Override + public boolean performOk() { + boolean ret = super.performOk(); + PyCodeCompletion.DEBUG_CODE_COMPLETION = isToDebugCodeCompletion(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyLinkedModeCompletionProposal.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyLinkedModeCompletionProposal.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyLinkedModeCompletionProposal.java 2006-07-17 04:29:15.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PyLinkedModeCompletionProposal.java 2006-11-05 20:59:42.000000000 +0100 +@@ -128,7 +128,7 @@ + } + + private void goToLinkedModeFromArgs(ITextViewer viewer, int offset, IDocument doc, int exitPos, int iPar, String newStr) throws BadLocationException { +- List offsetsAndLens = new ArrayList(); ++ List offsetsAndLens = new ArrayList(); + + StringBuffer buffer = new StringBuffer(); + for (int i = 0; i < newStr.length(); i++) { +@@ -136,40 +136,40 @@ + + if(Character.isJavaIdentifierPart(c)){ + if(buffer.length() == 0){ +- offsetsAndLens.add(i); ++ offsetsAndLens.add(new Integer(i)); + buffer.append(c); + }else{ + buffer.append(c); + } + }else{ + if(buffer.length() > 0){ +- offsetsAndLens.add(buffer.length()); ++ offsetsAndLens.add(new Integer(buffer.length())); + buffer = new StringBuffer(); + } + } + } + if(buffer.length() > 0){ +- offsetsAndLens.add(buffer.length()); ++ offsetsAndLens.add(new Integer(buffer.length())); + } + buffer = null; + + goToLinkedMode(viewer, offset, doc, exitPos, iPar, offsetsAndLens); + } + +- private void goToLinkedMode(ITextViewer viewer, int offset, IDocument doc, int exitPos, int iPar, List offsetsAndLens) throws BadLocationException { ++ private void goToLinkedMode(ITextViewer viewer, int offset, IDocument doc, int exitPos, int iPar, List offsetsAndLens) throws BadLocationException { + if(offsetsAndLens.size() > 0){ + LinkedModeModel model= new LinkedModeModel(); + + for (int i = 0; i < offsetsAndLens.size(); i++) { +- Integer offs = offsetsAndLens.get(i); ++ Integer offs = (Integer) offsetsAndLens.get(i); + i++; +- Integer len = offsetsAndLens.get(i); ++ Integer len = (Integer) offsetsAndLens.get(i); + if(i == 1){ +- firstParameterLen = len; ++ firstParameterLen = len.intValue(); + } +- int location = offset+iPar+offs+1; ++ int location = offset+iPar+offs.intValue()+1; + LinkedPositionGroup group= new LinkedPositionGroup(); +- ProposalPosition proposalPosition = new ProposalPosition(doc, location, len, 0 , new ICompletionProposal[0]); ++ ProposalPosition proposalPosition = new ProposalPosition(doc, location, len.intValue(), 0 , new ICompletionProposal[0]); + group.addPosition(proposalPosition); + model.addGroup(group); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PythonCompletionProcessor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PythonCompletionProcessor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PythonCompletionProcessor.java 2006-09-18 01:25:49.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PythonCompletionProcessor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -141,7 +141,6 @@ + * + * @see org.eclipse.jface.text.contentassist.IContentAssistProcessor#computeCompletionProposals(org.eclipse.jface.text.ITextViewer, int) + */ +- @SuppressWarnings("unchecked") + public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int documentOffset) { + updateStatus(); + ICompletionProposal[] proposals; +@@ -152,7 +151,7 @@ + + + //list for storing the proposals +- ArrayList pythonAndTemplateProposals = new ArrayList(); ++ ArrayList pythonAndTemplateProposals = new ArrayList(); + + CompletionRequest request = new CompletionRequest(edit.getEditorFile(), + edit.getPythonNature(), doc, documentOffset, codeCompletion); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PythonStringCompletionProcessor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PythonStringCompletionProcessor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/PythonStringCompletionProcessor.java 2006-07-16 15:51:10.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/PythonStringCompletionProcessor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -8,7 +8,6 @@ + super(edit, pyContentAssistant); + } + +- @Override + public char[] getCompletionProposalAutoActivationCharacters() { + //no auto-activation within strings. + return new char[]{}; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/AbstractASTManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/AbstractASTManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/AbstractASTManager.java 2006-09-24 03:03:16.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/AbstractASTManager.java 2006-11-05 20:59:42.000000000 +0100 +@@ -141,7 +141,7 @@ + } + + //set to hold the completion (no duplicates allowed). +- Set set = new HashSet(); ++ Set set = new HashSet(); + + String absoluteModule = original; + if (absoluteModule.endsWith(".")) { +@@ -167,15 +167,15 @@ + if(level == 1 && moduleName != null){ + //has returned itself, so, let's remove it + String strToRemove = FullRepIterable.getLastPart(moduleName); +- for(Iterator it=set.iterator();it.hasNext();){ +- IToken o = it.next(); ++ for(Iterator it=set.iterator();it.hasNext();){ ++ IToken o = (IToken) it.next(); + if(o.getRepresentation().equals(strToRemove)){ + it.remove(); + //don't break because the token might be different, but not the representation... + } + } + } +- return set.toArray(new IToken[0]); ++ return (IToken []) set.toArray(new IToken[0]); + } + + +@@ -184,11 +184,11 @@ + * @param moduleToGetTokensFrom the string that represents the token from where we are getting the imports + * @param set the set where the tokens should be added + */ +- protected void getAbsoluteImportTokens(String moduleToGetTokensFrom, Set set, int type, boolean onlyFilesOnSameLevel) { +- SortedMap modulesStartingWith = modulesManager.getAllModulesStartingWith(moduleToGetTokensFrom); +- Iterator itModules = modulesStartingWith.keySet().iterator(); ++ protected void getAbsoluteImportTokens(String moduleToGetTokensFrom, Set set, int type, boolean onlyFilesOnSameLevel) { ++ SortedMap modulesStartingWith = modulesManager.getAllModulesStartingWith(moduleToGetTokensFrom); ++ Iterator itModules = modulesStartingWith.keySet().iterator(); + while(itModules.hasNext()){ +- ModulesKey key = itModules.next(); ++ ModulesKey key = (ModulesKey) itModules.next(); + + String element = key.name; + // if (element.startsWith(moduleToGetTokensFrom)) { we don't check that anymore because we get all the modules starting with it already +@@ -237,15 +237,15 @@ + * @param moduleToGetTokensFrom + * @param set set where the tokens should be added + */ +- protected void getTokensForModule(String original, IPythonNature nature, String moduleToGetTokensFrom, Set set) { ++ protected void getTokensForModule(String original, IPythonNature nature, String moduleToGetTokensFrom, Set set) { + if (moduleToGetTokensFrom.length() > 0) { + if (original.endsWith(".")) { + original = original.substring(0, original.length() - 1); + } + +- Tuple modTok = findModuleFromPath(original, nature, false, null); //the current module name is not used as it is not relative +- IModule m = modTok.o1; +- String tok = modTok.o2; ++ Tuple modTok = findModuleFromPath(original, nature, false, null); //the current module name is not used as it is not relative ++ IModule m = (IModule) modTok.o1; ++ String tok = (String) modTok.o2; + + if(m == null){ + //we were unable to find it with the given path, so, there's nothing else to do here... +@@ -301,8 +301,8 @@ + public IToken[] getCompletionsForToken(IDocument doc, ICompletionState state) { + IToken[] completionsForModule; + try { +- Tuple obj = PyParser.reparseDocument(new PyParser.ParserInfo(doc, true, state.getNature(), state.getLine())); +- SimpleNode n = obj.o1; ++ Tuple obj = PyParser.reparseDocument(new PyParser.ParserInfo(doc, true, state.getNature(), state.getLine())); ++ SimpleNode n = (SimpleNode) obj.o1; + IModule module = AbstractModule.createModule(n); + + completionsForModule = getCompletionsForModule(module, state, true, true); +@@ -380,7 +380,7 @@ + if(PyCodeCompletion.DEBUG_CODE_COMPLETION){ + Log.toLogFile(this, "getCompletionsForModule"); + } +- ArrayList importedModules = new ArrayList(); ++ ArrayList importedModules = new ArrayList(); + ILocalScope localScope = null; + if(state.getLocalImportsGotten() == false){ + //in the first analyzed module, we have to get the local imports too. +@@ -416,13 +416,14 @@ + + //now, lets check if this is actually a module that is an __init__ (if so, we have to get all + //the other .py files as modules that are in the same level as the __init__) +- Set initial = new HashSet(); ++ Set initial = new HashSet(); + if(searchSameLevelMods){ + String modName = module.getName(); + if(modName != null && modName.endsWith(".__init__")){ +- HashSet gotten = new HashSet(); ++ HashSet gotten = new HashSet(); + getAbsoluteImportTokens(FullRepIterable.getParentModule(modName), gotten, PyCodeCompletion.TYPE_IMPORT, true); +- for (IToken token : gotten) { ++ for (Iterator iter = gotten.iterator(); iter.hasNext();) { ++ IToken token = (IToken) iter.next(); + if(token.getRepresentation().equals("__init__") == false){ + initial.add(token); + } +@@ -432,7 +433,7 @@ + + if (state.getActivationToken().length() == 0) { + +- List completions = getGlobalCompletions(globalTokens, importedModules.toArray(new IToken[0]), wildImportedModules, state, module); ++ List completions = getGlobalCompletions(globalTokens, (IToken[]) importedModules.toArray(new IToken[0]), wildImportedModules, state, module); + + //now find the locals for the module + if (state.getLine() >= 0){ +@@ -443,12 +444,12 @@ + } + completions.addAll(initial); //just addd all that are in the same level if it was an __init__ + +- return completions.toArray(new IToken[0]); ++ return (IToken []) completions.toArray(new IToken[0]); + + }else{ //ok, we have a token, find it and get its completions. + + //first check if the token is a module... if it is, get the completions for that module. +- IToken[] tokens = findTokensOnImportedMods(importedModules.toArray(new IToken[0]), state, module); ++ IToken[] tokens = findTokensOnImportedMods((IToken []) importedModules.toArray(new IToken[0]), state, module); + if(tokens != null && tokens.length > 0){ + return tokens; + } +@@ -525,18 +526,19 @@ + * @param state this is the state used for the completion + * @param localScope this is the scope we're currently on (may be null) + */ +- @SuppressWarnings("unchecked") + private IToken[] getArgsCompletion(ICompletionState state, ILocalScope localScope) { + if (localScope != null){ + LocalScope s = (LocalScope) localScope; + IToken[] args = localScope.getLocalTokens(-1,-1,true); //only to get the args + String activationToken = state.getActivationToken(); + String firstPart = FullRepIterable.getFirstPart(activationToken); +- for (IToken token : args) { ++ for (int i = 0; i < args.length; i++) { ++ IToken token = (IToken) args[i]; + if(token.getRepresentation().equals(firstPart)){ + IToken[] interfaceForLocal = s.getInterfaceForLocal(firstPart, state.getActivationToken()); + Collection argsCompletionFromParticipants = getArgsCompletionFromParticipants(state, localScope, interfaceForLocal); +- for (IToken t : interfaceForLocal) { ++ for (int j = 0; j < interfaceForLocal.length; j++) { ++ IToken t = interfaceForLocal[j]; + if(!t.getRepresentation().equals(state.getQualifier())){ + argsCompletionFromParticipants.add(t); + } +@@ -548,7 +550,6 @@ + return null; + } + +- @SuppressWarnings("unchecked") + private Collection getArgsCompletionFromParticipants(ICompletionState state, ILocalScope localScope, IToken[] interfaceForLocal) { + ArrayList ret = new ArrayList(); + +@@ -570,8 +571,10 @@ + * + * @return a list of tokens found. + */ +- protected IToken[] searchOnSameLevelMods(Set initial, ICompletionState state) { +- for (IToken token : initial) { ++ protected IToken[] searchOnSameLevelMods(Set initial, ICompletionState state) { ++ for (Iterator iter = initial.iterator(); iter.hasNext();) { ++ IToken token= (IToken) iter.next(); ++ + //ok, maybe it was from the set that is in the same level as this one (this will only happen if we are on an __init__ module) + String rep = token.getRepresentation(); + +@@ -626,7 +629,7 @@ + if (module instanceof SourceModule) { + SourceModule s = (SourceModule) module; + try { +- Definition[] defs = s.findDefinition(state, state.getLine(), state.getCol(), state.getNature(), new ArrayList()); ++ Definition[] defs = (Definition []) s.findDefinition(state, state.getLine(), state.getCol(), state.getNature(), new ArrayList()); + for (int i = 0; i < defs.length; i++) { + if(!(defs[i].ast instanceof FunctionDef)){ + //we might want to extend that later to check the return of some function... +@@ -660,11 +663,11 @@ + /** + * @see ICodeCompletionASTManager#getGlobalCompletions + */ +- public List getGlobalCompletions(IToken[] globalTokens, IToken[] importedModules, IToken[] wildImportedModules, ICompletionState state, IModule current) { ++ public List getGlobalCompletions(IToken[] globalTokens, IToken[] importedModules, IToken[] wildImportedModules, ICompletionState state, IModule current) { + if(PyCodeCompletion.DEBUG_CODE_COMPLETION){ + Log.toLogFile(this, "getGlobalCompletions"); + } +- List completions = new ArrayList(); ++ List completions = new ArrayList(); + + //in completion with nothing, just go for what is imported and global tokens. + for (int i = 0; i < globalTokens.length; i++) { +@@ -700,7 +703,7 @@ + /** + * @return the builtin completions + */ +- public List getBuiltinCompletions(ICompletionState state, List completions) { ++ public List getBuiltinCompletions(ICompletionState state, List completions) { + IPythonNature nature = state.getNature(); + IToken[] builtinCompletions = getBuiltinComps(nature); + if(builtinCompletions != null){ +@@ -749,19 +752,19 @@ + */ + public IToken resolveImport(ICompletionState state, IToken imported) { + String curModName = imported.getParentPackage(); +- Tuple3 modTok = findOnImportedMods(new IToken[]{imported}, state.getNature(), imported.getRepresentation(), curModName); ++ Tuple3 modTok = findOnImportedMods(new IToken[]{imported}, state.getNature(), imported.getRepresentation(), curModName); + if(modTok != null && modTok.o1 != null){ + +- if(modTok.o2.length() == 0){ ++ if(((String) modTok.o2).length() == 0){ + return imported; //it's a module actually, so, no problems... + + } else{ + try{ +- state.checkResolveImportMemory(modTok.o1, modTok.o2); ++ state.checkResolveImportMemory((IModule) modTok.o1, (String) modTok.o2); + }catch(CompletionRecursionException e){ + return imported; + } +- IToken repInModule = getRepInModule(modTok.o1, modTok.o2, state.getNature(), state); ++ IToken repInModule = getRepInModule((IModule) modTok.o1, (String) modTok.o2, state.getNature(), state); + if(repInModule != null){ + return repInModule; + } +@@ -810,7 +813,8 @@ + state.setActivationToken(actToken); + } + IToken[] completionsForModule = getCompletionsForModule(module, state); +- for (IToken foundTok : completionsForModule) { ++ for (int i = 0; i < completionsForModule.length; i++) { ++ IToken foundTok = completionsForModule[i]; + if(foundTok.getRepresentation().equals(hasToBeFound)){ + return foundTok; + } +@@ -823,7 +827,6 @@ + /* (non-Javadoc) + * @see ICodeCompletionASTManager#getCompletionsForWildImport(ICompletionState, IModule, List, IToken) + */ +- @SuppressWarnings("unchecked") + public List getCompletionsForWildImport(ICompletionState state, IModule current, List completions, IToken name) { + try { + //this one is an exception... even though we are getting the name as a relative import, we say it +@@ -855,13 +858,13 @@ + } + + public IToken[] findTokensOnImportedMods( IToken[] importedModules, ICompletionState state, IModule current) { +- Tuple3 o = findOnImportedMods(importedModules, state.getNature(), state.getActivationToken(), current.getName()); ++ Tuple3 o = findOnImportedMods(importedModules, state.getNature(), state.getActivationToken(), current.getName()); + + if(o == null) + return null; + +- IModule mod = o.o1; +- String tok = o.o2; ++ IModule mod = (IModule) o.o1; ++ String tok = (String) o.o2; + + if(tok.length() == 0){ + //the activation token corresponds to an imported module. We have to get its global tokens and return them. +@@ -889,7 +892,7 @@ + * 0: mod + * 1: tok + */ +- public Tuple3 findOnImportedMods( IPythonNature nature, String activationToken, IModule current) { ++ public Tuple3 findOnImportedMods( IPythonNature nature, String activationToken, IModule current) { + IToken[] importedModules = current.getTokenImportedModules(); + return findOnImportedMods(importedModules, nature, activationToken, current.getName()); + } +@@ -910,21 +913,23 @@ + * 1: tok (string) + * 2: actual tok + */ +- public Tuple3 findOnImportedMods( IToken[] importedModules, IPythonNature nature, String activationToken, String currentModuleName) { ++ public Tuple3 findOnImportedMods( IToken[] importedModules, IPythonNature nature, String activationToken, String currentModuleName) { + + FullRepIterable iterable = new FullRepIterable(activationToken, true); +- for(String tok : iterable){ +- for (IToken importedModule : importedModules) { ++ for (Iterator i = iterable.iterator(); i.hasNext(); ) { ++ String tok = (String) i.next(); ++ for (int j = 0; j < importedModules.length; j++) { ++ IToken importedModule = importedModules[j]; + + final String modRep = importedModule.getRepresentation(); //this is its 'real' representation (alias) on the file (if it is from xxx import a as yyy, it is yyy) + + if(modRep.equals(tok)){ + String act = activationToken; +- Tuple r = findOnImportedMods(importedModule, tok, nature, act, currentModuleName); ++ Tuple r = findOnImportedMods(importedModule, tok, nature, act, currentModuleName); + if(r == null){ + return null; + } +- return new Tuple3(r.o1, r.o2, importedModule); ++ return new Tuple3(r.o1, r.o2, importedModule); + } + } + } +@@ -936,11 +941,11 @@ + * Checks if some module can be resolved and returns the module it is resolved to (and to which token). + * + */ +- protected Tuple findOnImportedMods(IToken importedModule, String tok, IPythonNature nature, ++ protected Tuple findOnImportedMods(IToken importedModule, String tok, IPythonNature nature, + String activationToken, String currentModuleName) { + + +- Tuple modTok = null; ++ Tuple modTok = null; + IModule mod = null; + + //ok, check if it is a token for the new import +@@ -970,9 +975,9 @@ + relative += "."+tok; + + modTok = findModuleFromPath(relative, nature, false, null); +- mod = modTok.o1; ++ mod = (IModule) modTok.o1; + if(checkValidity(currentModuleName, mod)){ +- Tuple ret = fixTok(modTok, tok, activationToken); ++ Tuple ret = fixTok(modTok, tok, activationToken); + return ret; + } + //ok, it is 'forced' as relative import because it has a level, so, it MUST return here +@@ -986,9 +991,9 @@ + //check as relative with complete rep + String asRelativeImport = importedModule.getAsRelativeImport(currentModuleName); + modTok = findModuleFromPath(asRelativeImport, nature, true, currentModuleName); +- mod = modTok.o1; ++ mod = (IModule) modTok.o1; + if(checkValidity(currentModuleName, mod)){ +- Tuple ret = fixTok(modTok, tok, activationToken); ++ Tuple ret = fixTok(modTok, tok, activationToken); + return ret; + } + +@@ -1000,12 +1005,12 @@ + originalWithoutRep = originalWithoutRep + ".__init__"; + } + modTok = findModuleFromPath(originalWithoutRep, nature, true, null); +- mod = modTok.o1; +- if(modTok.o2.endsWith("__init__") == false && checkValidity(currentModuleName, mod)){ ++ mod = (IModule) modTok.o1; ++ if(((String) modTok.o2).endsWith("__init__") == false && checkValidity(currentModuleName, mod)){ + if(mod.isInGlobalTokens(importedModule.getRepresentation(), nature, false)){ + //then this is the token we're looking for (otherwise, it might be a module). +- Tuple ret = fixTok(modTok, tok, activationToken); +- if(ret.o2.length() == 0){ ++ Tuple ret = fixTok(modTok, tok, activationToken); ++ if(((String) ret.o2).length() == 0){ + ret.o2 = importedModule.getRepresentation(); + }else{ + ret.o2 = importedModule.getRepresentation()+"."+ret.o2; +@@ -1018,9 +1023,9 @@ + + //the most 'simple' case: check as absolute with original rep + modTok = findModuleFromPath(importedModule.getOriginalRep(), nature, false, null); +- mod = modTok.o1; ++ mod = (IModule) modTok.o1; + if(checkValidity(currentModuleName, mod)){ +- Tuple ret = fixTok(modTok, tok, activationToken); ++ Tuple ret = fixTok(modTok, tok, activationToken); + return ret; + } + +@@ -1031,9 +1036,9 @@ + + //ok, one last shot, to see a relative looking in folders __init__ + modTok = findModuleFromPath(asRelativeImport, nature, false, null); +- mod = modTok.o1; ++ mod = (IModule) modTok.o1; + if(checkValidity(currentModuleName, mod)){ +- Tuple ret = fixTok(modTok, tok, activationToken); ++ Tuple ret = fixTok(modTok, tok, activationToken); + //now let's see if what we did when we found it as a relative import is correct: + + //if we didn't find it in an __init__ module, all should be ok +@@ -1088,13 +1093,13 @@ + * + * This means that if we had testcase.TestCase and found it as TestCase, the token is added with TestCase + */ +- protected Tuple fixTok(Tuple modTok, String tok, String activationToken) { ++ protected Tuple fixTok(Tuple modTok, String tok, String activationToken) { + if(activationToken.length() > tok.length() && activationToken.startsWith(tok)){ + String toAdd = activationToken.substring(tok.length() + 1); +- if(modTok.o2.length() == 0){ ++ if(((String) modTok.o2).length() == 0){ + modTok.o2 = toAdd; + }else{ +- modTok.o2 += "."+toAdd; ++ modTok.o2 = (String) modTok.o2 + "."+toAdd; + } + } + return modTok; +@@ -1114,7 +1119,7 @@ + * @return tuple with found module and the String removed from the path in + * order to find the module. + */ +- protected Tuple findModuleFromPath(String rep, IPythonNature nature, boolean dontSearchInit, String currentModuleName){ ++ protected Tuple findModuleFromPath(String rep, IPythonNature nature, boolean dontSearchInit, String currentModuleName){ + String tok = ""; + boolean lookingForRelative = currentModuleName != null; + IModule mod = getModule(rep, nature, dontSearchInit, lookingForRelative); +@@ -1137,9 +1142,9 @@ + //if it equal, it should not match either, as it was found as the parent module... this can not happen because it must find + //it with __init__ if it was the parent module + if (mod.getName().length() <= parentModule.length()){ +- return new Tuple(null, null); ++ return new Tuple(null, null); + } + } +- return new Tuple((AbstractModule)mod, tok); ++ return new Tuple((AbstractModule)mod, tok); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/CompletionState.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/CompletionState.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/CompletionState.java 2006-09-24 03:03:16.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/CompletionState.java 2006-11-05 20:59:42.000000000 +0100 +@@ -24,13 +24,13 @@ + public IPythonNature nature; + public String qualifier; + +- public Memo memory = new Memo(); +- public Memo definitionMemory = new Memo(); +- public Memo wildImportMemory = new Memo(); +- public Memo importedModsCalled = new Memo(); +- public Memo findMemory = new Memo(); +- public Memo resolveImportMemory = new Memo(); +- public Memo findDefinitionMemory = new Memo(); ++ public Memo memory = new Memo(); ++ public Memo definitionMemory = new Memo(); ++ public Memo wildImportMemory = new Memo(); ++ public Memo importedModsCalled = new Memo(); ++ public Memo findMemory = new Memo(); ++ public Memo resolveImportMemory = new Memo(); ++ public Memo findDefinitionMemory = new Memo(); + + public boolean builtinsGotten=false; + public boolean localImportsGotten=false; +@@ -38,7 +38,7 @@ + + public int lookingForInstance=LOOKING_FOR_INSTANCE_UNDEFINED; + +- public CompletionState getCopy(){ ++ public ICompletionState getCopy(){ + CompletionState state = new CompletionState(); + state.activationToken = activationToken; + state.line = line; +@@ -66,7 +66,7 @@ + * + * @author Fabio Zadrozny + */ +- static class Memo{ ++ static class Memo{ + + private int max; + +@@ -82,38 +82,38 @@ + * if more than this number of ocurrences is found, we are in a recursion + */ + private static final int MAX_NUMBER_OF_OCURRENCES = 5; +- +- public Map> memo = new HashMap>(); + +- public boolean isInRecursion(IModule caller, E def){ +- Map val; ++ public Map memo = new HashMap(); ++ ++ public boolean isInRecursion(IModule caller, Object def){ ++ Map val; + + boolean occuredMoreThanMax = false; + if(!memo.containsKey(caller)){ + + //still does not exist, let's create the structure... +- val = new HashMap(); ++ val = new HashMap(); + memo.put(caller, val); + + }else{ +- val = memo.get(caller); ++ val = (Map) memo.get(caller); + + if(val.containsKey(def)){ //may be a recursion +- Integer numberOfOccurences = val.get(def); ++ Integer numberOfOccurences = (Integer) val.get(def); + + //should never be null... +- if(numberOfOccurences > max){ ++ if(numberOfOccurences.intValue() > max){ + occuredMoreThanMax = true; //ok, we are recursing... + } + } + } + + //let's raise the number of ocurrences anyway +- Integer numberOfOccurences = val.get(def); ++ Integer numberOfOccurences = (Integer) val.get(def); + if(numberOfOccurences == null){ +- val.put(def, 1); //this is the first ocurrence ++ val.put(def, new Integer(1)); //this is the first ocurrence + }else{ +- val.put(def, numberOfOccurences+1); ++ val.put(def, new Integer(numberOfOccurences.intValue() + 1)); + } + + return occuredMoreThanMax; +@@ -284,7 +284,7 @@ + } + + public ICompletionState getCopyWithActTok(String value) { +- CompletionState copy = getCopy(); ++ ICompletionState copy = getCopy(); + copy.setActivationToken(value); + return copy; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/AbstractModule.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/AbstractModule.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/AbstractModule.java 2006-09-23 23:22:50.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/AbstractModule.java 2006-11-05 20:59:42.000000000 +0100 +@@ -10,10 +10,10 @@ + import java.util.List; + + import org.eclipse.jface.text.IDocument; +-import org.python.pydev.core.FindInfo; + import org.python.pydev.core.FullRepIterable; + import org.python.pydev.core.ICodeCompletionASTManager; + import org.python.pydev.core.ICompletionState; ++import org.python.pydev.core.IDefinition; + import org.python.pydev.core.ILocalScope; + import org.python.pydev.core.IModule; + import org.python.pydev.core.IModulesManager; +@@ -23,7 +23,6 @@ + import org.python.pydev.core.Tuple; + import org.python.pydev.editor.codecompletion.revisited.CompletionState; + import org.python.pydev.editor.codecompletion.revisited.PythonPathHelper; +-import org.python.pydev.editor.codecompletion.revisited.visitors.Definition; + import org.python.pydev.parser.PyParser; + import org.python.pydev.parser.jython.SimpleNode; + +@@ -111,7 +110,8 @@ + state.setActivationToken (headAndTail[0]); + String head = headAndTail[1]; + IToken[] globalTokens = astManager.getCompletionsForModule(this, state, searchSameLevelMods); +- for (IToken token : globalTokens) { ++ for (int i = 0; i < globalTokens.length; i++) { ++ IToken token = globalTokens[i]; + String rep = token.getRepresentation(); + + if(ifHasGetAttributeConsiderInTokens && +@@ -134,7 +134,7 @@ + /** + * The token we're looking for must be the state activation token + */ +- public abstract Definition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List findInfo) throws Exception; ++ public abstract IDefinition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List findInfo) throws Exception; + + /** + * @see org.python.pydev.core.IModule#getGlobalTokens(org.python.pydev.editor.codecompletion.revisited.CompletionState, org.python.pydev.core.ICodeCompletionASTManager) +@@ -201,13 +201,13 @@ + if(f != null){ + String absolutePath = REF.getFileAbsolutePath(f); + if(PythonPathHelper.isValidSourceFile(absolutePath)){ +- Tuple obj = PyParser.reparseDocument(new PyParser.ParserInfo(doc, true, nature, currLine)); +- SimpleNode n = obj.o1; ++ Tuple obj = PyParser.reparseDocument(new PyParser.ParserInfo(doc, true, nature, currLine)); ++ SimpleNode n = (SimpleNode) obj.o1; + return new SourceModule(name, f, n); + } + } else { +- Tuple obj = PyParser.reparseDocument(new PyParser.ParserInfo(doc, true, nature, currLine)); +- SimpleNode n = obj.o1; ++ Tuple obj = PyParser.reparseDocument(new PyParser.ParserInfo(doc, true, nature, currLine)); ++ SimpleNode n = (SimpleNode) obj.o1; + return new SourceModule(name, f, n); + } + return null; +@@ -281,7 +281,6 @@ + /** + * @see org.python.pydev.core.IModule#toString() + */ +- @Override + public String toString() { + String n2 = this.getClass().getName(); + String n = n2.substring(n2.lastIndexOf('.')+1); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/CompiledModule.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/CompiledModule.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/CompiledModule.java 2006-09-25 01:15:13.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/CompiledModule.java 2006-11-05 20:59:42.000000000 +0100 +@@ -7,6 +7,7 @@ + + import java.io.File; + import java.io.IOException; ++import java.util.AbstractList; + import java.util.ArrayList; + import java.util.HashMap; + import java.util.Iterator; +@@ -20,6 +21,7 @@ + import org.python.pydev.core.FullRepIterable; + import org.python.pydev.core.ICodeCompletionASTManager; + import org.python.pydev.core.ICompletionState; ++import org.python.pydev.core.IDefinition; + import org.python.pydev.core.IModule; + import org.python.pydev.core.IPythonNature; + import org.python.pydev.core.IToken; +@@ -34,13 +36,13 @@ + /** + * @author Fabio Zadrozny + */ +-public class CompiledModule extends AbstractModule{ ++public class CompiledModule extends AbstractModule{ // + + public static boolean COMPILED_MODULES_ENABLED = true; + + public static boolean TRACE_COMPILED_MODULES = false; + +- private HashMap cache = new HashMap(); ++ private HashMap cache = new HashMap(); + + /** + * These are the tokens the compiled module has. +@@ -49,7 +51,6 @@ + + private File file; + +- @Override + public File getFile() { + return file; + } +@@ -66,7 +67,6 @@ + * + * @param module - module from where to get completions. + */ +- @SuppressWarnings("unchecked") + public CompiledModule(String name, int tokenTypes, ICodeCompletionASTManager manager){ + super(name); + if(COMPILED_MODULES_ENABLED){ +@@ -95,8 +95,9 @@ + } + } + if(tokens != null && tokens.length > 0){ +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_MODULES_OBSERVER); +- for (IModulesObserver observer : participants) { ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_MODULES_OBSERVER); ++ for (Iterator i = participants.iterator(); i.hasNext(); ) { ++ IModulesObserver observer = (IModulesObserver) i.next(); + observer.notifyCompiledModuleCreated(this, manager); + } + } +@@ -113,8 +114,8 @@ + } + AbstractShell shell = AbstractShell.getServerShell(manager.getNature(), AbstractShell.COMPLETION_SHELL); + synchronized(shell){ +- Tuple> completions = shell.getImportCompletions(name, manager.getModulesManager().getCompletePythonPath()); +- String fPath = completions.o1; ++ Tuple completions = shell.getImportCompletions(name, manager.getModulesManager().getCompletePythonPath()); ++ String fPath = (String) completions.o1; + if(!fPath.equals("None")){ + this.file = new File(fPath); + } +@@ -127,9 +128,9 @@ + this.file = f2; + } + } +- ArrayList array = new ArrayList(); ++ ArrayList array = new ArrayList(); + +- for (Iterator iter = completions.o2.iterator(); iter.hasNext();) { ++ for (Iterator iter = ((List) completions.o2).iterator(); iter.hasNext();) { + String[] element = (String[]) iter.next(); + //let's make this less error-prone. + try { +@@ -168,7 +169,7 @@ + array.add(new CompiledToken("__file__","","",name,PyCodeCompletion.TYPE_BUILTIN)); + } + +- tokens = array.toArray(new CompiledToken[0]); ++ tokens = (CompiledToken[]) array.toArray(new CompiledToken[0]); + } + } + +@@ -218,9 +219,9 @@ + AbstractShell shell = AbstractShell.getServerShell(manager.getNature(), AbstractShell.COMPLETION_SHELL); + synchronized(shell){ + String act = name+"."+state.getActivationToken(); +- List completions = shell.getImportCompletions(act, manager.getModulesManager().getCompletePythonPath()).o2; ++ List completions = (List) shell.getImportCompletions(act, manager.getModulesManager().getCompletePythonPath()).o2; + +- ArrayList array = new ArrayList(); ++ ArrayList array = new ArrayList(); + + for (Iterator iter = completions.iterator(); iter.hasNext();) { + String[] element = (String[]) iter.next(); +@@ -242,7 +243,6 @@ + return toks; + } + +- @Override + public boolean isInGlobalTokens(String tok, IPythonNature nature) { + //we have to override because there is no way to check if it is in some import from some other place if it has dots on the tok... + +@@ -255,7 +255,9 @@ + state.setActivationToken (headAndTail[0]); + String head = headAndTail[1]; + IToken[] globalTokens = getGlobalTokens(state, nature.getAstManager()); +- for (IToken token : globalTokens) { ++ for (int i = 0; i < globalTokens.length; i++) { ++ IToken token = globalTokens[i]; ++ + if(token.getRepresentation().equals(head)){ + return true; + } +@@ -269,24 +271,24 @@ + * @param findInfo + * @see org.python.pydev.editor.codecompletion.revisited.modules.AbstractModule#findDefinition(java.lang.String, int, int) + */ +- public Definition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List findInfo) throws Exception { ++ public IDefinition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List findInfo) throws Exception { + String token = state.getActivationToken(); + AbstractShell shell = AbstractShell.getServerShell(nature, AbstractShell.COMPLETION_SHELL); + synchronized(shell){ +- Tuple def = shell.getLineCol(this.name, token, nature.getAstManager().getModulesManager().getCompletePythonPath()); ++ Tuple def = shell.getLineCol(this.name, token, nature.getAstManager().getModulesManager().getCompletePythonPath()); + if(def == null){ + return new Definition[0]; + } +- String fPath = def.o1[0]; ++ String fPath = ((String [])def.o1)[0]; + if(fPath.equals("None")){ + return new Definition[0]; + } + File f = new File(fPath); + String foundModName = nature.resolveModule(f); +- String foundAs = def.o1[1]; ++ String foundAs = ((String []) def.o1)[1]; + + IModule mod = nature.getAstManager().getModule(foundModName, nature, true); +- int foundLine = def.o2[0]; ++ int foundLine = ((int []) def.o2)[0]; + if(foundLine == 0 && foundAs.length() > 0 && mod != null){ + IModule sourceMod = AbstractModule.createModuleFromDoc(mod.getName(), f, new Document(REF.getFileContents(f)), nature, 0); + if(sourceMod instanceof SourceModule){ +@@ -299,7 +301,7 @@ + if(mod == null){ + mod = this; + } +- int foundCol = def.o2[1]; ++ int foundCol = ((int [])def.o2)[1]; + if(foundCol < 0){ + foundCol = 0; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/EmptyModule.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/EmptyModule.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/EmptyModule.java 2006-07-17 01:39:51.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/EmptyModule.java 2006-11-05 20:59:42.000000000 +0100 +@@ -12,6 +12,7 @@ + import org.python.pydev.core.FindInfo; + import org.python.pydev.core.ICodeCompletionASTManager; + import org.python.pydev.core.ICompletionState; ++import org.python.pydev.core.IDefinition; + import org.python.pydev.core.IPythonNature; + import org.python.pydev.core.IToken; + import org.python.pydev.editor.codecompletion.revisited.visitors.Definition; +@@ -27,7 +28,6 @@ + private static final long serialVersionUID = 1L; + public File f; + +- @Override + public File getFile() { + return f; + } +@@ -78,7 +78,7 @@ + /** + * @see org.python.pydev.editor.codecompletion.revisited.modules.AbstractModule#findDefinition(java.lang.String, int, int) + */ +- public Definition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List findInfo) throws Exception { ++ public IDefinition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List findInfo) throws Exception { + throw new RuntimeException("Not intended to be called"); + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/SourceModule.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/SourceModule.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/SourceModule.java 2006-09-24 03:03:16.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/SourceModule.java 2006-11-05 20:59:42.000000000 +0100 +@@ -193,13 +193,13 @@ + if(iActTok > actToks.length){ + break; //unable to find it + } +- definitions = findDefinition(initialState.getCopyWithActTok(value), token.getLineDefinition(), token.getColDefinition(), manager.getNature(), new ArrayList()); ++ definitions = (Definition []) findDefinition(initialState.getCopyWithActTok(value), token.getLineDefinition(), token.getColDefinition(), manager.getNature(), new ArrayList()); + if(definitions.length == 1){ + Definition d = definitions[0]; + if(d.ast instanceof Assign){ + Assign assign = (Assign) d.ast; + value = NodeUtils.getRepresentationString(assign.value); +- definitions = findDefinition(initialState.getCopyWithActTok(value), d.line, d.col, manager.getNature(), new ArrayList()); ++ definitions = (Definition []) findDefinition(initialState.getCopyWithActTok(value), d.line, d.col, manager.getNature(), new ArrayList()); + }else if(d.ast instanceof ClassDef){ + IToken[] toks = (IToken[]) getToks(initialState, manager, d.ast).toArray(new IToken[0]); + if(iActTok == actToks.length-1){ +@@ -215,7 +215,7 @@ + if(visitor.definitions.size() == 0){ + return new IToken[0]; + } +- d = visitor.definitions.get(0); ++ d = (Definition) visitor.definitions.get(0); + value = d.value; + if(d instanceof AssignDefinition){ + return getValueCompletions(initialState, manager, value, d.module); +@@ -224,7 +224,7 @@ + if(d.module instanceof SourceModule){ + SourceModule m = (SourceModule) d.module; + String joined = FullRepIterable.joinFirstParts(actToks); +- Definition[] definitions2 = m.findDefinition(initialState.getCopyWithActTok(joined), d.line, d.col,manager.getNature(), null); ++ Definition[] definitions2 = (Definition []) m.findDefinition(initialState.getCopyWithActTok(joined), d.line, d.col,manager.getNature(), null); + if(definitions2.length == 0){ + return new IToken[0]; + } +@@ -285,8 +285,8 @@ + * @param ast + * @return + */ +- private List getToks(ICompletionState initialState, ICodeCompletionASTManager manager, SimpleNode ast) { +- List modToks = modToks = new ArrayList(Arrays.asList(GlobalModelVisitor.getTokens(ast, GlobalModelVisitor.INNER_DEFS, name)));//name = moduleName ++ private List getToks(ICompletionState initialState, ICodeCompletionASTManager manager, SimpleNode ast) { ++ List modToks = modToks = new ArrayList(Arrays.asList(GlobalModelVisitor.getTokens(ast, GlobalModelVisitor.INNER_DEFS, name)));//name = moduleName + + try { + //COMPLETION: get the completions for the whole hierarchy if this is a class!! +@@ -335,14 +335,13 @@ + return modToks; + } + +- @SuppressWarnings("unchecked") +- public Definition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List lFindInfo) throws Exception{ ++ public IDefinition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List lFindInfo) throws Exception{ + String rep = state.getActivationToken(); + if(lFindInfo == null){ +- lFindInfo = new ArrayList(); ++ lFindInfo = new ArrayList(); + } + //the line passed in starts at 1 and the lines for the visitor start at 0 +- ArrayList toRet = new ArrayList(); ++ ArrayList toRet = new ArrayList(); + FindInfo info = new FindInfo(); + lFindInfo.add(info); + +@@ -384,20 +383,22 @@ + //now, check for locals + IToken[] localTokens = scopeVisitor.scope.getAllLocalTokens(); + info.localTokens = localTokens; +- for (IToken tok : localTokens) { ++ for (int i = 0; i < localTokens.length; i++) { ++ IToken tok = localTokens[i]; + if(tok.getRepresentation().equals(rep)){ + return new Definition[]{new Definition(tok, scopeVisitor.scope, this, true)}; + } + } + + //not found... check as local imports +- List localImportedModules = scopeVisitor.scope.getLocalImportedModules(line, col, this.name); +- for (IToken tok : localImportedModules) { ++ List localImportedModules = scopeVisitor.scope.getLocalImportedModules(line, col, this.name); ++ for (Iterator i = localImportedModules.iterator(); i.hasNext(); ) { ++ IToken tok = (IToken) i.next(); + if(tok.getRepresentation().equals(rep)){ +- Tuple3 o = nature.getAstManager().findOnImportedMods(new IToken[]{tok}, nature, rep, this.getName()); ++ Tuple3 o = nature.getAstManager().findOnImportedMods(new IToken[]{tok}, nature, rep, this.getName()); + if(o != null && o.o1 instanceof SourceModule){ + ICompletionState copy = state.getCopy(); +- copy.setActivationToken(o.o2); ++ copy.setActivationToken((String) o.o2); + + findDefinitionsFromModAndTok(nature, toRet, null, (SourceModule) o.o1, copy); + } +@@ -421,7 +422,9 @@ + nature.getAstManager()); + + String withoutSelf = rep.substring(5); +- for (IToken token : globalTokens) { ++ for (int i = 0; i < globalTokens.length; i++) { ++ IToken token = globalTokens[i]; ++ + if(token.getRepresentation().equals(withoutSelf)){ + String parentPackage = token.getParentPackage(); + IModule module = nature.getAstManager().getModule(parentPackage, nature, true); +@@ -432,11 +435,11 @@ + } + + SimpleNode ast2 = ((SourceToken)token).getAst(); +- Tuple def = getLineColForDefinition(ast2); +- FastStack stack = new FastStack(); ++ Tuple def = getLineColForDefinition(ast2); ++ FastStack stack = new FastStack(); + stack.add(classDef); + ILocalScope scope = new LocalScope(stack); +- return new Definition[]{new Definition(def.o1, def.o2, token.getRepresentation(), ast2, scope, module)}; ++ return new Definition[]{new Definition(((Integer) def.o1).intValue(), ((Integer) def.o2).intValue(), token.getRepresentation(), ast2, scope, module)}; + + }else{ + return new Definition[0]; +@@ -451,19 +454,19 @@ + String tok = rep; + SourceModule mod = this; + +- Tuple3 o = nature.getAstManager().findOnImportedMods(nature, rep, this); ++ Tuple3 o = nature.getAstManager().findOnImportedMods(nature, rep, this); + + if(o != null && o.o1 instanceof SourceModule){ + mod = (SourceModule) o.o1; +- tok = o.o2; ++ tok = (String) o.o2; + + }else if(o != null && o.o1 instanceof CompiledModule){ + //ok, we have to check the compiled module +- tok = o.o2; ++ tok = (String) o.o2; + if (tok == null || tok.length() == 0 ){ +- return new Definition[]{new Definition(1,1,"",null,null,o.o1)}; ++ return new Definition[]{new Definition(1,1,"",null,null, (IModule) o.o1)}; + }else{ +- return (Definition[]) o.o1.findDefinition(state.getCopyWithActTok(tok), 0, 0, nature, lFindInfo); ++ return (Definition[]) ((IModule) o.o1).findDefinition(state.getCopyWithActTok(tok), 0, 0, nature, lFindInfo); + } + } + +@@ -477,13 +480,13 @@ + //ignore (will return what we've got so far) + } + +- return toRet.toArray(new Definition[0]); ++ return (Definition []) toRet.toArray(new Definition[0]); + } + + /** + * Finds the definitions for some module and a token from that module + */ +- private void findDefinitionsFromModAndTok(IPythonNature nature, ArrayList toRet, String moduleImported, SourceModule mod, ICompletionState state) { ++ private void findDefinitionsFromModAndTok(IPythonNature nature, ArrayList toRet, String moduleImported, SourceModule mod, ICompletionState state) { + String tok = state.getActivationToken(); + if(tok != null){ + if(tok.length() > 0){ +@@ -506,7 +509,7 @@ + } + } + +- private IDefinition getModuleDefinition(IPythonNature nature, ArrayList toRet, SourceModule mod, String moduleImported) { ++ private IDefinition getModuleDefinition(IPythonNature nature, ArrayList toRet, SourceModule mod, String moduleImported) { + String rel = AbstractToken.makeRelative(mod.getName(), moduleImported); + IModule modFound = nature.getAstManager().getModule(rel, nature, false); + if(modFound == null){ +@@ -541,13 +544,15 @@ + }else{ + tokens = getGlobalTokens(); + } +- for (IToken token : tokens) { ++ for (int i = 0; i < tokens.length; i++) { ++ IToken token = tokens[i]; ++ + boolean sameRep = token.getRepresentation().equals(rep); + if(sameRep){ + if(token instanceof SourceToken){ + //ok, we found it + SimpleNode a = ((SourceToken)token).getAst(); +- Tuple def = getLineColForDefinition(a); ++ Tuple def = getLineColForDefinition(a); + + String parentPackage = token.getParentPackage(); + IModule module = this; +@@ -570,10 +575,10 @@ + PydevPlugin.log(e); + } + } +- return new Definition(def.o1, def.o2, rep, a, scopeVisitor.scope, module); ++ return new Definition(((Integer) def.o1).intValue(), ((Integer) def.o2).intValue(), rep, a, scopeVisitor.scope, module); + }else{ + //line, col +- return new Definition(def.o1, def.o2, rep, a, new LocalScope(new FastStack()), module); ++ return new Definition(((Integer) def.o1).intValue(), ((Integer) def.o2).intValue(), rep, a, new LocalScope(new FastStack()), module); + } + }else{ + IToken comp = (IToken) token; //Compiled or Concrete token +@@ -581,7 +586,8 @@ + FullRepIterable iterable = new FullRepIterable(parentPackage, true); + + IModule module = null; +- for(String modName: iterable){ ++ for (Iterator j = iterable.iterator(); j.hasNext(); ) { ++ String modName = (String) j.next(); + module = nature.getAstManager().getModule(modName, nature, true); + if(module != null){ + break; +@@ -597,7 +603,7 @@ + } + finalRep += comp.getRepresentation(); + try { +- IDefinition[] definitions = module.findDefinition(state.getCopyWithActTok(finalRep), -1, -1, nature, new ArrayList()); ++ IDefinition[] definitions = module.findDefinition(state.getCopyWithActTok(finalRep), -1, -1, nature, new ArrayList()); + if(definitions.length > 0){ + return (Definition) definitions[0]; + } +@@ -611,7 +617,7 @@ + return null; + } + +- public Tuple getLineColForDefinition(SimpleNode a){ ++ public Tuple getLineColForDefinition(SimpleNode a){ + int line = a.beginLine; + int col = a.beginColumn; + +@@ -626,7 +632,7 @@ + col = c.name.beginColumn; + } + +- return new Tuple(line,col); ++ return new Tuple(new Integer(line), new Integer(col)); + } + + public IToken[] getLocalTokens(int line, int col){ +@@ -708,7 +714,6 @@ + } + } + +- @Override + public boolean equals(Object obj) { + if (!(obj instanceof SourceModule)) { + return false; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/SourceToken.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/SourceToken.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/SourceToken.java 2006-07-17 01:39:51.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/modules/SourceToken.java 2006-11-05 20:59:42.000000000 +0100 +@@ -126,7 +126,6 @@ + } + } + +- @Override + public boolean equals(Object obj) { + if(!(obj instanceof SourceToken)) + return false; +@@ -143,7 +142,6 @@ + return true; + } + +- @Override + public int hashCode() { + return 7*getLineDefinition()*getColDefinition(); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/ModulesManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/ModulesManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/ModulesManager.java 2006-07-17 01:39:51.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/ModulesManager.java 2006-11-05 20:59:42.000000000 +0100 +@@ -61,11 +61,11 @@ + /** + * The access to the cache is synchronized + */ +- private LRUCache, AbstractModule> internalCache; ++ private LRUCache internalCache; + + private ModulesManagerCache() { + mutex = this; +- internalCache = new LRUCache, AbstractModule>(MAX_NUMBER_OF_MODULES); ++ internalCache = new LRUCache(MAX_NUMBER_OF_MODULES); + } + + /** +@@ -73,11 +73,11 @@ + */ + public AbstractModule getObj(ModulesKey key, ModulesManager modulesManager) { + synchronized (mutex) { +- Tuple keyTuple = new Tuple(key, modulesManager); ++ Tuple keyTuple = new Tuple(key, modulesManager); + +- AbstractModule obj = internalCache.getObj(keyTuple); ++ AbstractModule obj = (AbstractModule) internalCache.getObj(keyTuple); + if(obj == null && modulesManager.modulesKeys.containsKey(key)){ +- key = modulesManager.modulesKeys.get(key); //get the 'real' key ++ key = (ModulesKey) modulesManager.modulesKeys.get(key); //get the 'real' key + obj = AbstractModule.createEmptyModule(key.name, key.file); + internalCache.add(keyTuple, obj); + } +@@ -87,14 +87,14 @@ + + public void remove(ModulesKey key, ModulesManager modulesManager) { + synchronized (mutex) { +- Tuple keyTuple = new Tuple(key, modulesManager); ++ Tuple keyTuple = new Tuple(key, modulesManager); + internalCache.remove(keyTuple); + } + } + + public void add(ModulesKey key, AbstractModule n, ModulesManager modulesManager) { + synchronized (mutex) { +- Tuple keyTuple = new Tuple(key, modulesManager); ++ Tuple keyTuple = new Tuple(key, modulesManager); + internalCache.add(keyTuple, n); + } + } +@@ -113,7 +113,7 @@ + * + * It is sorted so that we can get things in a 'subtree' faster + */ +- protected transient SortedMap modulesKeys = new TreeMap(); ++ protected transient SortedMap modulesKeys = new TreeMap(); + private static transient ModulesManagerCache cache = createCache(); + + private static ModulesManagerCache createCache(){ +@@ -124,7 +124,7 @@ + * This is the set of files that was found just right after unpickle (it should not be changed after that, + * and serves only as a reference cache). + */ +- protected transient Set files = new HashSet(); ++ protected transient Set files = new HashSet(); + + /** + * Helper for using the pythonpath. Also persisted. +@@ -137,9 +137,9 @@ + * Custom deserialization is needed. + */ + private void readObject(ObjectInputStream aStream) throws IOException, ClassNotFoundException { +- modulesKeys = new TreeMap(); ++ modulesKeys = new TreeMap(); + +- files = new HashSet(); ++ files = new HashSet(); + aStream.defaultReadObject(); + Set set = (Set) aStream.readObject(); + for (Iterator iter = set.iterator(); iter.hasNext();) { +@@ -159,13 +159,13 @@ + private void writeObject(ObjectOutputStream aStream) throws IOException { + aStream.defaultWriteObject(); + //write only the keys +- aStream.writeObject(new HashSet(modulesKeys.keySet())); ++ aStream.writeObject(new HashSet(modulesKeys.keySet())); + } + + /** + * @param modules The modules to set. + */ +- private void setModules(SortedMap keys) { ++ private void setModules(SortedMap keys) { + this.modulesKeys = keys; + } + +@@ -173,7 +173,7 @@ + /** + * @return Returns the modules. + */ +- protected Map getModules() { ++ protected Map getModules() { + throw new RuntimeException("Deprecated"); + } + +@@ -191,7 +191,7 @@ + * @param fromJar OUT - the names of the modules that were found inside a jar + * @return the total number of modules found (that's completions + fromJar) + */ +- private int listFilesForCompletion(IProgressMonitor monitor, List pythonpathList, List completions, List fromJar) { ++ private int listFilesForCompletion(IProgressMonitor monitor, List pythonpathList, List completions, List fromJar) { + int total = 0; + //first thing: get all files available from the python path and sum them up. + for (Iterator iter = pythonpathList.iterator(); iter.hasNext() && monitor.isCanceled() == false;) { +@@ -199,13 +199,13 @@ + + //the slow part is getting the files... not much we can do (I think). + File root = new File(element); +- List[] below = pythonPathHelper.getModulesBelow(root, monitor); ++ List[] below = pythonPathHelper.getModulesBelow(root, monitor); + if(below != null){ + completions.addAll(below[0]); + total += below[0].size(); + + }else{ //ok, it was null, so, maybe this is not a folder, but zip file with java classes... +- List currFromJar = PythonPathHelper.getFromJar(root, monitor); ++ List currFromJar = PythonPathHelper.getFromJar(root, monitor); + if(currFromJar != null){ + fromJar.addAll(currFromJar); + total += currFromJar.size(); +@@ -216,9 +216,9 @@ + } + + public void changePythonPath(String pythonpath, final IProject project, IProgressMonitor monitor, String defaultSelectedInterpreter) { +- List pythonpathList = pythonPathHelper.setPythonPath(pythonpath); +- List completions = new ArrayList(); +- List fromJar = new ArrayList(); ++ List pythonpathList = pythonPathHelper.setPythonPath(pythonpath); ++ List completions = new ArrayList(); ++ List fromJar = new ArrayList(); + int total = listFilesForCompletion(monitor, pythonpathList, completions, fromJar); + changePythonPath(pythonpath, project, monitor, pythonpathList, completions, fromJar, total, defaultSelectedInterpreter); + } +@@ -228,9 +228,9 @@ + * @param project may be null if there is no associated project. + */ + private void changePythonPath(String pythonpath, final IProject project, IProgressMonitor monitor, +- List pythonpathList, List completions, List fromJar, int total, String defaultSelectedInterpreter) { ++ List pythonpathList, List completions, List fromJar, int total, String defaultSelectedInterpreter) { + +- SortedMap keys = new TreeMap(); ++ SortedMap keys = new TreeMap(); + int j = 0; + + //now, create in memory modules for all the loaded files (empty modules). +@@ -272,7 +272,9 @@ + } + } + +- for (String modName : fromJar) { ++ for (Iterator iter = fromJar.iterator(); iter.hasNext();) { ++ String modName = (String) iter.next(); ++ + final ModulesKey k = new ModulesKey(modName, null); + keys.put(k, k); + } +@@ -306,7 +308,7 @@ + + + }else if (f != null){ //ok, remove the module that has a key with this file, as it can no longer be resolved +- Set toRemove = new HashSet(); ++ Set toRemove = new HashSet(); + for (Iterator iter = modulesKeys.keySet().iterator(); iter.hasNext();) { + ModulesKey key = (ModulesKey) iter.next(); + if(key.file != null && key.file.equals(f)){ +@@ -347,7 +349,7 @@ + return; + } + +- List toRem = new ArrayList(); ++ List toRem = new ArrayList(); + for (Iterator iter = modulesKeys.keySet().iterator(); iter.hasNext();) { + ModulesKey key = (ModulesKey) iter.next(); + if (key.file != null && key.file.equals(file)) { +@@ -368,7 +370,7 @@ + } + + String absolutePath = REF.getFileAbsolutePath(file); +- List toRem = new ArrayList(); ++ List toRem = new ArrayList(); + + for (Iterator iter = modulesKeys.keySet().iterator(); iter.hasNext();) { + ModulesKey key = (ModulesKey) iter.next(); +@@ -386,10 +388,10 @@ + * + * @param toRem the modules to be removed + */ +- protected void removeThem(Collection toRem) { ++ protected void removeThem(Collection toRem) { + //really remove them here. +- for (Iterator iter = toRem.iterator(); iter.hasNext();) { +- doRemoveSingleModule(iter.next()); ++ for (Iterator iter = toRem.iterator(); iter.hasNext();) { ++ doRemoveSingleModule((ModulesKey) iter.next()); + } + } + +@@ -419,15 +421,17 @@ + /** + * @return a set of all module keys + */ +- public Set getAllModuleNames() { +- Set s = new HashSet(); +- for (ModulesKey key : this.modulesKeys.keySet()) { ++ public Set getAllModuleNames() { ++ Set s = new HashSet(); ++ for (Iterator iter = this.modulesKeys.keySet().iterator(); iter.hasNext();) { ++ ModulesKey key = (ModulesKey) iter.next(); ++ + s.add(key.name); + } + return s; + } + +- public SortedMap getAllDirectModulesStartingWith(String strStartingWith) { ++ public SortedMap getAllDirectModulesStartingWith(String strStartingWith) { + if(strStartingWith.length() == 0){ + return modulesKeys; + } +@@ -436,7 +440,7 @@ + return modulesKeys.subMap(startingWith, endingWith); + } + +- public SortedMap getAllModulesStartingWith(String strStartingWith) { ++ public SortedMap getAllModulesStartingWith(String strStartingWith) { + return getAllDirectModulesStartingWith(strStartingWith); + } + +@@ -591,7 +595,8 @@ + * @return true if there is a token that has rep as its representation. + */ + private boolean contains(IToken[] tokens, String rep) { +- for (IToken token : tokens) { ++ for (int i = 0; i < tokens.length; i++) { ++ IToken token = tokens[i]; + if(token.getRepresentation().equals(rep)){ + return true; + } +@@ -628,8 +633,8 @@ + return pythonPathHelper.resolveModule(full, false); + } + +- public List getPythonPath(){ +- return new ArrayList(pythonPathHelper.pythonpath); ++ public List getPythonPath(){ ++ return new ArrayList(pythonPathHelper.pythonpath); + } + + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/ProjectModulesManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/ProjectModulesManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/ProjectModulesManager.java 2006-10-08 17:31:58.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/ProjectModulesManager.java 2006-11-05 20:59:42.000000000 +0100 +@@ -9,6 +9,7 @@ + import java.io.ObjectInputStream; + import java.util.ArrayList; + import java.util.HashSet; ++import java.util.Iterator; + import java.util.List; + import java.util.Set; + import java.util.SortedMap; +@@ -39,7 +40,7 @@ + /** + * @author Fabio Zadrozny + */ +-public class ProjectModulesManager extends ModulesManager implements IDeltaProcessor, IProjectModulesManager{ ++public class ProjectModulesManager extends ModulesManager implements IDeltaProcessor, IProjectModulesManager{ + + private static final long serialVersionUID = 1L; + +@@ -55,7 +56,7 @@ + /** + * Used to process deltas (in case we have the process killed for some reason) + */ +- private transient DeltaSaver deltaSaver; ++ private transient DeltaSaver deltaSaver; + + /** + * @see org.python.pydev.core.IProjectModulesManager#setProject(org.eclipse.core.resources.IProject, boolean) +@@ -63,11 +64,12 @@ + public void setProject(IProject project, boolean restoreDeltas){ + this.project = project; + this.nature = PythonNature.getPythonNature(project); +- this.deltaSaver = new DeltaSaver(this.nature.getCompletionsCacheDir(), "astdelta", new ICallback(){ ++ this.deltaSaver = new DeltaSaver(this.nature.getCompletionsCacheDir(), "astdelta", new ICallback(){ + +- public ModulesKey call(ObjectInputStream arg) { ++ public Object call(Object arg) { + try { +- return (ModulesKey) arg.readObject(); ++ ObjectInputStream arg1 = (ObjectInputStream)arg; ++ return (ModulesKey) arg1.readObject(); + } catch (Exception e) { + throw new RuntimeException(e); + } +@@ -85,6 +87,14 @@ + + + /** ++ * @see org.python.pydev.core.IDeltaProcessor#processUpdate(java.lang.Object) ++ */ ++ public void processUpdate(Object data) { ++ //updates are ignored because we always start with 'empty modules' (so, we don't actually generate them -- updates are treated as inserts). ++ throw new RuntimeException("Not impl"); ++ } ++ ++ /** + * @see org.python.pydev.core.IProjectModulesManager#processUpdate(org.python.pydev.core.ModulesKey) + */ + public void processUpdate(ModulesKey data) { +@@ -93,12 +103,28 @@ + } + + /** ++ * @see org.python.pydev.core.IDeltaProcessor#processDelete(java.lang.Object) ++ */ ++ public void processDelete(Object key) { ++ ModulesKey theKey = (ModulesKey)key; ++ processDelete(theKey); ++ } ++ ++ /** + * @see org.python.pydev.core.IProjectModulesManager#processDelete(org.python.pydev.core.ModulesKey) + */ + public void processDelete(ModulesKey key) { + super.doRemoveSingleModule(key); + } +- ++ ++ /** ++ * @see org.python.pydev.core.IDeltaProcessor#processInsert(java.lang.Object) ++ */ ++ public void processInsert(Object key) { ++ ModulesKey theKey = (ModulesKey)key; ++ processInsert(theKey); ++ } ++ + /** + * @see org.python.pydev.core.IProjectModulesManager#processInsert(org.python.pydev.core.ModulesKey) + */ +@@ -114,7 +140,6 @@ + nature.saveAstManager(); + } + +- @Override + public void doRemoveSingleModule(ModulesKey key) { + super.doRemoveSingleModule(key); + if(deltaSaver != null || !IN_TESTS){ //we don't want deltas in tests +@@ -125,7 +150,6 @@ + } + + +- @Override + public void doAddSingleModule(ModulesKey key, AbstractModule n) { + super.doAddSingleModule(key, n); + if(deltaSaver != null || !IN_TESTS){ //we don't want deltas in tests +@@ -164,7 +188,7 @@ + return nature; + } + +- public SystemModulesManager getSystemModulesManager(){ ++ public ISystemModulesManager getSystemModulesManager(){ + return getSystemModulesManager(null); + } + +@@ -190,16 +214,20 @@ + /** + * @see org.python.pydev.core.IProjectModulesManager#getAllModuleNames() + */ +- public Set getAllModuleNames() { +- Set s = new HashSet(); +- for (Object object : this.modulesKeys.keySet()) { ++ public Set getAllModuleNames() { ++ Set s = new HashSet(); ++ for (Iterator iter = this.modulesKeys.keySet().iterator(); iter.hasNext();) { ++ Object object = (Object) iter.next(); ++ + ModulesKey m = (ModulesKey) object; + s.add(m.name); + } + + ModulesManager[] managersInvolved = this.getManagersInvolved(true); + for (int i = 0; i < managersInvolved.length; i++) { +- for (Object object : managersInvolved[i].modulesKeys.keySet()) { ++ for (Iterator iter = managersInvolved[i].modulesKeys.keySet().iterator(); iter.hasNext();) { ++ Object object = (Object) iter.next(); ++ + ModulesKey m = (ModulesKey) object; + s.add(m.name); + } +@@ -210,9 +238,8 @@ + /** + * @return all the modules that start with some token (from this manager and others involved) + */ +- @Override +- public SortedMap getAllModulesStartingWith(String strStartingWith) { +- SortedMap ret = getAllDirectModulesStartingWith(strStartingWith); ++ public SortedMap getAllModulesStartingWith(String strStartingWith) { ++ SortedMap ret = getAllDirectModulesStartingWith(strStartingWith); + ModulesManager[] managersInvolved = this.getManagersInvolved(true); + for (int i = 0; i < managersInvolved.length; i++) { + ret.putAll(managersInvolved[i].getAllDirectModulesStartingWith(strStartingWith)); +@@ -241,7 +268,9 @@ + public IModule getModule(String name, IPythonNature nature, boolean checkSystemManager, boolean dontSearchInit) { + ModulesManager[] managersInvolved = this.getManagersInvolved(true); //only get the system manager here (to avoid recursion) + +- for (ModulesManager m : managersInvolved) { ++ for (int i = 0; i < managersInvolved.length; i++) { ++ ModulesManager m = managersInvolved[i]; ++ + IModule module; + if (m instanceof ProjectModulesManager) { + ProjectModulesManager pM = (ProjectModulesManager) m; +@@ -278,7 +307,8 @@ + */ + public String resolveModule(String full, boolean checkSystemManager) { + ModulesManager[] managersInvolved = this.getManagersInvolved(checkSystemManager); +- for (ModulesManager m : managersInvolved) { ++ for (int i = 0; i < managersInvolved.length; i++) { ++ ModulesManager m = managersInvolved[i]; + + String mod; + if (m instanceof ProjectModulesManager) { +@@ -349,7 +379,7 @@ + * @return the Managers that this project references or the ones that reference this project (depends on 'referenced') + */ + private ModulesManager[] getManagers(boolean checkSystemManager, boolean referenced) { +- ArrayList list = new ArrayList(); ++ ArrayList list = new ArrayList(); + SystemModulesManager systemModulesManager = getSystemModulesManager(null); + if(systemModulesManager == null){ + //may happen in initialization +@@ -387,7 +417,7 @@ + * @param list the list that will be filled with the managers + * @param projects the projects that should have the managers added + */ +- private void fillWithModulesManagers(ArrayList list, IProject[] projects) { ++ private void fillWithModulesManagers(ArrayList list, IProject[] projects) { + for (int i = 0; i < projects.length; i++) { + PythonNature nature = PythonNature.getPythonNature(projects[i]); + if(nature!=null){ +@@ -422,8 +452,8 @@ + /** + * @see org.python.pydev.core.IProjectModulesManager#getCompletePythonPath() + */ +- public List getCompletePythonPath(){ +- List l = new ArrayList(); ++ public List getCompletePythonPath(){ ++ List l = new ArrayList(); + l.addAll(this.pythonPathHelper.pythonpath); + ModulesManager[] managersInvolved = getManagersInvolved(true); + for (int i = 0; i < managersInvolved.length; i++) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/PyCodeCompletionVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/PyCodeCompletionVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/PyCodeCompletionVisitor.java 2006-01-24 19:24:06.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/PyCodeCompletionVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -25,7 +25,6 @@ + + public static final int PRIORITY_CODE_COMPLETION = PRIORITY_DEFAULT; + +- @Override + protected int getPriority() { + return PRIORITY_CODE_COMPLETION; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/PythonPathHelper.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/PythonPathHelper.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/PythonPathHelper.java 2006-10-30 17:27:10.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/PythonPathHelper.java 2006-11-05 20:59:42.000000000 +0100 +@@ -40,7 +40,7 @@ + /** + * This is a list of Files containg the pythonpath. + */ +- public List pythonpath = new ArrayList(); ++ public List pythonpath = new ArrayList(); + + /** + * Returns the default path given from the string. +@@ -63,7 +63,7 @@ + * @param monitor + * @return the files in position 0 and folders in position 1. + */ +- public List[] getModulesBelow(File root, IProgressMonitor monitor){ ++ public List[] getModulesBelow(File root, IProgressMonitor monitor){ + if(!root.exists()){ + return null; + } +@@ -93,18 +93,18 @@ + * @param monitor the monitor, to keep track of what is happening + * @return a list with the name of the found modules in the jar + */ +- public static List getFromJar(File root, IProgressMonitor monitor){ ++ public static List getFromJar(File root, IProgressMonitor monitor){ + String fileName = root.getName(); + if(root.isFile() && (fileName.endsWith(".jar") || fileName.endsWith(".zip"))){ //ok, it may be a jar file, so let's get its contents and get the available modules +- Set folders = new HashSet(); ++ Set folders = new HashSet(); + try { + String zipFileName = root.getName(); + ZipFile zipFile = new ZipFile(root); +- Enumeration entries = zipFile.entries(); ++ Enumeration entries = zipFile.entries(); + + //ok, now that we have the zip entries, let's map them to modules + while(entries.hasMoreElements()){ +- ZipEntry entry = entries.nextElement(); ++ ZipEntry entry = (ZipEntry) entries.nextElement(); + String name = entry.getName(); + if(!entry.isDirectory()){ + //it is a file... we will ignore them, as java files do not map to actual modules as python, but to classes. +@@ -128,7 +128,7 @@ + } + } + +- return new ArrayList(folders); ++ return new ArrayList(folders); + } catch (Exception e) { + //that's ok, it is probably not a zip file after all... + PydevPlugin.log(e); +@@ -171,7 +171,10 @@ + */ + public static boolean isValidSourceFile(String path) { + path = path.toLowerCase(); +- for(String end : getDottedValidSourceFiles()){ ++ String [] files = getDottedValidSourceFiles(); ++ for (int i = 0; i < files.length; i++) { ++ String end = files[i]; ++ + if(path.endsWith(end)){ + return true; + } +@@ -188,7 +191,10 @@ + return false; + } + ext = ext.toLowerCase(); +- for(String end : getValidSourceFiles()){ ++ String [] files = getValidSourceFiles(); ++ for (int i = 0; i < files.length; i++) { ++ String end = files[i]; ++ + if(ext.equals(end)){ + return true; + } +@@ -332,7 +338,9 @@ + if(requireFileToExist == false){ + //we have to remove the last part (.py, .pyc, .pyw) + fullPath = FullRepIterable.headAndTail(fullPath)[0]; +- for (String element : pythonpath) { ++ for (Iterator iter = pythonpath.iterator(); iter.hasNext();) { ++ String element = (String) iter.next(); ++ + element = getDefaultPathStr(element); + if(fullPath.startsWith(element)){ + String s = fullPath.substring(element.length()); +@@ -403,17 +411,17 @@ + * @param string with paths separated by | + * @return + */ +- public List setPythonPath(String string) { ++ public List setPythonPath(String string) { + pythonpath.clear(); + getPythonPathFromStr(string, pythonpath); +- return new ArrayList(pythonpath); ++ return new ArrayList(pythonpath); + } + + /** + * @param string this is the string that has the pythonpath (separated by |) + * @param lPath OUT: this list is filled with the pythonpath. + */ +- public void getPythonPathFromStr(String string, List lPath) { ++ public void getPythonPathFromStr(String string, List lPath) { + String[] strings = string.split("\\|"); + for (int i = 0; i < strings.length; i++) { + String defaultPathStr = getDefaultPathStr(strings[i]); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/SystemModulesManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/SystemModulesManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/SystemModulesManager.java 2006-05-16 16:02:47.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/SystemModulesManager.java 2006-11-05 20:59:42.000000000 +0100 +@@ -25,14 +25,14 @@ + /** + * @param forcedLibs + */ +- public SystemModulesManager(Collection forcedLibs) { ++ public SystemModulesManager(Collection forcedLibs) { + regenerateForcedBuilltins(forcedLibs); + } + + /** + * @see org.python.pydev.core.ISystemModulesManager#regenerateForcedBuilltins(java.util.Collection) + */ +- public void regenerateForcedBuilltins(Collection forcedLibs){ ++ public void regenerateForcedBuilltins(Collection forcedLibs){ + this.builtins = (String[]) forcedLibs.toArray(new String[0]); + } + +@@ -50,7 +50,7 @@ + /** + * @see org.python.pydev.core.ISystemModulesManager#setBuiltins(java.util.Collection) + */ +- public void setBuiltins(Collection forcedLibs) { ++ public void setBuiltins(Collection forcedLibs) { + regenerateForcedBuilltins(forcedLibs); + } + +@@ -75,8 +75,8 @@ + return super.resolveModule(full); + } + +- public List getCompletePythonPath() { +- return new ArrayList(super.getPythonPath()); ++ public List getCompletePythonPath() { ++ return new ArrayList(super.getPythonPath()); + } + + public IModule getRelativeModule(String name, IPythonNature nature) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/AbstractVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/AbstractVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/AbstractVisitor.java 2006-05-02 14:24:25.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/AbstractVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -6,6 +6,7 @@ + package org.python.pydev.editor.codecompletion.revisited.visitors; + + import java.util.ArrayList; ++import java.util.Iterator; + import java.util.List; + + import org.python.pydev.core.FullRepIterable; +@@ -38,7 +39,7 @@ + + public static final int INNER_DEFS = 5; + +- protected List tokens = new ArrayList(); ++ protected List tokens = new ArrayList(); + + /** + * Module being visited. +@@ -82,9 +83,9 @@ + * + * @return the tokens list passed in or the created one if it was null + */ +- public static IToken makeWildImportToken(ImportFrom node, List tokens, String moduleName) { ++ public static IToken makeWildImportToken(ImportFrom node, List tokens, String moduleName) { + if(tokens == null){ +- tokens = new ArrayList(); ++ tokens = new ArrayList(); + } + SourceToken sourceToken = null; + if(isWildImport(node)){ +@@ -94,7 +95,7 @@ + return sourceToken; + } + +- public static List makeImportToken(SimpleNode node, List tokens, String moduleName, boolean allowForMultiple) { ++ public static List makeImportToken(SimpleNode node, List tokens, String moduleName, boolean allowForMultiple) { + if(node instanceof Import){ + return makeImportToken((Import)node, tokens, moduleName, allowForMultiple); + } +@@ -121,7 +122,7 @@ + * + * @return the tokens list passed in or the created one if it was null + */ +- public static List makeImportToken(Import node, List tokens, String moduleName, boolean allowForMultiple) { ++ public static List makeImportToken(Import node, List tokens, String moduleName, boolean allowForMultiple) { + aliasType[] names = node.names; + return makeImportToken(node, tokens, names, moduleName, "", allowForMultiple); + } +@@ -129,7 +130,7 @@ + /** + * The same as above but with ImportFrom + */ +- public static List makeImportToken(ImportFrom node, List tokens, String moduleName, boolean allowForMultiple) { ++ public static List makeImportToken(ImportFrom node, List tokens, String moduleName, boolean allowForMultiple) { + aliasType[] names = node.names; + String importName = ((NameTok)node.module).id; + +@@ -139,9 +140,9 @@ + /** + * The same as above + */ +- private static List makeImportToken(SimpleNode node, List tokens, aliasType[] names, String module, String initialImportName, boolean allowForMultiple) { ++ private static List makeImportToken(SimpleNode node, List tokens, aliasType[] names, String module, String initialImportName, boolean allowForMultiple) { + if(tokens == null){ +- tokens = new ArrayList(); ++ tokens = new ArrayList(); + } + + if(initialImportName.length() > 0){ +@@ -160,7 +161,8 @@ + + if(name == null){ + FullRepIterable iterator = new FullRepIterable(original); +- for (String rep : iterator) { ++ for (Iterator iter = iterator.iterator(); iter.hasNext();) { ++ String rep = (String) iter.next(); + SourceToken sourceToken = new SourceToken(node, rep, "", "", module, initialImportName+rep); + tokens.add(sourceToken); + } +@@ -206,7 +208,7 @@ + return node.names.length > 0; + } + +- public List getTokens() { ++ public List getTokens() { + return this.tokens; + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/Definition.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/Definition.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/Definition.java 2006-09-23 23:22:50.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/Definition.java 2006-11-05 20:59:42.000000000 +0100 +@@ -142,7 +142,6 @@ + return true; + } + +- @Override + public int hashCode() { + return value.hashCode() + col + line; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/FindDefinitionModelVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/FindDefinitionModelVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/FindDefinitionModelVisitor.java 2006-09-23 23:22:50.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/FindDefinitionModelVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -34,12 +34,12 @@ + /** + * List of definitions. + */ +- public List definitions = new ArrayList(); ++ public List definitions = new ArrayList(); + + /** + * Stack of classes / methods to get to a definition. + */ +- private FastStack defsStack = new FastStack(); ++ private FastStack defsStack = new FastStack(); + + /** + * This is the module we are visiting +@@ -70,7 +70,6 @@ + this.moduleName = module.getName(); + } + +- @Override + public Object visitImportFrom(ImportFrom node) throws Exception { + String modRep = NodeUtils.getRepresentationString(node.module); + if( NodeUtils.isWithin(line, col, node.module) ){ +@@ -93,7 +92,10 @@ + moduleImported += modRep.substring(lastChar, i); + }else{ + //it was not the module, so, we have to check for each name alias imported +- for (aliasType alias: node.names){ ++ ++ for (int i = 0; i < node.names.length; i++) { ++ aliasType alias = node.names[i]; ++ + //we do not check the 'as' because if it is some 'as', it will be gotten as a global in the module + if( NodeUtils.isWithin(line, col, alias.name) ){ + moduleImported = modRep + "." + +@@ -150,8 +152,8 @@ + foundAsDefinition = true; + // if it is found as a definition it is an 'exact' match, so, erase all the others. + ILocalScope scope = new LocalScope(this.defsStack); +- for (Iterator it = definitions.iterator(); it.hasNext();) { +- Definition d = it.next(); ++ for (Iterator it = definitions.iterator(); it.hasNext();) { ++ Definition d = (Definition) it.next(); + if(!d.scope.equals(scope)){ + it.remove(); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/FindScopeVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/FindScopeVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/FindScopeVisitor.java 2006-09-23 23:22:50.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/FindScopeVisitor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -21,12 +21,12 @@ + /** + * Stack of classes / methods representing the scope. + */ +- protected FastStack stackScope = new FastStack(); ++ protected FastStack stackScope = new FastStack(); + + /** + * This is the scope. + */ +- public LocalScope scope = new LocalScope(new FastStack()); ++ public LocalScope scope = new LocalScope(new FastStack()); + + /** + * Variable to mark if we found scope. +@@ -71,7 +71,7 @@ + //scope is locked at this time. + found = true; + int original = scope.ifMainLine; +- scope = new LocalScope((FastStack) this.stackScope.clone()); ++ scope = new LocalScope((FastStack) this.stackScope.clone()); + scope.ifMainLine = original; + } + }else{ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/HeuristicFindAttrs.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/HeuristicFindAttrs.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/HeuristicFindAttrs.java 2006-06-29 14:15:34.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/HeuristicFindAttrs.java 2006-11-05 20:59:42.000000000 +0100 +@@ -158,7 +158,8 @@ + }else if(node.targets[i] instanceof Tuple && inFuncDef == false){ + //that's for finding the definition: a,b,c = range(3) inside a class definition + Tuple tuple = (Tuple) node.targets[i]; +- for(exprType t :tuple.elts){ ++ for (int j = 0; j < tuple.elts.length; j++) { ++ exprType t = tuple.elts[j]; + if(t instanceof Name){ + String id = ((Name)t).id; + if(id != null){ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/LocalScope.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/LocalScope.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/LocalScope.java 2006-09-23 23:22:50.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/revisited/visitors/LocalScope.java 2006-11-05 20:59:42.000000000 +0100 +@@ -30,13 +30,13 @@ + */ + public class LocalScope implements ILocalScope { + +- public FastStack scope = new FastStack(); ++ public FastStack scope = new FastStack(); + + public int scopeEndLine = -1; + + public int ifMainLine = -1; + +- public LocalScope(FastStack scope){ ++ public LocalScope(FastStack scope){ + this.scope.addAll(scope); + } + +@@ -112,7 +112,7 @@ + * @see org.python.pydev.core.ILocalScope#getLocalTokens(int, int, boolean) + */ + public IToken[] getLocalTokens(int endLine, int col, boolean onlyArgs){ +- Set comps = new HashSet(); ++ Set comps = new HashSet(); + + for (Iterator iter = this.scope.iterator(); iter.hasNext();) { + SimpleNode element = (SimpleNode) iter.next(); +@@ -162,7 +162,7 @@ + * @return a list of tokens for the local + */ + public IToken[] getInterfaceForLocal(String argName, String activationToken) { +- Set comps = new HashSet(); ++ Set comps = new HashSet(); + + for (Iterator iter = this.scope.iterator(); iter.hasNext();) { + SimpleNode element = (SimpleNode) iter.next(); +@@ -175,10 +175,10 @@ + String dottedActTok = activationToken+'.'; + //ok, that's the scope we have to analyze + SequencialASTIteratorVisitor visitor = SequencialASTIteratorVisitor.create(f); +- Iterator iterator = visitor.getIterator(Attribute.class); ++ Iterator iterator = visitor.getIterator(Attribute.class); + + while(iterator.hasNext()){ +- ASTEntry entry = iterator.next(); ++ ASTEntry entry = (ASTEntry) iterator.next(); + String rep = NodeUtils.getFullRepresentationString(entry.node); + if(rep.startsWith(dottedActTok)){ + rep = rep.substring(dottedActTok.length()); +@@ -196,8 +196,8 @@ + /** + * @see org.python.pydev.core.ILocalScope#getLocalImportedModules(int, int, java.lang.String) + */ +- public List getLocalImportedModules(int line, int col, String moduleName) { +- ArrayList importedModules = new ArrayList(); ++ public List getLocalImportedModules(int line, int col, String moduleName) { ++ ArrayList importedModules = new ArrayList(); + for (Iterator iter = this.scope.iterator(); iter.hasNext();) { + SimpleNode element = (SimpleNode) iter.next(); + +@@ -206,7 +206,8 @@ + for (int i = 0; i < f.body.length; i++) { + + IToken[] tokens = GlobalModelVisitor.getTokens(f.body[i], GlobalModelVisitor.ALIAS_MODULES, moduleName); +- for (IToken token : tokens) { ++ for (int j = 0; j < tokens.length; j++) { ++ IToken token = tokens[j]; + importedModules.add(token); + } + } +@@ -219,7 +220,8 @@ + * @see org.python.pydev.core.ILocalScope#getClassDef() + */ + public ClassDef getClassDef() { +- for(SimpleNode node : this.scope){ ++ for (Iterator i = this.scope.iterator(); i.hasNext(); ) { ++ SimpleNode node = (SimpleNode) i.next(); + if(node instanceof ClassDef){ + return (ClassDef) node; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/AbstractShell.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/AbstractShell.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/AbstractShell.java 2006-09-26 02:54:21.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/AbstractShell.java 2006-11-05 20:59:42.000000000 +0100 +@@ -97,7 +97,7 @@ + * @see #COMPLETION_SHELL + * @see #OTHERS_SHELL + */ +- protected static Map> shells = new HashMap>(); ++ protected static Map shells = new HashMap(); + + /** + * if we are already finished for good, we may not start new shells (this is a static, because this +@@ -109,7 +109,7 @@ + * simple stop of a shell (it may be later restarted) + */ + public synchronized static void stopServerShell(int relatedId, int id) { +- Map typeToShell = getTypeToShellFromId(relatedId); ++ Map typeToShell = getTypeToShellFromId(relatedId); + AbstractShell pythonShell = (AbstractShell) typeToShell.get(new Integer(id)); + + if(pythonShell != null){ +@@ -128,10 +128,10 @@ + */ + public synchronized static void shutdownAllShells(){ + synchronized(shells){ +- for (Iterator> iter = shells.values().iterator(); iter.hasNext();) { ++ for (Iterator iter = shells.values().iterator(); iter.hasNext();) { + finishedForGood = true; //we may no longer restart shells + +- Map rel = (Map) iter.next(); ++ Map rel = (Map) iter.next(); + if(rel != null){ + for (Iterator iter2 = rel.values().iterator(); iter2.hasNext();) { + AbstractShell element = (AbstractShell) iter2.next(); +@@ -153,13 +153,13 @@ + * @param relatedId the id that is related to the structure we want to get + * @return a map with the type of the shell mapping to the shell itself + */ +- private synchronized static Map getTypeToShellFromId(int relatedId) { ++ private synchronized static Map getTypeToShellFromId(int relatedId) { + synchronized(shells){ +- Map typeToShell = shells.get(relatedId); ++ Map typeToShell = (Map) shells.get(new Integer(relatedId)); + + if (typeToShell == null) { +- typeToShell = new HashMap(); +- shells.put(relatedId, typeToShell); ++ typeToShell = new HashMap(); ++ shells.put(new Integer(relatedId), typeToShell); + } + return typeToShell; + } +@@ -178,7 +178,7 @@ + */ + public synchronized static void putServerShell(IPythonNature nature, int id, AbstractShell shell) { + try { +- Map typeToShell = getTypeToShellFromId(nature.getRelatedId()); ++ Map typeToShell = getTypeToShellFromId(nature.getRelatedId()); + typeToShell.put(new Integer(id), shell); + } catch (Exception e) { + throw new RuntimeException(e); +@@ -211,7 +211,7 @@ + if(PyCodeCompletion.DEBUG_CODE_COMPLETION){ + Log.toLogFile( "Getting shell relatedId:"+relatedId+" id:"+id, AbstractShell.class); + } +- Map typeToShell = getTypeToShellFromId(relatedId); ++ Map typeToShell = getTypeToShellFromId(relatedId); + pythonShell = (AbstractShell) typeToShell.get(new Integer(id)); + + if(pythonShell == null){ +@@ -732,7 +732,7 @@ + * @return list with tuples: new String[]{token, description} + * @throws CoreException + */ +- public synchronized Tuple> getImportCompletions(String str, List pythonpath) throws CoreException { ++ public synchronized Tuple getImportCompletions(String str, List pythonpath) throws CoreException { + while(isInOperation){ + sleepALittle(100); + } +@@ -788,7 +788,7 @@ + } + } + +- protected synchronized Tuple> getTheCompletions(String str) throws CoreException { ++ protected synchronized Tuple getTheCompletions(String str) throws CoreException { + try { + this.write(str); + +@@ -838,16 +838,16 @@ + /** + * @return + */ +- protected synchronized Tuple> getInvalidCompletion() { +- List l = new ArrayList(); +- return new Tuple>(null, l); ++ protected synchronized Tuple getInvalidCompletion() { ++ List l = new ArrayList(); ++ return new Tuple(null, l); + } + + /** + * @throws IOException + */ +- protected synchronized Tuple> getCompletions() throws IOException { +- ArrayList list = new ArrayList(); ++ protected synchronized Tuple getCompletions() throws IOException { ++ ArrayList list = new ArrayList(); + String string = this.read().replaceAll("\\(","").replaceAll("\\)",""); + StringTokenizer tokenizer = new StringTokenizer(string, ","); + +@@ -858,7 +858,7 @@ + while(tokenizer.hasMoreTokens()){ + String token = URLDecoder.decode(tokenizer.nextToken(), ENCODING_UTF_8); + if(!tokenizer.hasMoreTokens()){ +- return new Tuple>(file, list); ++ return new Tuple(file, list); + } + String description = URLDecoder.decode(tokenizer.nextToken(), ENCODING_UTF_8); + +@@ -878,7 +878,7 @@ + } + } + } +- return new Tuple>(file, list); ++ return new Tuple(file, list); + } + + +@@ -887,7 +887,7 @@ + * @param token the token we are looking for + * @return the file where the token was defined, its line and its column (or null if it was not found) + */ +- public synchronized Tuple getLineCol(String moduleName, String token, List pythonpath) { ++ public synchronized Tuple getLineCol(String moduleName, String token, List pythonpath) { + while(isInOperation){ + sleepALittle(100); + } +@@ -898,14 +898,14 @@ + + try { + str = URLEncoder.encode(str, ENCODING_UTF_8); +- Tuple> theCompletions = this.getTheCompletions("@@SEARCH" + str + "\nEND@@"); ++ Tuple theCompletions = this.getTheCompletions("@@SEARCH" + str + "\nEND@@"); + +- List def = theCompletions.o2; ++ List def = (List) theCompletions.o2; + if(def.size() == 0){ + return null; + } + +- String[] comps = def.get(0); ++ String[] comps = (String[]) def.get(0); + if(comps.length == 0){ + return null; + } +@@ -914,8 +914,8 @@ + int col = Integer.parseInt(comps[1]); + + String foundAs = comps[2]; +- return new Tuple( +- new String[]{theCompletions.o1, foundAs}, ++ return new Tuple( ++ new String[]{(String) theCompletions.o1, foundAs}, + new int[]{line, col}); + + } catch (Exception e) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/JythonShell.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/JythonShell.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/JythonShell.java 2006-01-08 13:04:55.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/JythonShell.java 2006-11-05 20:59:42.000000000 +0100 +@@ -18,7 +18,6 @@ + } + + +- @Override + protected synchronized String createServerProcess(int pWrite, int pRead) throws IOException { + String args = pWrite+" "+pRead; + String script = REF.getFileAbsolutePath(serverFile); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/PythonShell.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/PythonShell.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/PythonShell.java 2005-10-13 14:04:11.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codecompletion/shell/PythonShell.java 2006-11-05 20:59:42.000000000 +0100 +@@ -31,7 +31,6 @@ + } + + +- @Override + protected synchronized String createServerProcess(int pWrite, int pRead) throws IOException { + String interpreter = PydevPlugin.getPythonInterpreterManager().getDefaultInterpreter(); + File file = new File(interpreter); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codefolding/PySourceViewer.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codefolding/PySourceViewer.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/codefolding/PySourceViewer.java 2006-07-14 03:48:35.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/codefolding/PySourceViewer.java 2006-11-05 20:59:42.000000000 +0100 +@@ -25,6 +25,7 @@ + + + public class PySourceViewer extends ProjectionViewer { ++ + + private PyEditProjection projection; + private PyCorrectionAssistant fCorrectionAssistant; +@@ -46,6 +47,10 @@ + } + + ++ public interface Iterable { ++ public Iterator iterator(); ++ } ++ + public void configure(SourceViewerConfiguration configuration) { + super.configure(configuration); + if (configuration instanceof PyEditConfiguration) { +@@ -67,11 +72,13 @@ + * @param markerType the type of the marker (if null, it is not used) + * @return a list of markers at the given line + */ +- public List getMarkersAtLine(int markerLine, String markerType){ +- ArrayList markers = new ArrayList(); ++ public List getMarkersAtLine(int markerLine, String markerType){ ++ ArrayList markers = new ArrayList(); + +- Iterable markerIteratable = getMarkerIteratable(); +- for (IMarker marker : markerIteratable) { ++ Iterable markerIteratable = getMarkerIteratable(); ++ for (Iterator iter = markerIteratable.iterator(); iter.hasNext();) { ++ IMarker marker = (IMarker) iter.next(); ++ + try { + //check the line + Integer line = (Integer) marker.getAttribute(IMarker.LINE_NUMBER); +@@ -93,7 +100,7 @@ + /** + * @return a class that iterates through the markers available in this source viewer + */ +- public Iterable getMarkerIteratable(){ ++ public Iterable getMarkerIteratable(){ + final IAnnotationModel annotationModel = getAnnotationModel(); + //it may be null on external files, because I simply cannot make it get the org.python.copiedfromeclipsesrc.PydevFileEditorInput + //(if it did, I could enhance it...). Instead, it returns a org.eclipse.ui.internal.editors.text.JavaFileEditorInput +@@ -101,10 +108,10 @@ + if(annotationModel != null){ + final Iterator annotationIterator = annotationModel.getAnnotationIterator(); + +- return new Iterable(){ ++ return new Iterable(){ + +- public Iterator iterator() { +- return new Iterator(){ ++ public Iterator iterator() { ++ return new Iterator(){ + + private IMarker marker; + +@@ -126,7 +133,7 @@ + return false; + } + +- public IMarker next() { ++ public Object next() { + hasNext(); + + IMarker m = marker; +@@ -143,15 +150,15 @@ + + }; + } +- return new Iterable(){ ++ return new Iterable(){ + +- public Iterator iterator() { +- return new Iterator(){ ++ public Iterator iterator() { ++ return new Iterator(){ + public boolean hasNext() { + return false; + } + +- public IMarker next() { ++ public Object next() { + return null; + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistAssignCompletionProposal.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistAssignCompletionProposal.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistAssignCompletionProposal.java 2006-06-26 14:26:50.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistAssignCompletionProposal.java 2006-11-05 20:59:42.000000000 +0100 +@@ -24,7 +24,6 @@ + this.pyEdit = edit; + } + +- @Override + public void apply(IDocument document) { + try { + //default apply +@@ -63,7 +62,6 @@ + } + } + +- @Override + public Point getSelection(IDocument document) { + return null; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistAssign.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistAssign.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistAssign.java 2006-09-19 01:43:25.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistAssign.java 2006-11-05 20:59:42.000000000 +0100 +@@ -35,8 +35,8 @@ + /** + * @see org.python.pydev.editor.correctionassist.heuristics.IAssistProps#getProps(org.python.pydev.core.docutils.PySelection, org.python.pydev.core.bundle.ImageCache, java.io.File, org.python.pydev.plugin.PythonNature) + */ +- public List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException { +- List l = new ArrayList(); ++ public List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException { ++ List l = new ArrayList(); + String sel = PyAction.getLineWithoutComments(ps); + if (sel.trim().length() == 0) { + return l; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistDocString.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistDocString.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistDocString.java 2006-04-29 20:43:01.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistDocString.java 2006-11-05 20:59:42.000000000 +0100 +@@ -30,13 +30,13 @@ + /** + * @see org.python.pydev.editor.correctionassist.heuristics.IAssistProps#getProps(org.python.pydev.core.docutils.PySelection, org.python.pydev.core.bundle.ImageCache) + */ +- public List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException { +- ArrayList l = new ArrayList(); +- Tuple, Integer> tuple = ps.getInsideParentesisToks(false); ++ public List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException { ++ ArrayList l = new ArrayList(); ++ Tuple tuple = ps.getInsideParentesisToks(false); + if(tuple == null){ +- tuple = new Tuple, Integer>(new ArrayList(), offset); ++ tuple = new Tuple(new ArrayList(), new Integer(offset)); + } +- List params = tuple.o1; ++ List params = (List) tuple.o1; + + String initial = PySelection.getIndentationFromLine(ps.getCursorLineContents()); + String delimiter = PyAction.getDelimiter(ps.getDoc()); +@@ -59,7 +59,7 @@ + buf.append(inAndIndent+"'''"); + buf.append(inAndIndent); + +- int lineOfOffset = ps.getLineOfOffset(tuple.o2); ++ int lineOfOffset = ps.getLineOfOffset(((Integer)tuple.o2).intValue()); + String comp = buf.toString(); + int offsetPosToAdd = ps.getEndLineOffset(lineOfOffset); + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistImport.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistImport.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistImport.java 2006-04-06 17:58:51.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistImport.java 2006-11-05 20:59:42.000000000 +0100 +@@ -27,8 +27,8 @@ + /** + * @see org.python.pydev.editor.correctionassist.heuristics.IAssistProps#getProps(org.python.pydev.core.docutils.PySelection, org.python.pydev.core.bundle.ImageCache) + */ +- public List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offsetReceived) throws BadLocationException { +- ArrayList l = new ArrayList(); ++ public List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offsetReceived) throws BadLocationException { ++ ArrayList l = new ArrayList(); + String sel = PyAction.getLineWithoutComments(ps).trim(); + + int i = sel.indexOf("import"); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistOverride.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistOverride.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistOverride.java 2006-09-24 03:03:16.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistOverride.java 2006-11-05 20:59:42.000000000 +0100 +@@ -32,8 +32,8 @@ + /** + * @see org.python.pydev.editor.correctionassist.heuristics.IAssistProps#getProps(org.python.pydev.core.docutils.PySelection, org.python.pydev.core.bundle.ImageCache) + */ +- public List getProps(PySelection ps, ImageCache imageCache, File file, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException { +- ArrayList l = new ArrayList(); ++ public List getProps(PySelection ps, ImageCache imageCache, File file, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException { ++ ArrayList l = new ArrayList(); + String sel = PyAction.getLineWithoutComments(ps); + String indentation = PyAction.getStaticIndentationString(edit); + String delimiter = PyAction.getDelimiter(ps.getDoc()); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistTry.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistTry.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistTry.java 2006-04-29 20:43:01.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/AssistTry.java 2006-11-05 20:59:42.000000000 +0100 +@@ -29,9 +29,9 @@ + * @throws BadLocationException + * @see org.python.pydev.editor.correctionassist.heuristics.IAssistProps#getProps(org.python.pydev.core.docutils.PySelection, org.python.pydev.core.bundle.ImageCache) + */ +- public List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException { ++ public List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException { + +- ArrayList l = new ArrayList(); ++ ArrayList l = new ArrayList(); + String indentation = PyAction.getStaticIndentationString(edit); + + int start = ps.getStartLine().getOffset(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/IAssistProps.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/IAssistProps.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/IAssistProps.java 2006-04-06 17:58:51.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/heuristics/IAssistProps.java 2006-11-05 20:59:42.000000000 +0100 +@@ -33,7 +33,7 @@ + * @return a list of completions with proposals to fix things + * @throws BadLocationException + */ +- List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException; ++ List getProps(PySelection ps, ImageCache imageCache, File f, IPythonNature nature, PyEdit edit, int offset) throws BadLocationException; + + /** + * Gets wether this assist proposal is valid to be applied at the current line +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/PythonCorrectionProcessor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/PythonCorrectionProcessor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/correctionassist/PythonCorrectionProcessor.java 2006-06-01 19:45:01.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/correctionassist/PythonCorrectionProcessor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -8,6 +8,7 @@ + import java.util.ArrayList; + import java.util.Collections; + import java.util.HashMap; ++import java.util.Iterator; + import java.util.List; + import java.util.Map; + +@@ -72,7 +73,7 @@ + + private PyEdit edit; + private ImageCache imageCache; +- private static Map additionalAssists = new HashMap(); ++ private static Map additionalAssists = new HashMap(); + + public static boolean hasAdditionalAssist(String id){ + synchronized (additionalAssists) { +@@ -108,13 +109,15 @@ + + PySelection ps = new PySelection(edit); + +- List results = new ArrayList(); ++ List results = new ArrayList(); + String sel = PyAction.getLineWithoutComments(ps); + + +- List assists = new ArrayList(); ++ List assists = new ArrayList(); + synchronized (this.additionalAssists) { +- for (IAssistProps prop : additionalAssists.values()) { ++ for (Iterator iter = additionalAssists.values().iterator(); iter.hasNext();) { ++ IAssistProps prop = (IAssistProps) iter.next(); ++ + assists.add(prop); + } + } +@@ -126,7 +129,9 @@ + + assists.addAll(ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_CTRL_1)); + +- for (IAssistProps assist : assists) { ++ for (Iterator iter = assists.iterator(); iter.hasNext();) { ++ IAssistProps assist = (IAssistProps) iter.next(); ++ + try { + if (assist.isValid(ps, sel, edit, offset)) { + try { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/hover/PyAnnotationHover.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/hover/PyAnnotationHover.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/hover/PyAnnotationHover.java 2005-08-02 19:24:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/hover/PyAnnotationHover.java 2006-11-05 20:59:42.000000000 +0100 +@@ -6,6 +6,8 @@ + */ + package org.python.pydev.editor.hover; + ++import java.util.Iterator; ++ + import org.eclipse.core.resources.IMarker; + import org.eclipse.core.runtime.CoreException; + import org.eclipse.jface.text.source.IAnnotationHover; +@@ -23,11 +25,13 @@ + + if(sourceViewer instanceof PySourceViewer){ + PySourceViewer s = (PySourceViewer) sourceViewer; +- for(IMarker marker : s.getMarkerIteratable()){ ++ for (Iterator iter = s.getMarkerIteratable().iterator(); iter.hasNext();) { ++ IMarker marker = (IMarker) iter.next(); ++ + try { + Integer line = (Integer) marker.getAttribute(IMarker.LINE_NUMBER); + if(line != null){ +- if(line == lineNumber){ ++ if(line.intValue() == lineNumber){ + if(buf.length() >0){ + buf.append("\n"); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/hover/PyTextHover.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/hover/PyTextHover.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/hover/PyTextHover.java 2006-05-26 13:26:30.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/hover/PyTextHover.java 2006-11-05 20:59:42.000000000 +0100 +@@ -6,6 +6,8 @@ + */ + package org.python.pydev.editor.hover; + ++import java.util.Iterator; ++ + import org.eclipse.core.resources.IMarker; + import org.eclipse.core.runtime.CoreException; + import org.eclipse.jface.text.IRegion; +@@ -23,8 +25,9 @@ + + public PyTextHover(ISourceViewer sourceViewer, String contentType) { + pythonCommentOrMultiline = false; +- +- for(String type : IPythonPartitions.types){ ++ for (int i = 0; i < IPythonPartitions.types.length; i++) { ++ String type = IPythonPartitions.types[i]; ++ + if(type.equals(contentType)){ + pythonCommentOrMultiline = true; + } +@@ -37,13 +40,15 @@ + if(textViewer instanceof PySourceViewer){ + PySourceViewer s = (PySourceViewer) textViewer; + +- for(IMarker marker : s.getMarkerIteratable()){ ++ for (Iterator iter = s.getMarkerIteratable().iterator(); iter.hasNext();) { ++ IMarker marker = (IMarker) iter.next(); ++ + try { + Integer cStart = (Integer) marker.getAttribute(IMarker.CHAR_START); + Integer cEnd = (Integer) marker.getAttribute(IMarker.CHAR_END); + if(cStart != null && cEnd != null){ + int offset = hoverRegion.getOffset(); +- if(cStart <= offset && cEnd >= offset){ ++ if(cStart.intValue() <= offset && cEnd.intValue() >= offset){ + if(buf.length() >0){ + buf.append("\n"); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/model/ItemPointer.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/model/ItemPointer.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/model/ItemPointer.java 2006-10-09 23:43:17.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/model/ItemPointer.java 2006-11-05 20:59:42.000000000 +0100 +@@ -47,7 +47,6 @@ + this.definition = definition; + } + +- @Override + public String toString() { + StringBuffer buffer = new StringBuffer("ItemPointer ["); + buffer.append(file); +@@ -59,7 +58,6 @@ + return buffer.toString(); + } + +- @Override + public boolean equals(Object obj) { + if(!(obj instanceof ItemPointer)){ + return false; +@@ -79,7 +77,6 @@ + return true; + } + +- @Override + public int hashCode() { + if(this.file != null){ + return this.file.hashCode() * 17; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/model/Location.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/model/Location.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/model/Location.java 2006-01-15 12:41:14.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/model/Location.java 2006-11-05 20:59:42.000000000 +0100 +@@ -66,7 +66,6 @@ + return 0; + } + +- @Override + public boolean equals(Object obj) { + if(!(obj instanceof Location)){ + return false; +@@ -75,7 +74,6 @@ + return l.line == line && l.column == column; + } + +- @Override + public int hashCode() { + return (line * 99) + (column * 5); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/PyCodeScanner.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/PyCodeScanner.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/PyCodeScanner.java 2006-09-14 03:15:46.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/PyCodeScanner.java 2006-11-05 20:59:42.000000000 +0100 +@@ -174,7 +174,7 @@ + funcNameToken = new Token( new TextAttribute(colorCache.getNamedColor(PydevPrefs.FUNC_NAME_COLOR), null, preferences.getInt(PydevPrefs.FUNC_NAME_STYLE))); + + setDefaultReturnToken(defaultToken); +- List rules = new ArrayList(); ++ List rules = new ArrayList(); + + // Scanning strategy: + // 1) whitespace +@@ -183,12 +183,13 @@ + + rules.add(new WhitespaceRule(new GreatWhite())); + +- Map defaults = new HashMap(); ++ Map defaults = new HashMap(); + defaults.put("self", selfToken); + + PyWordRule wordRule = new PyWordRule(new GreatKeywordDetector(), defaultToken, classNameToken, funcNameToken); +- for (String keyword : KEYWORDS) { +- IToken token = defaults.get(keyword); ++ for (int i = 0; i < KEYWORDS.length; i++) { ++ String keyword = KEYWORDS[i]; ++ IToken token = (IToken) defaults.get(keyword); + if(token == null){ + token = keywordToken; + } +@@ -200,6 +201,6 @@ + rules.add(new WordRule(new DecoratorDetector(), decoratorToken)); + rules.add(new WordRule(new NumberDetector(), numberToken)); + +- setRules(rules.toArray(new IRule[0])); ++ setRules((IRule[]) rules.toArray(new IRule[0])); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/PyEditConfiguration.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/PyEditConfiguration.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/PyEditConfiguration.java 2006-07-16 21:04:14.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/PyEditConfiguration.java 2006-11-05 20:59:42.000000000 +0100 +@@ -77,12 +77,10 @@ + } + + +- @Override + public IAnnotationHover getAnnotationHover(ISourceViewer sourceViewer) { + return new PyAnnotationHover(sourceViewer); + } + +- @Override + public ITextHover getTextHover(ISourceViewer sourceViewer, String contentType) { + return new PyTextHover(sourceViewer, contentType); + } +@@ -98,7 +96,6 @@ + IPythonPartitions.PY_MULTILINE_STRING1, IPythonPartitions.PY_MULTILINE_STRING2 }; + } + +- @Override + public String getConfiguredDocumentPartitioning(ISourceViewer sourceViewer) { + return IPythonPartitions.PYTHON_PARTITION_TYPE; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/PyEdit.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/PyEdit.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/PyEdit.java 2006-10-23 23:53:08.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/PyEdit.java 2006-11-05 20:59:42.000000000 +0100 +@@ -4,6 +4,7 @@ + import java.util.ArrayList; + import java.util.Collection; + import java.util.HashMap; ++import java.util.Iterator; + import java.util.List; + import java.util.ListResourceBundle; + import java.util.Map; +@@ -140,18 +141,18 @@ + Hyperlink fMouseListener; + + /** listeners that get notified of model changes */ +- List modelListeners; ++ List modelListeners; + + // ---------------------------- listeners stuff + /** + * Those are the ones that register with the PYDEV_PYEDIT_LISTENER extension point + */ +- private static List editListeners; ++ private static List editListeners; + + /** + * Those are the ones that register at runtime (not throught extensions points). + */ +- private List registeredEditListeners = new ArrayList(); ++ private List registeredEditListeners = new ArrayList(); + + /** + * This is the scripting engine that is binded to this interpreter. +@@ -173,13 +174,14 @@ + + + +- @Override + protected void handleCursorPositionChanged() { + super.handleCursorPositionChanged(); + if(!initFinished){ + return; + } +- for(IPyEditListener listener : getAllListeners()){ ++ for (Iterator iter = getAllListeners().iterator(); iter.hasNext();) { ++ IPyEditListener listener = (IPyEditListener) iter.next(); ++ + try { + if(listener instanceof IPyEditListener2){ + ((IPyEditListener2)listener).handleCursorPositionChanged(this); +@@ -191,7 +193,7 @@ + } + } + +- public List getAllListeners() { ++ public List getAllListeners() { + while (initFinished == false){ + synchronized(getLock()){ + try { +@@ -202,7 +204,7 @@ + } + } + } +- ArrayList listeners = new ArrayList(); ++ ArrayList listeners = new ArrayList(); + if(editListeners != null){ + listeners.addAll(editListeners); + } +@@ -224,7 +226,7 @@ + * + * The suggestion is that the cache key is always preceded by the class name that will use it. + */ +- public Map cache = new HashMap(); ++ public Map cache = new HashMap(); + + /** + * Indicates whether the init was already finished +@@ -240,7 +242,6 @@ + + // ---------------------------- end listeners stuff + +- @SuppressWarnings("unchecked") + public PyEdit() { + super(); + +@@ -249,7 +250,7 @@ + editListeners = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_PYEDIT_LISTENER); + } + +- modelListeners = new ArrayList(); ++ modelListeners = new ArrayList(); + colorCache = new ColorCache(PydevPlugin.getChainedPrefStore()); + + editConfiguration = new PyEditConfiguration(colorCache, this); +@@ -463,7 +464,6 @@ + * + * @see org.eclipse.ui.texteditor.AbstractTextEditor#doSetInput(org.eclipse.ui.IEditorInput) + */ +- @Override + protected void doSetInput(IEditorInput input) throws CoreException { + super.doSetInput(input); + IDocument document = getDocument(input); +@@ -934,7 +934,7 @@ + message = message.replaceAll("\\r", " "); + message = message.replaceAll("\\n", " "); + } +- Map map = new HashMap(); ++ Map map = new HashMap(); + map.put(IMarker.MESSAGE, message); + map.put(IMarker.SEVERITY, new Integer(IMarker.SEVERITY_ERROR)); + map.put(IMarker.LINE_NUMBER, new Integer(errorLine)); +@@ -990,7 +990,9 @@ + */ + protected void fireModelChanged(SimpleNode root) { + //create a copy, to avoid concurrent modifications +- for (IModelListener listener : new ArrayList(modelListeners)) { ++ for (Iterator iter = new ArrayList(modelListeners).iterator(); iter.hasNext();) { ++ IModelListener listener = (IModelListener) iter.next(); ++ + listener.modelChanged(root); + } + } +@@ -1002,7 +1004,7 @@ + IProject project = getProject(); + IPythonNature pythonNature = PythonNature.getPythonNature(project); + if(pythonNature == null){ +- Tuple infoForFile = PydevPlugin.getInfoForFile(getEditorFile()); ++ Tuple infoForFile = PydevPlugin.getInfoForFile(getEditorFile()); + if(infoForFile == null){ + NotConfiguredInterpreterException e = new NotConfiguredInterpreterException(); + ErrorDialog.openError(PyAction.getShell(), +@@ -1011,7 +1013,7 @@ + throw e; + + } +- pythonNature = infoForFile.o1; ++ pythonNature = (IPythonNature) infoForFile.o1; + } + return pythonNature; + } +@@ -1030,8 +1032,8 @@ + return ast; + } + +- Map onOfflineActionListeners = new HashMap(); +- public Collection getOfflineActionDescriptions(){ ++ Map onOfflineActionListeners = new HashMap(); ++ public Collection getOfflineActionDescriptions(){ + return onOfflineActionListeners.values(); + } + public void addOfflineActionListener(String key, IAction action) { +@@ -1041,7 +1043,7 @@ + onOfflineActionListeners.put(key, new ActionInfo(action, description, key, needsEnter)); + } + public boolean activatesAutomaticallyOn(String key){ +- ActionInfo info = onOfflineActionListeners.get(key); ++ ActionInfo info = (ActionInfo) onOfflineActionListeners.get(key); + if(info != null){ + if(!info.needsEnter){ + return true; +@@ -1053,7 +1055,7 @@ + * @return if an action was binded and was successfully executed + */ + public boolean onOfflineAction(String requestedStr, OfflineActionTarget target) { +- ActionInfo actionInfo = onOfflineActionListeners.get(requestedStr); ++ ActionInfo actionInfo = (ActionInfo) onOfflineActionListeners.get(requestedStr); + if(actionInfo == null){ + target.statusError("No action was found binded to:"+requestedStr); + return false; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/PyEditNotifier.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/PyEditNotifier.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/PyEditNotifier.java 2006-06-10 20:43:09.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/PyEditNotifier.java 2006-11-05 20:59:42.000000000 +0100 +@@ -1,6 +1,7 @@ + package org.python.pydev.editor; + + import java.lang.ref.WeakReference; ++import java.util.Iterator; + + import org.eclipse.jface.text.IDocument; + import org.python.pydev.editor.PyEdit.MyResources; +@@ -8,20 +9,22 @@ + + public class PyEditNotifier { + +- private WeakReference pyEdit; ++ private WeakReference pyEdit; + + public PyEditNotifier(PyEdit edit){ +- this.pyEdit = new WeakReference(edit); ++ this.pyEdit = new WeakReference(edit); + } + + public void notifyOnCreateActions(final MyResources resources) { +- final PyEdit edit = pyEdit.get(); ++ final PyEdit edit = (PyEdit) pyEdit.get(); + if(edit == null){ + return; + } + Runnable runnable = new Runnable(){ + public void run(){ +- for(IPyEditListener listener : edit.getAllListeners()){ ++ for (Iterator iter = edit.getAllListeners().iterator(); iter.hasNext();) { ++ IPyEditListener listener = (IPyEditListener) iter.next(); ++ + try { + listener.onCreateActions(resources, edit); + } catch (Exception e) { +@@ -35,13 +38,15 @@ + } + + public void notifyOnSave() { +- final PyEdit edit = pyEdit.get(); ++ final PyEdit edit = (PyEdit) pyEdit.get(); + if(edit == null){ + return; + } + Runnable runnable = new Runnable(){ + public void run(){ +- for(IPyEditListener listener : edit.getAllListeners()){ ++ for (Iterator iter = edit.getAllListeners().iterator(); iter.hasNext();) { ++ IPyEditListener listener = (IPyEditListener) iter.next(); ++ + try { + listener.onSave(edit); + } catch (Throwable e) { +@@ -63,14 +68,15 @@ + } + + public void notifyOnDispose() { +- final PyEdit edit = pyEdit.get(); ++ final PyEdit edit = (PyEdit) pyEdit.get(); + if(edit == null){ + return; + } + + Runnable runnable = new Runnable(){ + public void run(){ +- for(IPyEditListener listener : edit.getAllListeners()){ ++ for (Iterator iter = edit.getAllListeners().iterator(); iter.hasNext();) { ++ IPyEditListener listener = (IPyEditListener) iter.next(); + try { + listener.onDispose(edit); + } catch (Throwable e) { +@@ -86,13 +92,14 @@ + * @param document the document just set + */ + public void notifyOnSetDocument(final IDocument document) { +- final PyEdit edit = pyEdit.get(); ++ final PyEdit edit = (PyEdit) pyEdit.get(); + if(edit == null){ + return; + } + Runnable runnable = new Runnable(){ + public void run(){ +- for(IPyEditListener listener : edit.getAllListeners()){ ++ for (Iterator iter = edit.getAllListeners().iterator(); iter.hasNext();) { ++ IPyEditListener listener = (IPyEditListener) iter.next(); + try { + listener.onSetDocument(document, edit); + } catch (Exception e) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/refactoring/AbstractPyRefactoring.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/refactoring/AbstractPyRefactoring.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/refactoring/AbstractPyRefactoring.java 2006-05-21 22:26:32.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/refactoring/AbstractPyRefactoring.java 2006-11-05 20:59:42.000000000 +0100 +@@ -24,7 +24,7 @@ + */ + private static IPyRefactoring pyRefactoring; + private static IPyRefactoring defaultPyRefactoring; +- private List propChangeListeners = new ArrayList(); ++ private List propChangeListeners = new ArrayList(); + private Object[] lastRefactorResults; + + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/refactoring/PyRefactoring.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/refactoring/PyRefactoring.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/refactoring/PyRefactoring.java 2006-06-22 16:19:56.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/refactoring/PyRefactoring.java 2006-11-05 20:59:42.000000000 +0100 +@@ -155,7 +155,7 @@ + + String string = makeAction(s, request); + +- List l = new ArrayList(); ++ List l = new ArrayList(); + + if (string.startsWith("BIKE_OK:")){ + string = string.replaceFirst("BIKE_OK:", "").replaceAll("\\[","").replaceAll("'",""); +@@ -178,7 +178,7 @@ + } + + +- return l.toArray(new ItemPointer[0]); ++ return (ItemPointer[]) l.toArray(new ItemPointer[0]); + + } + +@@ -228,8 +228,8 @@ + * @param string + * @return list of strings affected by the refactoring. + */ +- private List refactorResultAsList(String string) { +- List l = new ArrayList(); ++ private List refactorResultAsList(String string) { ++ List l = new ArrayList(); + + if (string == null){ + return l; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/refactoring/RefactoringRequest.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/refactoring/RefactoringRequest.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/refactoring/RefactoringRequest.java 2006-07-01 03:47:53.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/refactoring/RefactoringRequest.java 2006-11-05 20:59:42.000000000 +0100 +@@ -203,9 +203,9 @@ + + public void fillInitialNameAndOffset(){ + try { +- Tuple currToken = ps.getCurrToken(); +- duringProcessInfo.initialName = currToken.o1; +- duringProcessInfo.initialOffset = currToken.o2; ++ Tuple currToken = ps.getCurrToken(); ++ duringProcessInfo.initialName = (String) currToken.o1; ++ duringProcessInfo.initialOffset = ((Integer)currToken.o2).intValue(); + } catch (Exception e) { + throw new RuntimeException(e); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/scripting/PyEditScripting.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/scripting/PyEditScripting.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/scripting/PyEditScripting.java 2006-03-29 14:45:44.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/scripting/PyEditScripting.java 2006-11-05 20:59:42.000000000 +0100 +@@ -29,27 +29,27 @@ + } + + +- private void doExec(HashMap locals) { ++ private void doExec(HashMap locals) { + JythonPlugin.execAll(locals, "pyedit", interpreter); //execute all the files that start with 'pyedit' that are located beneath + //the org.python.pydev.jython/jysrc directory and some user specified dir (if any). + } + + public void onSave(PyEdit edit) { +- HashMap locals = new HashMap(); ++ HashMap locals = new HashMap(); + locals.put("cmd", "onSave"); + locals.put("editor", edit); + doExec(locals); + } + + public void onCreateActions(ListResourceBundle resources, PyEdit edit) { +- HashMap locals = new HashMap(); ++ HashMap locals = new HashMap(); + locals.put("cmd", "onCreateActions"); + locals.put("editor", edit); + doExec(locals); + } + + public void onDispose(PyEdit edit) { +- HashMap locals = new HashMap(); ++ HashMap locals = new HashMap(); + locals.put("cmd", "onDispose"); + locals.put("editor", edit); + doExec(locals); +@@ -59,7 +59,7 @@ + } + + public void onSetDocument(IDocument document, PyEdit edit) { +- HashMap locals = new HashMap(); ++ HashMap locals = new HashMap(); + locals.put("cmd", "onSetDocument"); + locals.put("document", document); + locals.put("editor", edit); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/simpleassist/ISimpleAssistParticipant.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/simpleassist/ISimpleAssistParticipant.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/simpleassist/ISimpleAssistParticipant.java 2006-02-25 01:14:24.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/simpleassist/ISimpleAssistParticipant.java 2006-11-05 20:59:42.000000000 +0100 +@@ -22,6 +22,6 @@ + * + * @return a list of completions + */ +- Collection computeCompletionProposals(String activationToken, String qualifier, PySelection ps, PyEdit edit, int offset); ++ Collection computeCompletionProposals(String activationToken, String qualifier, PySelection ps, PyEdit edit, int offset); + + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/simpleassist/SimpleAssistProcessor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/simpleassist/SimpleAssistProcessor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/editor/simpleassist/SimpleAssistProcessor.java 2006-07-16 21:04:14.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/editor/simpleassist/SimpleAssistProcessor.java 2006-11-05 20:59:42.000000000 +0100 +@@ -5,6 +5,7 @@ + + import java.util.ArrayList; + import java.util.Collections; ++import java.util.Iterator; + import java.util.List; + + import org.eclipse.jface.text.IDocument; +@@ -103,11 +104,12 @@ + String qualifier = strs[1]; + + PySelection ps = new PySelection(edit); +- List results = new ArrayList(); ++ List results = new ArrayList(); + +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_SIMPLE_ASSIST); ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_SIMPLE_ASSIST); + +- for (ISimpleAssistParticipant participant : participants) { ++ for (Iterator i = participants.iterator(); i.hasNext(); ) { ++ ISimpleAssistParticipant participant = (ISimpleAssistParticipant) i.next(); + results.addAll(participant.computeCompletionProposals(activationToken, qualifier, ps, edit, offset)); + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/actions/OpenPythonNodeAction.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/actions/OpenPythonNodeAction.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/actions/OpenPythonNodeAction.java 2006-10-09 23:43:17.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/actions/OpenPythonNodeAction.java 2006-11-05 22:29:40.000000000 +0100 +@@ -52,7 +52,7 @@ + */ + public void run() { + if (isEnabled()) { +- ParsedItem actualObject = data.getActualObject(); ++ ParsedItem actualObject = (ParsedItem) data.getActualObject(); + new PyOpenAction().run(new ItemPointer( data.getPythonFile().getActualObject(), actualObject.astThis.node)); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/actions/PyOpenPythonFileAction.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/actions/PyOpenPythonFileAction.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/actions/PyOpenPythonFileAction.java 2006-10-18 03:24:36.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/actions/PyOpenPythonFileAction.java 2006-11-05 21:46:05.000000000 +0100 +@@ -24,7 +24,7 @@ + + private IWorkbenchPage page; + +- private List selected; ++ private List selected; + + private ISelectionProvider provider; + +@@ -41,7 +41,7 @@ + * @see org.eclipse.jface.action.Action#isEnabled() + */ + public boolean isEnabled() { +- selected = new ArrayList(); ++ selected = new ArrayList(); + + ISelection selection = provider.getSelection(); + if (!selection.isEmpty()) { +@@ -74,7 +74,8 @@ + */ + public void run() { + if (isEnabled()) { +- for(IFile f:selected){ ++ for (Iterator i = selected.iterator(); i.hasNext(); ) { ++ IFile f = (IFile) i.next(); + new PyOpenAction().run(new ItemPointer(f)); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/actions/PythonActionProvider.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/actions/PythonActionProvider.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/actions/PythonActionProvider.java 2006-10-23 03:12:24.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/actions/PythonActionProvider.java 2006-11-05 21:46:48.000000000 +0100 +@@ -19,7 +19,6 @@ + // private PyOpenPythonFileAction openResourceAction; + // private DeleteResourceAction deleteResourceAction; + +- @Override + public void init(ICommonActionExtensionSite aSite) { + ICommonViewerSite viewSite = aSite.getViewSite(); + if(viewSite instanceof ICommonViewerWorkbenchSite){ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/IWrappedResource.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/IWrappedResource.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/IWrappedResource.java 2006-10-23 03:12:24.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/IWrappedResource.java 2006-11-05 22:27:51.000000000 +0100 +@@ -1,5 +1,7 @@ + package org.python.pydev.navigator; + ++import org.eclipse.core.resources.IResource; ++ + /** + * Interface for a child resource (a resource that has a parent) + * +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonBaseModelProvider.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonBaseModelProvider.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonBaseModelProvider.java 2006-10-30 15:14:47.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonBaseModelProvider.java 2006-11-05 22:29:03.000000000 +0100 +@@ -68,7 +68,7 @@ + * see things in this provider, the python model starts only after some source folder + * is found. + */ +- private Map> projectToSourceFolders = new HashMap>(); ++ private Map projectToSourceFolders = new HashMap(); + + /** + * This is the viewer that we're using to see the contents of this file provider. +@@ -85,10 +85,10 @@ + /** + * Notification received when the pythonpath has been changed or rebuilt. + */ +- public void notifyPythonPathRebuilt(IProject project, List projectPythonpath) { ++ public void notifyPythonPathRebuilt(IProject project, List projectPythonpath) { + projectToSourceFolders.remove(project); + Runnable refreshRunnable = getRefreshRunnable(project); +- final Collection runnables = new ArrayList(); ++ final Collection runnables = new ArrayList(); + runnables.add(refreshRunnable); + processRunnables(runnables); + } +@@ -112,12 +112,12 @@ + * or the resource itself if it could not be found in the python model. + */ + protected Object getResourceInPythonModel(IResource object, boolean removeFoundResource, boolean returnNullIfNotFound) { +- Set sourceFolders = getProjectSourceFolders(object); ++ Set sourceFolders = getProjectSourceFolders(object); + Object f = null; + PythonSourceFolder sourceFolder = null; + +- for (Iterator it = sourceFolders.iterator();f == null && it.hasNext();) { +- sourceFolder = it.next(); ++ for (Iterator it = sourceFolders.iterator();f == null && it.hasNext();) { ++ sourceFolder = (PythonSourceFolder) it.next(); + if(sourceFolder.getActualObject().equals(object)){ + f = sourceFolder; + }else{ +@@ -143,10 +143,10 @@ + } + + +- protected Set getProjectSourceFolders(IResource object) { +- Set sourceFolder = projectToSourceFolders.get(object.getProject()); ++ protected Set getProjectSourceFolders(IResource object) { ++ Set sourceFolder = (Set) projectToSourceFolders.get(object.getProject()); + if(sourceFolder == null){ +- sourceFolder = new HashSet(); ++ sourceFolder = new HashSet(); + projectToSourceFolders.put(object.getProject(), sourceFolder); + } + return sourceFolder; +@@ -194,7 +194,7 @@ + }else if (parentElement instanceof PythonFile) { + // if it's a file, we want to show the classes and methods + PythonFile file = (PythonFile) parentElement; +- if (PythonPathHelper.isValidSourceFile(file.getActualObject())) { ++ if (PythonPathHelper.isValidSourceFile((IFile) file.getActualObject())) { + + if (nature != null) { + ICodeCompletionASTManager astManager = nature.getAstManager(); +@@ -202,14 +202,14 @@ + + if (modulesManager instanceof ProjectModulesManager) { + ProjectModulesManager projectModulesManager = (ProjectModulesManager) modulesManager; +- String moduleName = projectModulesManager.resolveModuleInDirectManager(file.getActualObject(), project); ++ String moduleName = projectModulesManager.resolveModuleInDirectManager((IResource) file.getActualObject(), project); + if (moduleName != null) { + IModule module = projectModulesManager.getModuleInDirectManager(moduleName, nature, true); + if (module instanceof SourceModule) { + SourceModule sourceModule = (SourceModule) module; + + OutlineCreatorVisitor visitor = OutlineCreatorVisitor.create(sourceModule.getAst()); +- ParsedItem root = new ParsedItem(visitor.getAll().toArray(new ASTEntryWithChildren[0])); ++ ParsedItem root = new ParsedItem((ASTEntryWithChildren []) visitor.getAll().toArray(new ASTEntryWithChildren[0])); + childrenToReturn = getChildrenFromParsedItem(parentElement, root, file); + } + } +@@ -247,12 +247,12 @@ + + try { + //check for source folder +- Set sourcePathSet = nature.getPythonPathNature().getProjectSourcePathSet(); ++ Set sourcePathSet = nature.getPythonPathNature().getProjectSourcePathSet(); + IPath fullPath = folder.getFullPath(); + if(sourcePathSet.contains(fullPath.toString())){ + ret[i] = new PythonSourceFolder(parentElement, folder); + //System.out.println("Created source folder: "+ret[i]+" - "+folder.getProject()+" - "+folder.getProjectRelativePath()); +- Set sourceFolders = getProjectSourceFolders(resource); ++ Set sourceFolders = getProjectSourceFolders(resource); + sourceFolders.add((PythonSourceFolder) ret[i]); + } + } catch (CoreException e) { +@@ -335,7 +335,8 @@ + PythonNode p[] = new PythonNode[children.length]; + int i = 0; + // in this case, we just want to return the roots +- for (ParsedItem e : children) { ++ for (int j = 0; j < children.length; j++) { ++ ParsedItem e = children[j]; + p[i] = new PythonNode(pythonFile, parentElement, e); + i++; + } +@@ -414,7 +415,7 @@ + return; + } + +- final Collection runnables = new ArrayList(); ++ final Collection runnables = new ArrayList(); + processDelta(delta, runnables); + processRunnables(runnables); + } +@@ -422,7 +423,7 @@ + /** + * @param runnables + */ +- private void processRunnables(final Collection runnables) { ++ private void processRunnables(final Collection runnables) { + Control ctrl = viewer.getControl(); + if (ctrl == null || ctrl.isDisposed()) { + return; +@@ -469,7 +470,7 @@ + /** + * Process a resource delta. Add any runnables + */ +- private void processDelta(IResourceDelta delta, Collection runnables) { ++ private void processDelta(IResourceDelta delta, Collection runnables) { + // he widget may have been destroyed + // by the time this is run. Check for this and do nothing if so. + Control ctrl = viewer.getControl(); +@@ -591,7 +592,6 @@ + final boolean hasRename = numMovedFrom > 0 && numMovedTo > 0; + + Runnable addAndRemove = new Runnable() { +- @SuppressWarnings("unchecked") + public void run() { + if (viewer instanceof AbstractTreeViewer) { + AbstractTreeViewer treeViewer = (AbstractTreeViewer) viewer; +@@ -613,12 +613,13 @@ + + if (removedObjects.length > 0) { + treeViewer.remove(removedObjects); +- for (Object object : removedObjects) { ++ for (int i = 0; i < removedObjects.length; i++) { ++ Object object = removedObjects[i]; + if(object instanceof IResource){ + IResource rem = (IResource) object; + Object remInPythonModel = getResourceInPythonModel(rem, true); + if(remInPythonModel instanceof PythonSourceFolder){ +- projectToSourceFolders.get(resource.getProject()).remove(remInPythonModel); ++ ((Set) projectToSourceFolders.get(resource.getProject())).remove(remInPythonModel); + } + } + } +@@ -664,7 +665,6 @@ + }; + } + +- @SuppressWarnings("unchecked") + protected boolean convertToPythonElements(Set currentChildren) { + LinkedHashSet convertedChildren = new LinkedHashSet(); + for (Iterator childrenItr = currentChildren.iterator(); childrenItr.hasNext();) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonFile.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonFile.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonFile.java 2006-10-29 19:07:57.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonFile.java 2006-11-05 22:21:34.000000000 +0100 +@@ -28,7 +28,7 @@ + * + * @author fabioz + */ +-public class PythonFile extends WrappedResource implements IFile{ ++public class PythonFile extends WrappedResource implements IFile{ + + public PythonFile(Object parentElement, IFile actualObject, PythonSourceFolder pythonSourceFolder) { + super(parentElement, actualObject, pythonSourceFolder, IWrappedResource.RANK_PYTHON_FILE); +@@ -48,10 +48,10 @@ + actualObject.accept(visitor); + } + public void appendContents(InputStream source, boolean force, boolean keepHistory, IProgressMonitor monitor) throws CoreException { +- actualObject.appendContents(source, force, keepHistory, monitor); ++ ((IFile) actualObject).appendContents(source, force, keepHistory, monitor); + } + public void appendContents(InputStream source, int updateFlags, IProgressMonitor monitor) throws CoreException { +- actualObject.appendContents(source, updateFlags, monitor); ++ ((IFile) actualObject).appendContents(source, updateFlags, monitor); + } + public void clearHistory(IProgressMonitor monitor) throws CoreException { + actualObject.clearHistory(monitor); +@@ -72,16 +72,16 @@ + actualObject.copy(description, updateFlags, monitor); + } + public void create(InputStream source, boolean force, IProgressMonitor monitor) throws CoreException { +- actualObject.create(source, force, monitor); ++ ((IFile) actualObject).create(source, force, monitor); + } + public void create(InputStream source, int updateFlags, IProgressMonitor monitor) throws CoreException { +- actualObject.create(source, updateFlags, monitor); ++ ((IFile) actualObject).create(source, updateFlags, monitor); + } + public void createLink(IPath localLocation, int updateFlags, IProgressMonitor monitor) throws CoreException { +- actualObject.createLink(localLocation, updateFlags, monitor); ++ ((IFile) actualObject).createLink(localLocation, updateFlags, monitor); + } + public void createLink(URI location, int updateFlags, IProgressMonitor monitor) throws CoreException { +- actualObject.createLink(location, updateFlags, monitor); ++ ((IFile) actualObject).createLink(location, updateFlags, monitor); + } + public IMarker createMarker(String type) throws CoreException { + return actualObject.createMarker(type); +@@ -90,7 +90,7 @@ + return actualObject.createProxy(); + } + public void delete(boolean force, boolean keepHistory, IProgressMonitor monitor) throws CoreException { +- actualObject.delete(force, keepHistory, monitor); ++ ((IFile) actualObject).delete(force, keepHistory, monitor); + } + public void delete(boolean force, IProgressMonitor monitor) throws CoreException { + actualObject.delete(force, monitor); +@@ -114,25 +114,25 @@ + return actualObject.getAdapter(adapter); + } + public String getCharset() throws CoreException { +- return actualObject.getCharset(); ++ return ((IFile) actualObject).getCharset(); + } + public String getCharset(boolean checkImplicit) throws CoreException { +- return actualObject.getCharset(checkImplicit); ++ return ((IFile) actualObject).getCharset(checkImplicit); + } + public String getCharsetFor(Reader reader) throws CoreException { +- return actualObject.getCharsetFor(reader); ++ return ((IFile) actualObject).getCharsetFor(reader); + } + public IContentDescription getContentDescription() throws CoreException { +- return actualObject.getContentDescription(); ++ return ((IFile) actualObject).getContentDescription(); + } + public InputStream getContents() throws CoreException { +- return actualObject.getContents(); ++ return ((IFile) actualObject).getContents(); + } + public InputStream getContents(boolean force) throws CoreException { +- return actualObject.getContents(force); ++ return ((IFile) actualObject).getContents(force); + } + public int getEncoding() throws CoreException { +- return actualObject.getEncoding(); ++ return ((IFile) actualObject).getEncoding(); + } + public String getFileExtension() { + return actualObject.getFileExtension(); +@@ -141,7 +141,7 @@ + return actualObject.getFullPath(); + } + public IFileState[] getHistory(IProgressMonitor monitor) throws CoreException { +- return actualObject.getHistory(monitor); ++ return ((IFile) actualObject).getHistory(monitor); + } + public long getLocalTimeStamp() { + return actualObject.getLocalTimeStamp(); +@@ -222,7 +222,7 @@ + return actualObject.isTeamPrivateMember(); + } + public void move(IPath destination, boolean force, boolean keepHistory, IProgressMonitor monitor) throws CoreException { +- actualObject.move(destination, force, keepHistory, monitor); ++ ((IFile) actualObject).move(destination, force, keepHistory, monitor); + } + public void move(IPath destination, boolean force, IProgressMonitor monitor) throws CoreException { + actualObject.move(destination, force, monitor); +@@ -243,22 +243,22 @@ + actualObject.revertModificationStamp(value); + } + public void setCharset(String newCharset, IProgressMonitor monitor) throws CoreException { +- actualObject.setCharset(newCharset, monitor); ++ ((IFile) actualObject).setCharset(newCharset, monitor); + } + public void setCharset(String newCharset) throws CoreException { +- actualObject.setCharset(newCharset); ++ ((IFile) actualObject).setCharset(newCharset); + } + public void setContents(IFileState source, boolean force, boolean keepHistory, IProgressMonitor monitor) throws CoreException { +- actualObject.setContents(source, force, keepHistory, monitor); ++ ((IFile) actualObject).setContents(source, force, keepHistory, monitor); + } + public void setContents(IFileState source, int updateFlags, IProgressMonitor monitor) throws CoreException { +- actualObject.setContents(source, updateFlags, monitor); ++ ((IFile) actualObject).setContents(source, updateFlags, monitor); + } + public void setContents(InputStream source, boolean force, boolean keepHistory, IProgressMonitor monitor) throws CoreException { +- actualObject.setContents(source, force, keepHistory, monitor); ++ ((IFile) actualObject).setContents(source, force, keepHistory, monitor); + } + public void setContents(InputStream source, int updateFlags, IProgressMonitor monitor) throws CoreException { +- actualObject.setContents(source, updateFlags, monitor); ++ ((IFile) actualObject).setContents(source, updateFlags, monitor); + } + public void setDerived(boolean isDerived) throws CoreException { + actualObject.setDerived(isDerived); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonFolder.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonFolder.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonFolder.java 2006-10-29 19:07:58.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonFolder.java 2006-11-05 22:25:33.000000000 +0100 +@@ -20,7 +20,7 @@ + import org.eclipse.core.runtime.QualifiedName; + import org.eclipse.core.runtime.jobs.ISchedulingRule; + +-public class PythonFolder extends WrappedResource implements IFolder{ ++public class PythonFolder extends WrappedResource implements IFolder{ + + public PythonFolder(Object parentElement, IFolder folder, PythonSourceFolder pythonSourceFolder) { + super(parentElement, folder, pythonSourceFolder, IWrappedResource.RANK_PYTHON_FOLDER); +@@ -57,16 +57,16 @@ + actualObject.copy(description, updateFlags, monitor); + } + public void create(boolean force, boolean local, IProgressMonitor monitor) throws CoreException { +- actualObject.create(force, local, monitor); ++ ((IFolder) actualObject).create(force, local, monitor); + } + public void create(int updateFlags, boolean local, IProgressMonitor monitor) throws CoreException { +- actualObject.create(updateFlags, local, monitor); ++ ((IFolder) actualObject).create(updateFlags, local, monitor); + } + public void createLink(IPath localLocation, int updateFlags, IProgressMonitor monitor) throws CoreException { +- actualObject.createLink(localLocation, updateFlags, monitor); ++ ((IFolder) actualObject).createLink(localLocation, updateFlags, monitor); + } + public void createLink(URI location, int updateFlags, IProgressMonitor monitor) throws CoreException { +- actualObject.createLink(location, updateFlags, monitor); ++ ((IFolder) actualObject).createLink(location, updateFlags, monitor); + } + public IMarker createMarker(String type) throws CoreException { + return actualObject.createMarker(type); +@@ -75,7 +75,7 @@ + return actualObject.createProxy(); + } + public void delete(boolean force, boolean keepHistory, IProgressMonitor monitor) throws CoreException { +- actualObject.delete(force, keepHistory, monitor); ++ ((IFolder) actualObject).delete(force, keepHistory, monitor); + } + public void delete(boolean force, IProgressMonitor monitor) throws CoreException { + actualObject.delete(force, monitor); +@@ -90,10 +90,10 @@ + return actualObject.exists(); + } + public boolean exists(IPath path) { +- return actualObject.exists(path); ++ return ((IFolder) actualObject).exists(path); + } + public IFile[] findDeletedMembersWithHistory(int depth, IProgressMonitor monitor) throws CoreException { +- return actualObject.findDeletedMembersWithHistory(depth, monitor); ++ return ((IFolder) actualObject).findDeletedMembersWithHistory(depth, monitor); + } + public IMarker findMarker(long id) throws CoreException { + return actualObject.findMarker(id); +@@ -102,40 +102,40 @@ + return actualObject.findMarkers(type, includeSubtypes, depth); + } + public IResource findMember(IPath path, boolean includePhantoms) { +- return actualObject.findMember(path, includePhantoms); ++ return ((IFolder) actualObject).findMember(path, includePhantoms); + } + public IResource findMember(IPath path) { +- return actualObject.findMember(path); ++ return ((IFolder) actualObject).findMember(path); + } + public IResource findMember(String name, boolean includePhantoms) { +- return actualObject.findMember(name, includePhantoms); ++ return ((IFolder) actualObject).findMember(name, includePhantoms); + } + public IResource findMember(String name) { +- return actualObject.findMember(name); ++ return ((IFolder) actualObject).findMember(name); + } + public Object getAdapter(Class adapter) { + return actualObject.getAdapter(adapter); + } + public String getDefaultCharset() throws CoreException { +- return actualObject.getDefaultCharset(); ++ return ((IFolder) actualObject).getDefaultCharset(); + } + public String getDefaultCharset(boolean checkImplicit) throws CoreException { +- return actualObject.getDefaultCharset(checkImplicit); ++ return ((IFolder) actualObject).getDefaultCharset(checkImplicit); + } + public IFile getFile(IPath path) { +- return actualObject.getFile(path); ++ return ((IFolder) actualObject).getFile(path); + } + public IFile getFile(String name) { +- return actualObject.getFile(name); ++ return ((IFolder) actualObject).getFile(name); + } + public String getFileExtension() { + return actualObject.getFileExtension(); + } + public IFolder getFolder(IPath path) { +- return actualObject.getFolder(path); ++ return ((IFolder) actualObject).getFolder(path); + } + public IFolder getFolder(String name) { +- return actualObject.getFolder(name); ++ return ((IFolder) actualObject).getFolder(name); + } + public IPath getFullPath() { + return actualObject.getFullPath(); +@@ -219,16 +219,16 @@ + return actualObject.isTeamPrivateMember(); + } + public IResource[] members() throws CoreException { +- return actualObject.members(); ++ return ((IFolder) actualObject).members(); + } + public IResource[] members(boolean includePhantoms) throws CoreException { +- return actualObject.members(includePhantoms); ++ return ((IFolder) actualObject).members(includePhantoms); + } + public IResource[] members(int memberFlags) throws CoreException { +- return actualObject.members(memberFlags); ++ return ((IFolder) actualObject).members(memberFlags); + } + public void move(IPath destination, boolean force, boolean keepHistory, IProgressMonitor monitor) throws CoreException { +- actualObject.move(destination, force, keepHistory, monitor); ++ ((IFolder) actualObject).move(destination, force, keepHistory, monitor); + } + public void move(IPath destination, boolean force, IProgressMonitor monitor) throws CoreException { + actualObject.move(destination, force, monitor); +@@ -249,10 +249,10 @@ + actualObject.revertModificationStamp(value); + } + public void setDefaultCharset(String charset, IProgressMonitor monitor) throws CoreException { +- actualObject.setDefaultCharset(charset, monitor); ++ ((IFolder) actualObject).setDefaultCharset(charset, monitor); + } + public void setDefaultCharset(String charset) throws CoreException { +- actualObject.setDefaultCharset(charset); ++ ((IFolder) actualObject).setDefaultCharset(charset); + } + public void setDerived(boolean isDerived) throws CoreException { + actualObject.setDerived(isDerived); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonModelProvider.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonModelProvider.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonModelProvider.java 2006-10-30 15:14:46.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonModelProvider.java 2006-11-05 21:40:14.000000000 +0100 +@@ -30,7 +30,6 @@ + */ + public class PythonModelProvider extends PythonBaseModelProvider implements IPipelinedTreeContentProvider { + +- @SuppressWarnings("unchecked") + public void getPipelinedChildren(Object parent, Set currentChildren) { + Object[] children = getChildren(parent); + for (Iterator iter = currentChildren.iterator(); iter.hasNext();){ +@@ -42,7 +41,6 @@ + currentChildren.addAll(Arrays.asList(children)); + } + +- @SuppressWarnings("unchecked") + public void getPipelinedElements(Object input, Set currentElements) { + Object[] children = getElements(input); + +@@ -101,7 +99,6 @@ + * @param isAdd whether this is an add operation or not + * @return + */ +- @SuppressWarnings("unchecked") + protected boolean wrapChildren(IResource parent, PythonSourceFolder pythonSourceFolder, Set currentChildren, boolean isAdd) { + LinkedHashSet convertedChildren = new LinkedHashSet(); + for (Iterator childrenItr = currentChildren.iterator(); childrenItr.hasNext();) { +@@ -128,13 +125,13 @@ + PythonNature nature = PythonNature.getPythonNature(project); + if(nature!= null){ + //check for source folder +- Set sourcePathSet = nature.getPythonPathNature().getProjectSourcePathSet(); ++ Set sourcePathSet = nature.getPythonPathNature().getProjectSourcePathSet(); + IPath fullPath = folder.getFullPath(); + if(sourcePathSet.contains(fullPath.toString())){ + PythonSourceFolder sourceFolder = new PythonSourceFolder(parent, folder); + convertedChildren.add(sourceFolder); + //System.out.println("Created source folder: "+ret[i]+" - "+folder.getProject()+" - "+folder.getProjectRelativePath()); +- Set sourceFolders = getProjectSourceFolders(folder); ++ Set sourceFolders = getProjectSourceFolders(folder); + sourceFolders.add((PythonSourceFolder) sourceFolder); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonModelSorter.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonModelSorter.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonModelSorter.java 2006-10-29 19:07:58.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonModelSorter.java 2006-11-05 21:40:24.000000000 +0100 +@@ -10,7 +10,6 @@ + + public class PythonModelSorter extends ViewerSorter{ + +- @SuppressWarnings("unchecked") + public int compare(Viewer viewer, Object e1, Object e2) { + if(e1 instanceof PythonNode || e2 instanceof PythonNode){ + return 0; //we don't want to sort it... just show it in the order it is found in the file +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonNode.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonNode.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonNode.java 2006-10-23 03:12:24.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonNode.java 2006-11-05 22:27:08.000000000 +0100 +@@ -18,7 +18,6 @@ + this.pythonFile = pythonFile; + } + +- @Override + public String toString() { + return entry.toString(); + } +@@ -34,7 +33,7 @@ + return parent; + } + +- public ParsedItem getActualObject() { ++ public Object getActualObject() { + return entry; + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonResource.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonResource.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonResource.java 2006-10-29 19:07:58.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonResource.java 2006-11-05 21:40:52.000000000 +0100 +@@ -19,7 +19,7 @@ + import org.eclipse.core.runtime.jobs.ISchedulingRule; + + +-public class PythonResource extends WrappedResource implements IResource{ ++public class PythonResource extends WrappedResource implements IResource{ + + public PythonResource(Object parentElement, IResource object, PythonSourceFolder pythonSourceFolder) { + super(parentElement, object, pythonSourceFolder, IWrappedResource.RANK_PYTHON_RESOURCE); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonSourceFolder.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonSourceFolder.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/PythonSourceFolder.java 2006-10-29 19:07:58.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/PythonSourceFolder.java 2006-11-05 22:28:07.000000000 +0100 +@@ -7,6 +7,7 @@ + import java.net.URI; + import java.util.ArrayList; + import java.util.HashMap; ++import java.util.Iterator; + import java.util.List; + import java.util.Map; + +@@ -37,8 +38,8 @@ + + public IFolder folder; + public Object parentElement; +- public Map children = new HashMap(); +- public Map> childrenForContainer = new HashMap>(); ++ public Map children = new HashMap(); ++ public Map childrenForContainer = new HashMap(); + + public PythonSourceFolder(Object parentElement, IFolder folder) { + this.parentElement = parentElement; +@@ -63,9 +64,9 @@ + children.put(actualObject, child); + + IContainer container = actualObject.getParent(); +- List l = childrenForContainer.get(container); ++ List l = (List) childrenForContainer.get(container); + if(l == null){ +- l = new ArrayList(); ++ l = new ArrayList(); + childrenForContainer.put(container, l); + } + l.add(actualObject); +@@ -75,9 +76,10 @@ + //System.out.println("Removing child:"+actualObject); + children.remove(actualObject); + if(actualObject instanceof IContainer){ +- List l = childrenForContainer.get(actualObject); ++ List l = (List) childrenForContainer.get(actualObject); + if(l != null){ +- for (IResource resource : l) { ++ for (Iterator i = l.iterator(); i.hasNext(); ) { ++ IResource resource = (IResource) i.next(); + removeChild(resource); + } + childrenForContainer.remove(actualObject); +@@ -86,7 +88,7 @@ + } + + public Object getChild(IResource actualObject){ +- IWrappedResource ret = children.get(actualObject); ++ IWrappedResource ret = (IWrappedResource) children.get(actualObject); + //System.out.println("Gotten child:"+ret+" for resource:"+actualObject); + return ret; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/WrappedResource.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/WrappedResource.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/navigator/WrappedResource.java 2006-10-29 19:07:57.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/navigator/WrappedResource.java 2006-11-05 22:28:21.000000000 +0100 +@@ -5,14 +5,14 @@ + import org.eclipse.ui.IContributorResourceAdapter; + + +-public class WrappedResource implements IWrappedResource, IContributorResourceAdapter, IAdaptable{ ++public class WrappedResource implements IWrappedResource, IContributorResourceAdapter, IAdaptable{ + + protected Object parentElement; +- protected X actualObject; ++ protected IResource actualObject; + protected PythonSourceFolder pythonSourceFolder; + protected int rank; + +- public WrappedResource(Object parentElement, X actualObject, PythonSourceFolder pythonSourceFolder, int rank) { ++ public WrappedResource(Object parentElement, IResource actualObject, PythonSourceFolder pythonSourceFolder, int rank) { + this.parentElement = parentElement; + this.actualObject = actualObject; + this.pythonSourceFolder = pythonSourceFolder; +@@ -20,7 +20,7 @@ + this.rank = rank; + } + +- public X getActualObject() { ++ public Object getActualObject() { + return actualObject; + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/outline/ParsedItem.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/outline/ParsedItem.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/outline/ParsedItem.java 2006-10-08 17:31:58.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/outline/ParsedItem.java 2006-11-05 20:59:43.000000000 +0100 +@@ -86,11 +86,13 @@ + return new ParsedItem[0]; + } + +- ArrayList items = new ArrayList(); +- for(ASTEntryWithChildren c : astChildrenEntries){ ++ ArrayList items = new ArrayList(); ++ for (int i = 0; i < astChildrenEntries.length; i++) { ++ ASTEntryWithChildren c = astChildrenEntries[i]; ++ + items.add(new ParsedItem(this, c, c.getChildren())); + } +- children = items.toArray(new ParsedItem[items.size()]); ++ children = (ParsedItem[]) items.toArray(new ParsedItem[items.size()]); + return children; + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/outline/ParsedModel.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/outline/ParsedModel.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/outline/ParsedModel.java 2006-06-11 22:04:08.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/outline/ParsedModel.java 2006-11-05 20:59:43.000000000 +0100 +@@ -41,13 +41,13 @@ + Display.getDefault().asyncExec( new Runnable() { + public void run() { + OutlineCreatorVisitor visitor = OutlineCreatorVisitor.create(ast); +- setRoot(new ParsedItem(visitor.getAll().toArray(new ASTEntryWithChildren[0]))); ++ setRoot(new ParsedItem((ASTEntryWithChildren[])visitor.getAll().toArray(new ASTEntryWithChildren[0]))); + } + }); + } + }; + OutlineCreatorVisitor visitor = OutlineCreatorVisitor.create(editor.getAST()); +- root = new ParsedItem(visitor.getAll().toArray(new ASTEntryWithChildren[0])); ++ root = new ParsedItem((ASTEntryWithChildren[])visitor.getAll().toArray(new ASTEntryWithChildren[0])); + editor.addModelListener(modelListener); + } + +@@ -62,7 +62,7 @@ + // patchRootHelper makes oldItem just like the newItem + // the differnce between the two is + private void patchRootHelper(ParsedItem oldItem, ParsedItem newItem, +- ArrayList itemsToRefresh, ArrayList itemsToUpdate) { ++ ArrayList itemsToRefresh, ArrayList itemsToUpdate) { + + ParsedItem[] newChildren = newItem.getChildren(); + ParsedItem[] oldChildren = oldItem.getChildren(); +@@ -100,8 +100,8 @@ + // We'll try to do the 'least flicker replace' + // compare the two root structures, and tell outline what to refresh + if (root != null) { +- ArrayList itemsToRefresh = new ArrayList(); +- ArrayList itemsToUpdate = new ArrayList(); ++ ArrayList itemsToRefresh = new ArrayList(); ++ ArrayList itemsToUpdate = new ArrayList(); + patchRootHelper(root, newRoot, itemsToRefresh, itemsToUpdate); + if (outline != null) { + if(outline.isDisposed()){ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/outline/PyOutlinePage.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/outline/PyOutlinePage.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/outline/PyOutlinePage.java 2006-07-20 03:27:05.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/outline/PyOutlinePage.java 2006-11-05 20:59:43.000000000 +0100 +@@ -213,7 +213,6 @@ + if(hideCommentsFilter == null){ + hideCommentsFilter = new ViewerFilter(){ + +- @Override + public boolean select(Viewer viewer, Object parentElement, Object element) { + if(element instanceof ParsedItem){ + ParsedItem item = (ParsedItem) element; +@@ -251,7 +250,6 @@ + if(hideImportsFilter == null){ + hideImportsFilter = new ViewerFilter(){ + +- @Override + public boolean select(Viewer viewer, Object parentElement, Object element) { + if(element instanceof ParsedItem){ + ParsedItem item = (ParsedItem) element; +@@ -278,7 +276,6 @@ + getStore().setValue(PREF_ALPHA_SORT, doSort); + if (sortByNameSorter == null) { + sortByNameSorter = new ViewerSorter() { +- @SuppressWarnings("unchecked") + public int compare(Viewer viewer, Object e1, Object e2) { + return ((Comparable)e1).compareTo(e2); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/AbstractPydevPrefs.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/AbstractPydevPrefs.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/AbstractPydevPrefs.java 2006-05-30 03:09:48.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/AbstractPydevPrefs.java 2006-11-05 20:59:43.000000000 +0100 +@@ -223,7 +223,7 @@ + + protected OverlayPreferenceStore fOverlayStore; + +- protected Map fCheckBoxes= new HashMap(); ++ protected Map fCheckBoxes= new HashMap(); + protected SelectionListener fCheckBoxListener= new SelectionListener() { + public void widgetDefaultSelected(SelectionEvent e) { + } +@@ -233,7 +233,7 @@ + } + }; + +- protected Map fTextFields= new HashMap(); ++ protected Map fTextFields= new HashMap(); + protected ModifyListener fTextFieldListener= new ModifyListener() { + public void modifyText(ModifyEvent e) { + Text text= (Text) e.widget; +@@ -241,7 +241,7 @@ + } + }; + +- protected java.util.List fNumberFields= new ArrayList(); ++ protected java.util.List fNumberFields= new ArrayList(); + protected ModifyListener fNumberFieldListener= new ModifyListener() { + public void modifyText(ModifyEvent e) { + numberFieldChanged((Text) e.widget); +@@ -284,11 +284,11 @@ + * @see #createDependency(Button, String, Control) + * @since 3.0 + */ +- protected java.util.List fMasterSlaveListeners= new ArrayList(); ++ protected java.util.List fMasterSlaveListeners= new ArrayList(); + + protected OverlayPreferenceStore createOverlayStore() { + +- java.util.List overlayKeys= new ArrayList(); ++ java.util.List overlayKeys= new ArrayList(); + + //text + overlayKeys.add(new OverlayPreferenceStore.OverlayKey(OverlayPreferenceStore.INT, TAB_WIDTH)); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/IPythonNatureListener.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/IPythonNatureListener.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/IPythonNatureListener.java 2006-10-29 19:07:58.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/IPythonNatureListener.java 2006-11-05 21:46:58.000000000 +0100 +@@ -24,7 +24,7 @@ + * @param project is the project that had the pythonpath rebuilt + * @param projectPythonpath the project pythonpath used when rebuilding {@link IPythonPathNature#getCompleteProjectPythonPath()} + */ +- void notifyPythonPathRebuilt(IProject project, List projectPythonpath); ++ void notifyPythonPathRebuilt(IProject project, List projectPythonpath); + + + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNature.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNature.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNature.java 2006-10-29 19:07:58.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNature.java 2006-11-05 21:48:06.000000000 +0100 +@@ -9,6 +9,7 @@ + + import java.io.File; + import java.util.ArrayList; ++import java.util.Iterator; + import java.util.List; + + import org.eclipse.core.resources.ICommand; +@@ -246,7 +247,6 @@ + + Job codeCompletionLoadJob = new Job("Pydev code completion") { + +- @SuppressWarnings("unchecked") + protected IStatus run(IProgressMonitor monitorArg) { + //begins task automatically + JobProgressComunicator jobProgressComunicator = new JobProgressComunicator(monitorArg, "Pydev restoring cache info...", IProgressMonitor.UNKNOWN, this); +@@ -263,8 +263,9 @@ + } + + if (astManager != null) { +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); +- for (IInterpreterObserver observer : participants) { ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); ++ for (Iterator i = participants.iterator(); i.hasNext(); ) { ++ IInterpreterObserver observer = (IInterpreterObserver) i.next(); + try { + observer.notifyNatureRecreated(nature, jobProgressComunicator); + } catch (Exception e) { +@@ -353,7 +354,6 @@ + final PythonNature nature = this; + Job myJob = new Job("Pydev code completion: rebuilding modules") { + +- @SuppressWarnings("unchecked") + protected IStatus run(IProgressMonitor monitorArg) { + + JobProgressComunicator jobProgressComunicator = new JobProgressComunicator(monitorArg, "Rebuilding modules", IProgressMonitor.UNKNOWN, this); +@@ -370,8 +370,11 @@ + tempAstManager.changePythonPath(paths, project, jobProgressComunicator, defaultSelectedInterpreter); + saveAstManager(); + +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); +- for (IInterpreterObserver observer : participants) { ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); ++ for (Iterator iter = participants.iterator(); iter ++ .hasNext();) { ++ IInterpreterObserver observer = (IInterpreterObserver) iter.next(); ++ + try { + observer.notifyProjectPythonpathRestored(nature, jobProgressComunicator, defaultSelectedInterpreter); + } catch (Exception e) { +@@ -438,11 +441,13 @@ + /** + * @return all the python natures available in the workspace + */ +- public static List getAllPythonNatures() { +- List natures = new ArrayList(); ++ public static List getAllPythonNatures() { ++ List natures = new ArrayList(); + IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot(); + IProject[] projects = root.getProjects(); +- for (IProject project : projects) { ++ for (int i = 0; i < projects.length; i++) { ++ IProject project = projects[i]; ++ + PythonNature nature = getPythonNature(project); + if(nature != null){ + natures.add(nature); +@@ -530,9 +535,9 @@ + + public boolean isJython() throws CoreException { + if(isJython == null){ +- isJython = getVersion().equals(JYTHON_VERSION_2_1); ++ isJython = new Boolean(getVersion().equals(JYTHON_VERSION_2_1)); + } +- return isJython; ++ return isJython.booleanValue(); + } + + public boolean isPython() throws CoreException { +@@ -671,11 +676,13 @@ + this.builtinMod = mod; + } + +- public static List getPythonNaturesRelatedTo(int relatedTo) { +- ArrayList ret = new ArrayList(); ++ public static List getPythonNaturesRelatedTo(int relatedTo) { ++ ArrayList ret = new ArrayList(); + IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot(); + IProject[] projects = root.getProjects(); +- for (IProject project : projects) { ++ for (int i = 0; i < projects.length; i++) { ++ IProject project = projects[i]; ++ + PythonNature nature = getPythonNature(project); + try { + if(nature != null){ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNatureListenersManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNatureListenersManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNatureListenersManager.java 2006-10-29 19:07:58.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNatureListenersManager.java 2006-11-05 21:49:38.000000000 +0100 +@@ -19,10 +19,10 @@ + * @author Fabio + */ + public class PythonNatureListenersManager { +- private static List> pythonNatureListeners = new ArrayList>(); ++ private static List pythonNatureListeners = new ArrayList(); + + public static void addPythonNatureListener(IPythonNatureListener listener){ +- pythonNatureListeners.add(new WeakReference(listener)); ++ pythonNatureListeners.add(new WeakReference(listener)); + } + + /** +@@ -31,11 +31,11 @@ + * @param project is the project that had the pythonpath rebuilt + * @param projectPythonpath the project pythonpath used when rebuilding + */ +- public static void notifyPythonPathRebuilt(IProject project, List projectPythonpath){ +- for(Iterator> it = pythonNatureListeners.iterator();it.hasNext();){ +- WeakReference ref = it.next(); ++ public static void notifyPythonPathRebuilt(IProject project, List projectPythonpath){ ++ for(Iterator it = pythonNatureListeners.iterator();it.hasNext();){ ++ WeakReference ref = (WeakReference) it.next(); + try{ +- IPythonNatureListener listener = ref.get(); ++ IPythonNatureListener listener = (IPythonNatureListener) ref.get(); + if(listener == null){ + it.remove(); + }else{ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNatureStore.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNatureStore.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNatureStore.java 2006-11-01 11:35:08.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNatureStore.java 2006-11-05 21:50:34.000000000 +0100 +@@ -253,7 +253,7 @@ + private String[] getChildValuesWithType(Node node, String type) { + NodeList childNodes = node.getChildNodes(); + if (childNodes != null && childNodes.getLength() > 0) { +- List result = new ArrayList(); ++ List result = new ArrayList(); + for (int i = 0; i < childNodes.getLength(); i++) { + Node child = childNodes.item(i); + if (child.getNodeName().equals(type)) { +@@ -261,7 +261,7 @@ + } + } + String[] retval = new String[result.size()]; +- return result.toArray(retval); ++ return (String []) result.toArray(retval); + } + return null; + } +@@ -542,7 +542,6 @@ + } else { + Job storeJob = new Job("Store Pydev Project Descriptor") { + +- @Override + protected IStatus run(IProgressMonitor monitor) { + try { + monitor.beginTask("Storing Pydev Project Descriptor", 10); +@@ -573,7 +572,6 @@ + if (xmlFile.getModificationStamp() != modStamp) { + Job loadJob = new Job("Reload Pydev Project Descriptor") { + +- @Override + protected IStatus run(IProgressMonitor monitor) { + try { + monitor.beginTask("Loading Pydev Project Descriptor", 10); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/PythonPathNature.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/PythonPathNature.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/nature/PythonPathNature.java 2006-10-29 19:07:58.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/nature/PythonPathNature.java 2006-11-05 21:51:26.000000000 +0100 +@@ -165,13 +165,13 @@ + /** + * Cache for the project source path. + */ +- private Set projectSourcePathSet; ++ private Set projectSourcePathSet; + +- public Set getProjectSourcePathSet() throws CoreException { ++ public Set getProjectSourcePathSet() throws CoreException { + if(projectSourcePathSet == null){ + String projectSourcePath = getProjectSourcePath(); + String[] paths = projectSourcePath.split("\\|"); +- projectSourcePathSet = new HashSet(Arrays.asList(paths)); ++ projectSourcePathSet = new HashSet(Arrays.asList(paths)); + } + return projectSourcePathSet; + } +@@ -189,7 +189,9 @@ + //project, the path may become invalid (in which case we have to make it compatible again). + StringBuffer buffer = new StringBuffer(); + String[] paths = projectSourcePath.split("\\|"); +- for (String path : paths) { ++ for (int i = 0; i < paths.length; i++) { ++ String path = paths[i]; ++ + if(path.trim().length() > 0){ + IPath p = new Path(path); + if(p.isEmpty()){ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/PydevPlugin.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/PydevPlugin.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/PydevPlugin.java 2006-06-23 01:46:26.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/PydevPlugin.java 2006-11-05 20:59:43.000000000 +0100 +@@ -474,8 +474,8 @@ + }else if(askIfDoesNotExist){ + //this is the last resort... First we'll try to check for a 'good' match, + //and if there's more than one we'll ask it to the user +- List likelyFiles = getLikelyFiles(path, w); +- IFile iFile = selectWorkspaceFile(likelyFiles.toArray(new IFile[0])); ++ List likelyFiles = getLikelyFiles(path, w); ++ IFile iFile = selectWorkspaceFile((IFile[]) likelyFiles.toArray(new IFile[0])); + if(iFile != null){ + return new FileEditorInput(iFile); + } +@@ -502,7 +502,7 @@ + * This is the last resort... pointing to some filesystem file to get the editor for some path. + */ + private static IEditorInput selectFilesystemFileForPath(final IPath path) { +- final List l = new ArrayList(); ++ final List l = new ArrayList(); + Runnable r = new Runnable(){ + + public void run() { +@@ -522,7 +522,7 @@ + r.run(); + } + if(l.size() > 0){ +- String fileAbsolutePath = REF.getFileAbsolutePath(l.get(0)); ++ String fileAbsolutePath = REF.getFileAbsolutePath((String) l.get(0)); + return new PydevFileEditorInput(new File(fileAbsolutePath)); + } + return null; +@@ -532,8 +532,8 @@ + * This method will pass all the files in the workspace and check if there's a file that might + * be a match to some path (use only as an almost 'last-resort'). + */ +- private static List getLikelyFiles(IPath path, IWorkspace w) { +- List ret = new ArrayList(); ++ private static List getLikelyFiles(IPath path, IWorkspace w) { ++ List ret = new ArrayList(); + try { + IResource[] resources = w.getRoot().members(); + getLikelyFiles(path, ret, resources); +@@ -546,10 +546,11 @@ + /** + * Used to recursively get the likely files given the first set of containers + */ +- private static void getLikelyFiles(IPath path, List ret, IResource[] resources) throws CoreException { ++ private static void getLikelyFiles(IPath path, List ret, IResource[] resources) throws CoreException { + String strPath = path.removeFileExtension().lastSegment().toLowerCase(); //this will return something as 'foo' +- +- for (IResource resource : resources) { ++ for (int i = 0; i < resources.length; i++) { ++ IResource resource = resources[i]; ++ + if(resource instanceof IFile){ + IFile f = (IFile) resource; + +@@ -595,7 +596,7 @@ + return null; + + int length= files.length; +- ArrayList existentFiles= new ArrayList(length); ++ ArrayList existentFiles= new ArrayList(length); + for (int i= 0; i < length; i++) { + if (files[i].exists()) + existentFiles.add(files[i]); +@@ -610,7 +611,7 @@ + if(files.length == 1){ + return files[0]; + } +- final List selected = new ArrayList(); ++ final List selected = new ArrayList(); + + Runnable r = new Runnable(){ + public void run() { +@@ -631,7 +632,7 @@ + r.run(); + } + if(selected.size() > 0){ +- return selected.get(0); ++ return (IFile) selected.get(0); + } + return null; + } +@@ -712,8 +713,8 @@ + /** + * @return All the IFiles below the current folder that are python files (does not check if it has an __init__ path) + */ +- public static List getAllIFilesBelow(IFolder member) { +- final ArrayList ret = new ArrayList(); ++ public static List getAllIFilesBelow(IFolder member) { ++ final ArrayList ret = new ArrayList(); + try { + member.accept(new IResourceVisitor(){ + +@@ -738,7 +739,7 @@ + * @param file + * @return tuple with files in pos 0 and folders in pos 1 + */ +- public static List[] getPyFilesBelow(File file, IProgressMonitor monitor, final boolean includeDirs, boolean checkHasInit) { ++ public static List[] getPyFilesBelow(File file, IProgressMonitor monitor, final boolean includeDirs, boolean checkHasInit) { + FileFilter filter = getPyFilesFileFilter(includeDirs); + return getPyFilesBelow(file, filter, monitor, true, checkHasInit); + } +@@ -774,11 +775,11 @@ + } + + +- public static List[] getPyFilesBelow(File file, FileFilter filter, IProgressMonitor monitor, boolean checkHasInit) { ++ public static List[] getPyFilesBelow(File file, FileFilter filter, IProgressMonitor monitor, boolean checkHasInit) { + return getPyFilesBelow(file, filter, monitor, true, checkHasInit); + } + +- public static List[] getPyFilesBelow(File file, FileFilter filter, IProgressMonitor monitor, boolean addSubFolders, boolean checkHasInit) { ++ public static List[] getPyFilesBelow(File file, FileFilter filter, IProgressMonitor monitor, boolean addSubFolders, boolean checkHasInit) { + return getPyFilesBelow(file, filter, monitor, addSubFolders, 0, checkHasInit); + } + /** +@@ -788,13 +789,12 @@ + * @param addSubFolders: indicates if sub-folders should be added + * @return tuple with files in pos 0 and folders in pos 1 + */ +- @SuppressWarnings("unchecked") +- private static List[] getPyFilesBelow(File file, FileFilter filter, IProgressMonitor monitor, boolean addSubFolders, int level, boolean checkHasInit) { ++ private static List[] getPyFilesBelow(File file, FileFilter filter, IProgressMonitor monitor, boolean addSubFolders, int level, boolean checkHasInit) { + if (monitor == null) { + monitor = new NullProgressMonitor(); + } +- List filesToReturn = new ArrayList(); +- List folders = new ArrayList(); ++ List filesToReturn = new ArrayList(); ++ List folders = new ArrayList(); + + if (file.exists() == true) { + +@@ -809,7 +809,7 @@ + + boolean hasInit = false; + +- List foldersLater = new LinkedList(); ++ List foldersLater = new LinkedList(); + + for (int i = 0; i < files.length; i++) { + File file2 = files[i]; +@@ -836,7 +836,7 @@ + for (Iterator iter = foldersLater.iterator(); iter.hasNext();) { + File file2 = (File) iter.next(); + if(file2.isDirectory() && addSubFolders){ +- List[] below = getPyFilesBelow(file2, filter, monitor, addSubFolders, level+1, checkHasInit); ++ List[] below = getPyFilesBelow(file2, filter, monitor, addSubFolders, level+1, checkHasInit); + filesToReturn.addAll(below[0]); + folders.addAll(below[1]); + monitor.worked(1); +@@ -866,7 +866,6 @@ + private List listeners = new ArrayList(); + + +- @SuppressWarnings("unchecked") + public void addTestListener(ITestRunListener listener) { + listeners.add(listener); + } +@@ -914,7 +913,7 @@ + * @param file the file we want to get info on. + * @return a tuple with the pythonnature to be used and the name of the module represented by the file in that scenario. + */ +- public static Tuple getInfoForFile(File file){ ++ public static Tuple getInfoForFile(File file){ + String modName = null; + IInterpreterManager pythonInterpreterManager = getPythonInterpreterManager(); + IInterpreterManager jythonInterpreterManager = getJythonInterpreterManager(); +@@ -937,21 +936,21 @@ + } + } + if(modName != null){ +- return new Tuple(systemPythonNature, modName); ++ return new Tuple(systemPythonNature, modName); + }else{ + //unable to discover it + try { + // the default one is python (actually, this should never happen, but who knows) + pythonInterpreterManager.getDefaultInterpreter(); + modName = getModNameFromFile(file); +- return new Tuple(pySystemPythonNature, modName); ++ return new Tuple(pySystemPythonNature, modName); + } catch (Exception e) { + //the python interpreter manager is not valid or not configured + try { + // the default one is jython + jythonInterpreterManager.getDefaultInterpreter(); + modName = getModNameFromFile(file); +- return new Tuple(jySystemPythonNature, modName); ++ return new Tuple(jySystemPythonNature, modName); + } catch (Exception e1) { + // ok, nothing to do about it, no interpreter is configured + return null; +@@ -1046,11 +1045,12 @@ + throw new RuntimeException(e); + } + +- return REF.readFromInputStreamAndCloseIt(new ICallback(){ ++ return REF.readFromInputStreamAndCloseIt(new ICallback(){ + +- public Object call(ObjectInputStream arg) { ++ public Object call(Object arg) { + try{ +- return arg.readObject(); ++ ObjectInputStream arg1 = (ObjectInputStream) arg; ++ return arg1.readObject(); + }catch(Exception e){ + throw new RuntimeException(e); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/PydevPrefsInitializer.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/PydevPrefsInitializer.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/PydevPrefsInitializer.java 2006-09-12 02:15:51.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/PydevPrefsInitializer.java 2006-11-05 20:59:43.000000000 +0100 +@@ -14,7 +14,6 @@ + public class PydevPrefsInitializer extends AbstractPreferenceInitializer{ + + +- @Override + public void initializeDefaultPreferences() { + Preferences node = new DefaultScope().getNode(PydevPlugin.DEFAULT_PYDEV_SCOPE); + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/StubInterpreterManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/StubInterpreterManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/plugin/StubInterpreterManager.java 2006-06-24 16:43:07.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/plugin/StubInterpreterManager.java 2006-11-05 20:59:43.000000000 +0100 +@@ -46,7 +46,7 @@ + return false; + } + +- public void clearAllBut(List allButTheseInterpreters) { ++ public void clearAllBut(List allButTheseInterpreters) { + } + + public boolean isJython() { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimpleExeRunner.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimpleExeRunner.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimpleExeRunner.java 2006-06-27 01:40:46.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimpleExeRunner.java 2006-11-05 20:59:43.000000000 +0100 +@@ -15,8 +15,7 @@ + + public class SimpleExeRunner extends SimpleRunner{ + +- @Override +- public Tuple runAndGetOutput(String script, String[] args, File workingDir, IProject project) { ++ public Tuple runAndGetOutput(String script, String[] args, File workingDir, IProject project) { + String executionString = getCommandLineAsString(new String[]{script}, args); + return runAndGetOutput(executionString, workingDir, project); + } +@@ -65,20 +64,20 @@ + * @param paths the windows paths to be converted to cygwin. + * @return a list of changed paths converted to cygwin. + */ +- public List convertToCygwinPath(String cygpathLoc, String ... paths){ ++ public List convertToCygwinPath(String cygpathLoc, String [] paths){ + for (int i = 0; i < paths.length; i++) { + paths[i] = StringUtils.replaceAllSlashes(paths[i]); + } +- ArrayList ret = new ArrayList(); ++ ArrayList ret = new ArrayList(); + +- Tuple output = runAndGetOutput(cygpathLoc, paths, (File)null, (IProject)null); +- if(output.o2 != null && output.o2.length() > 0){ ++ Tuple output = runAndGetOutput(cygpathLoc, paths, (File)null, (IProject)null); ++ if(output.o2 != null && ((String) output.o2).length() > 0){ + throw new RuntimeException("Error converting windows paths to cygwin paths: "+output.o2+".\nCygpath location:"+cygpathLoc); + } +- if(output.o1 == null || output.o1.length() == 0){ ++ if(output.o1 == null || ((String) output.o1).length() == 0){ + throw new RuntimeException("Unable to get the output.\nCygpath location:"+cygpathLoc); + } +- StringTokenizer tokenizer = new StringTokenizer(output.o1, "\r\n"); ++ StringTokenizer tokenizer = new StringTokenizer((String) output.o1, "\r\n"); + while(tokenizer.hasMoreTokens()){ + String tok = tokenizer.nextToken(); + ret.add(tok.trim()); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimpleJythonRunner.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimpleJythonRunner.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimpleJythonRunner.java 2006-09-19 03:41:12.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimpleJythonRunner.java 2006-11-05 20:59:43.000000000 +0100 +@@ -5,6 +5,7 @@ + + import java.io.File; + import java.io.IOException; ++import java.util.Iterator; + + import org.eclipse.core.resources.IProject; + import org.eclipse.core.runtime.IProgressMonitor; +@@ -17,7 +18,7 @@ + + public class SimpleJythonRunner extends SimpleRunner{ + +- public Tuple runAndGetOutputWithJar(String script, String jythonJar, String args, File workingDir, IProject project, IProgressMonitor monitor) { ++ public Tuple runAndGetOutputWithJar(String script, String jythonJar, String args, File workingDir, IProject project, IProgressMonitor monitor) { + //"C:\Program Files\Java\jdk1.5.0_04\bin\java.exe" "-Dpython.home=C:\bin\jython21" + //-classpath "C:\bin\jython21\jython.jar;%CLASSPATH%" org.python.util.jython %ARGS% + //used just for getting info without any classpath nor pythonpath +@@ -32,7 +33,7 @@ + "org.python.util.jython" + ,script + }; +- String executionString = getCommandLineAsString(s); ++ String executionString = getCommandLineAsString(s, new String [] {}); + + return runAndGetOutput(executionString, workingDir, project, monitor); + } catch (Exception e) { +@@ -40,8 +41,7 @@ + } + + } +- @Override +- public Tuple runAndGetOutput(String script, String[] args, File workingDir, IProject project) { ++ public Tuple runAndGetOutput(String script, String[] args, File workingDir, IProject project) { + //"java.exe" -classpath "C:\bin\jython21\jython.jar" -Dpython.path xxx;xxx;xxx org.python.util.jython script %ARGS% + + try { +@@ -78,7 +78,9 @@ + + StringBuffer jythonPath = new StringBuffer(); + String pathSeparator = SimpleRunner.getPythonPathSeparator(); +- for (String lib : info.libs) { ++ for (Iterator iter = info.libs.iterator(); iter.hasNext();) { ++ String lib = (String) iter.next(); ++ + if(jythonPath.length() != 0){ + jythonPath.append(pathSeparator); + } +@@ -110,7 +112,7 @@ + "org.python.util.jython", + script + }; +- String executionString = getCommandLineAsString(s); ++ String executionString = getCommandLineAsString(s, new String [] {}); + + return executionString; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimplePythonRunner.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimplePythonRunner.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimplePythonRunner.java 2006-06-27 01:40:46.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimplePythonRunner.java 2006-11-05 20:59:43.000000000 +0100 +@@ -40,7 +40,7 @@ + * + * @return a string with the output of the process (stdout) + */ +- public Tuple runAndGetOutput(String script, String[] args, File workingDir, IProject project) { ++ public Tuple runAndGetOutput(String script, String[] args, File workingDir, IProject project) { + String executionString = makeExecutableCommandStr(script, args); + return runAndGetOutput(executionString, workingDir, project); + } +@@ -72,7 +72,7 @@ + * + * @return the stdout of the run (if any) + */ +- public Tuple runAndGetOutputWithInterpreter(String interpreter, String script, String[] args, File workingDir, IProject project, IProgressMonitor monitor) { ++ public Tuple runAndGetOutputWithInterpreter(String interpreter, String script, String[] args, File workingDir, IProject project, IProgressMonitor monitor) { + monitor.setTaskName("Mounting executable string..."); + monitor.worked(5); + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimpleRunner.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimpleRunner.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/runners/SimpleRunner.java 2006-06-27 01:40:46.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/runners/SimpleRunner.java 2006-11-05 20:59:43.000000000 +0100 +@@ -64,7 +64,7 @@ + + DebugPlugin defaultPlugin = DebugPlugin.getDefault(); + if(defaultPlugin != null){ +- Map env = getDefaultSystemEnv(defaultPlugin); ++ Map env = getDefaultSystemEnv(defaultPlugin); + + env.put("PYTHONPATH", pythonPathEnvStr); //put the environment + return getMapEnvAsArray(env); +@@ -95,13 +95,12 @@ + /** + * @return a map with the env variables for the system + */ +- @SuppressWarnings("unchecked") +- private Map getDefaultSystemEnv(DebugPlugin defaultPlugin) throws CoreException { ++ private Map getDefaultSystemEnv(DebugPlugin defaultPlugin) throws CoreException { + if(defaultPlugin != null){ + ILaunchManager launchManager = defaultPlugin.getLaunchManager(); + + // build base environment +- Map env = new HashMap(); ++ Map env = new HashMap(); + env.putAll(launchManager.getNativeEnvironment()); + + // Add variables from config +@@ -150,7 +149,7 @@ + * @param args - other arguments to be added to the command line (may be null) + * @return + */ +- public static String getCommandLineAsString(String[] commandLine, String ... args) { ++ public static String getCommandLineAsString(String[] commandLine, String [] args) { + if(args != null && args.length > 0){ + String[] newCommandLine = new String[commandLine.length + args.length]; + System.arraycopy(commandLine, 0, newCommandLine, 0, commandLine.length); +@@ -242,7 +241,7 @@ + * @return an array with the formatted map + */ + private String[] getMapEnvAsArray(Map env) { +- List strings= new ArrayList(env.size()); ++ List strings= new ArrayList(env.size()); + for(Iterator iter= env.entrySet().iterator(); iter.hasNext(); ) { + Map.Entry entry = (Map.Entry) iter.next(); + StringBuffer buffer= new StringBuffer((String) entry.getKey()); +@@ -250,34 +249,34 @@ + strings.add(buffer.toString()); + } + +- return strings.toArray(new String[strings.size()]); ++ return (String [])strings.toArray(new String[strings.size()]); + } + + /** + * shortcut + */ +- public Tuple runAndGetOutput(String executionString, File workingDir, IProgressMonitor monitor) { ++ public Tuple runAndGetOutput(String executionString, File workingDir, IProgressMonitor monitor) { + return runAndGetOutput(executionString, workingDir, null, monitor); + } + + /** + * shortcut + */ +- public Tuple runAndGetOutput(String executionString, File workingDir) { ++ public Tuple runAndGetOutput(String executionString, File workingDir) { + return runAndGetOutput(executionString, workingDir, null, new NullProgressMonitor()); + } + + /** + * shortcut + */ +- public Tuple runAndGetOutput(String executionString, File workingDir, IProject project) { ++ public Tuple runAndGetOutput(String executionString, File workingDir, IProject project) { + return runAndGetOutput(executionString, workingDir, project, new NullProgressMonitor()); + } + + /** + * shortcut + */ +- public Tuple runAndGetOutput(String script, String[] args, File workingDir) { ++ public Tuple runAndGetOutput(String script, String[] args, File workingDir) { + return runAndGetOutput(script, args, workingDir, null); + } + +@@ -292,7 +291,7 @@ + * + * @return the string that is the output of the process (stdout) and the stderr (o2) + */ +- public Tuple runAndGetOutput(String executionString, File workingDir, IProject project, IProgressMonitor monitor) { ++ public Tuple runAndGetOutput(String executionString, File workingDir, IProject project, IProgressMonitor monitor) { + monitor.setTaskName("Executing: "+executionString); + monitor.worked(5); + Process process = null; +@@ -337,7 +336,7 @@ + } catch (Exception e) { + //ignore + } +- return new Tuple(std.contents.toString(), err.contents.toString()); ++ return new Tuple(std.contents.toString(), err.contents.toString()); + + } else { + try { +@@ -348,7 +347,7 @@ + } + + } +- return new Tuple("","Error creating process - got null process("+ executionString + ")"); //no output ++ return new Tuple("","Error creating process - got null process("+ executionString + ")"); //no output + } + + /** +@@ -361,6 +360,6 @@ + * + * @return a string with the output of the process (stdout) + */ +- public abstract Tuple runAndGetOutput(String script, String args[], File workingDir, IProject project); ++ public abstract Tuple runAndGetOutput(String script, String args[], File workingDir, IProject project); + + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/dialogs/PythonModulePickerDialog.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/dialogs/PythonModulePickerDialog.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/dialogs/PythonModulePickerDialog.java 2006-01-20 01:27:43.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/dialogs/PythonModulePickerDialog.java 2006-11-05 20:59:43.000000000 +0100 +@@ -78,7 +78,7 @@ + + if (container.isAccessible()) { + try { +- List children = new ArrayList(); ++ List children = new ArrayList(); + + IResource[] members = container.members(); + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/dialogs/PythonPackageSelectionDialog.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/dialogs/PythonPackageSelectionDialog.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/dialogs/PythonPackageSelectionDialog.java 2006-01-21 15:06:26.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/dialogs/PythonPackageSelectionDialog.java 2006-11-05 20:59:43.000000000 +0100 +@@ -37,7 +37,6 @@ + + public PythonPackageSelectionDialog(Shell parent, final boolean selectOnlySourceFolders) { + super(parent, new CopiedWorkbenchLabelProvider(){ +- @Override + public String getText(Object element) { + if(element instanceof Package){ + element = ((Package)element).folder; +@@ -49,7 +48,6 @@ + return super.getText(element); + } + +- @Override + public Image getImage(Object element) { + if(element instanceof Package){ + element = ((Package)element).folder; +@@ -108,10 +106,12 @@ + //workspace root + if(parentElement instanceof IWorkspaceRoot){ + this.workspaceRoot = (IWorkspaceRoot) parentElement; +- List ret = new ArrayList(); ++ List ret = new ArrayList(); + + IProject[] projects = workspaceRoot.getProjects(); +- for (IProject project : projects) { ++ for (int i = 0; i < projects.length; i++) { ++ IProject project = projects[i]; ++ + PythonNature nature = PythonNature.getPythonNature(project); + if(nature != null){ + ret.add(project); +@@ -123,13 +123,16 @@ + + //project + if(parentElement instanceof IProject){ +- List ret = new ArrayList(); ++ List ret = new ArrayList(); + IProject project = (IProject) parentElement; + IPythonPathNature nature = PythonNature.getPythonPathNature(project); + if(nature != null){ + try { + String[] srcPaths = PythonNature.getStrAsStrItems(nature.getProjectSourcePath()); +- for (String str : srcPaths) { ++ for (int i = 0; i < srcPaths.length; i++) { ++ String str = srcPaths[i]; ++ ++ + IResource resource = this.workspaceRoot.findMember(new Path(str)); + if(resource instanceof IFolder){ + IFolder folder = (IFolder) resource; +@@ -172,10 +175,12 @@ + + if(parentElement instanceof IFolder){ + IFolder f = (IFolder) parentElement; +- ArrayList ret = new ArrayList(); ++ ArrayList ret = new ArrayList(); + try { + IResource[] resources = f.members(); +- for (IResource resource : resources) { ++ for (int i = 0; i < resources.length; i++) { ++ IResource resource = resources[i]; ++ + if(resource instanceof IFolder){ + ret.add(new Package((IFolder) resource, sourceFolder)); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/interpreters/AbstractInterpreterManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/interpreters/AbstractInterpreterManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/interpreters/AbstractInterpreterManager.java 2006-06-24 16:43:07.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/interpreters/AbstractInterpreterManager.java 2006-11-05 20:59:43.000000000 +0100 +@@ -8,6 +8,7 @@ + import java.lang.reflect.InvocationTargetException; + import java.util.ArrayList; + import java.util.HashMap; ++import java.util.Iterator; + import java.util.List; + import java.util.Map; + +@@ -22,6 +23,7 @@ + import org.eclipse.swt.widgets.Display; + import org.eclipse.swt.widgets.Shell; + import org.python.pydev.core.ExtensionHelper; ++import org.python.pydev.core.IInterpreterInfo; + import org.python.pydev.core.IInterpreterManager; + import org.python.pydev.core.IPythonNature; + import org.python.pydev.core.Tuple; +@@ -41,19 +43,20 @@ + /** + * This is the cache, that points from an interpreter to its information. + */ +- private Map exeToInfo = new HashMap(); ++ private Map exeToInfo = new HashMap(); + private Preferences prefs; + private String[] interpretersFromPersistedString; + + /** + * Constructor + */ +- @SuppressWarnings("unchecked") + public AbstractInterpreterManager(Preferences prefs) { + this.prefs = prefs; + prefs.setDefault(getPreferenceName(), ""); +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); +- for (IInterpreterObserver observer : participants) { ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); ++ for (Iterator iter = participants.iterator(); iter.hasNext();) { ++ IInterpreterObserver observer = (IInterpreterObserver) iter.next(); ++ + observer.notifyInterpreterManagerRecreated(this); + } + prefs.addPropertyChangeListener(new Preferences.IPropertyChangeListener(){ +@@ -90,16 +93,20 @@ + } + } + +- public void clearAllBut(List allButTheseInterpreters) { ++ public void clearAllBut(List allButTheseInterpreters) { + synchronized(exeToInfo){ +- ArrayList toRemove = new ArrayList(); +- for (String interpreter : exeToInfo.keySet()) { ++ ArrayList toRemove = new ArrayList(); ++ for (Iterator iter = exeToInfo.keySet().iterator(); iter.hasNext();) { ++ String interpreter = (String) iter.next(); ++ + if(!allButTheseInterpreters.contains(interpreter)){ + toRemove.add(interpreter); + } + } + //we do not want to remove it while we are iterating... +- for (Object object : toRemove) { ++ for (Iterator iter = toRemove.iterator(); iter.hasNext();) { ++ Object object = (Object) iter.next(); ++ + exeToInfo.remove(object); + } + } +@@ -129,7 +136,8 @@ + } + interpreter = interpreter.toLowerCase(); + String[] interpreters = getInterpreters(); +- for (String str : interpreters) { ++ for (int i = 0; i < interpreters.length; i++) { ++ String str = interpreters[i]; + if(str.toLowerCase().equals(interpreter)){ + return true; + } +@@ -140,7 +148,7 @@ + /** + * @see org.python.pydev.core.IInterpreterManager#getDefaultInterpreterInfo(org.eclipse.core.runtime.IProgressMonitor) + */ +- public InterpreterInfo getDefaultInterpreterInfo(IProgressMonitor monitor) { ++ public IInterpreterInfo getDefaultInterpreterInfo(IProgressMonitor monitor) { + String interpreter = getDefaultInterpreter(); + return getInterpreterInfo(interpreter, monitor); + } +@@ -154,35 +162,35 @@ + * @return the interpreter info for the executable + * @throws CoreException + */ +- public abstract Tuple createInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException; ++ public abstract Tuple createInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException; + + /** + * Creates the interpreter info from the output. Checks for errors. + */ +- protected static InterpreterInfo createInfoFromOutput(IProgressMonitor monitor, Tuple outTup) { +- if(outTup.o1 == null || outTup.o1.trim().length() == 0){ ++ protected static InterpreterInfo createInfoFromOutput(IProgressMonitor monitor, Tuple outTup) { ++ if(outTup.o1 == null || ((String)outTup.o1).trim().length() == 0){ + throw new RuntimeException( + "No output was in the standard output when trying to create the interpreter info.\n" + + "The error output contains:>>"+outTup.o2+"<<"); + } +- InterpreterInfo info = InterpreterInfo.fromString(outTup.o1); ++ InterpreterInfo info = InterpreterInfo.fromString(((String)outTup.o1)); + return info; + } + + /** + * @see org.python.pydev.core.IInterpreterManager#getInterpreterInfo(java.lang.String) + */ +- public InterpreterInfo getInterpreterInfo(String executable, IProgressMonitor monitor) { ++ public IInterpreterInfo getInterpreterInfo(String executable, IProgressMonitor monitor) { + synchronized(lock){ + InterpreterInfo info = (InterpreterInfo) exeToInfo.get(executable); + if(info == null){ + monitor.worked(5); + //ok, we have to get the info from the executable (and let's cache results for future use)... +- Tuple tup = null; ++ Tuple tup = null; + try { + + tup = createInterpreterInfo(executable, monitor); +- info = tup.o1; ++ info = (InterpreterInfo) tup.o1; + + } catch (Exception e) { + PydevPlugin.log(e); +@@ -224,7 +232,7 @@ + */ + public String addInterpreter(String executable, IProgressMonitor monitor) { + exeToInfo.remove(executable); //always clear it +- InterpreterInfo info = getInterpreterInfo(executable, monitor); ++ InterpreterInfo info = (InterpreterInfo) getInterpreterInfo(executable, monitor); + return info.executableOrJar; + } + +@@ -243,14 +251,16 @@ + } + + if(persistedCache == null || persistedCache.equals(persisted) == false){ +- List ret = new ArrayList(); ++ List ret = new ArrayList(); + + try { +- List list = new ArrayList(); ++ List list = new ArrayList(); + String[] strings = persisted.split("&&&&&"); + + //first, get it... +- for (String string : strings) { ++ for (int i = 0; i < strings.length; i++) { ++ String string = strings[i]; ++ + try { + list.add(InterpreterInfo.fromString(string)); + } catch (Exception e) { +@@ -264,7 +274,9 @@ + } + + //then, put it in cache +- for (InterpreterInfo info: list) { ++ for (Iterator iter = list.iterator(); iter.hasNext();) { ++ InterpreterInfo info = (InterpreterInfo) iter.next(); ++ + if(info != null && info.executableOrJar != null){ + this.exeToInfo.put(info.executableOrJar, info); + ret.add(info.executableOrJar); +@@ -272,7 +284,9 @@ + } + + //and at last, restore the system info +- for (final InterpreterInfo info: list) { ++ for (Iterator iter = list.iterator(); iter.hasNext();) { ++ final InterpreterInfo info = (InterpreterInfo) iter.next(); ++ + try { + info.modulesManager = (SystemModulesManager) PydevPlugin.readFromPlatformFile(info.getExeAsFileSystemValidPath()); + } catch (Exception e) { +@@ -314,7 +328,7 @@ + } + + persistedCache = persisted; +- persistedCacheRet = ret.toArray(new String[0]); ++ persistedCacheRet = (String[]) ret.toArray(new String[0]); + } + } + return persistedCacheRet; +@@ -325,8 +339,10 @@ + */ + public String getStringToPersist(String[] executables) { + StringBuffer buf = new StringBuffer(); +- for (String exe : executables) { +- InterpreterInfo info = this.exeToInfo.get(exe); ++ for (int i = 0; i < executables.length; i++) { ++ String exe = executables[i]; ++ ++ InterpreterInfo info = (InterpreterInfo) this.exeToInfo.get(exe); + if(info!=null){ + PydevPlugin.writeToPlatformFile(info.modulesManager, info.getExeAsFileSystemValidPath()); + buf.append(info.toString()); +@@ -375,14 +391,15 @@ + /** + * @see org.python.pydev.core.IInterpreterManager#restorePythopathFor(java.lang.String, org.eclipse.core.runtime.IProgressMonitor) + */ +- @SuppressWarnings("unchecked") + public void restorePythopathFor(String defaultSelectedInterpreter, IProgressMonitor monitor) { + synchronized(lock){ +- final InterpreterInfo info = getInterpreterInfo(defaultSelectedInterpreter, monitor); ++ final InterpreterInfo info = (InterpreterInfo) getInterpreterInfo(defaultSelectedInterpreter, monitor); + info.restorePythonpath(monitor); //that's it, info.modulesManager contains the SystemModulesManager + +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); +- for (IInterpreterObserver observer : participants) { ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); ++ for (Iterator iter = participants.iterator(); iter.hasNext();) { ++ IInterpreterObserver observer = (IInterpreterObserver) iter.next(); ++ + try { + observer.notifyDefaultPythonpathRestored(this, defaultSelectedInterpreter, monitor); + } catch (Exception e) { +@@ -391,8 +408,10 @@ + } + + //update the natures... +- List pythonNatures = PythonNature.getAllPythonNatures(); +- for (IPythonNature nature : pythonNatures) { ++ List pythonNatures = PythonNature.getAllPythonNatures(); ++ for (Iterator iter = pythonNatures.iterator(); iter.hasNext();) { ++ IPythonNature nature = (IPythonNature) iter.next(); ++ + try { + //if they have the same type of the interpreter manager. + if (this.isPython() == nature.isPython() || this.isJython() == nature.isJython()) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/interpreters/JythonInterpreterManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/interpreters/JythonInterpreterManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/interpreters/JythonInterpreterManager.java 2006-09-03 02:26:08.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/interpreters/JythonInterpreterManager.java 2006-11-05 20:59:43.000000000 +0100 +@@ -7,6 +7,7 @@ + package org.python.pydev.ui.interpreters; + + import java.io.File; ++import java.util.Iterator; + import java.util.List; + + import org.eclipse.core.runtime.CoreException; +@@ -26,12 +27,10 @@ + super(prefs); + } + +- @Override + protected String getPreferenceName() { + return JYTHON_INTERPRETER_PATH; + } + +- @Override + protected String getNotConfiguredInterpreterMsg() { + return "Interpreter is not properly configured!\r\n" + + "Please go to window->preferences->PyDev->Jython Interpreters and configure it.\r\n" + +@@ -39,8 +38,7 @@ + "project properties to the project you want (e.g.: Python project)."; + } + +- @Override +- public TuplecreateInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { ++ public Tuple createInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { + return doCreateInterpreterInfo(executable, monitor); + } + +@@ -53,7 +51,7 @@ + * + * @throws CoreException + */ +- public static Tuple doCreateInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { ++ public static Tuple doCreateInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { + boolean isJythonExecutable = InterpreterInfo.isJythonExecutable(executable); + + if(!isJythonExecutable){ +@@ -65,16 +63,18 @@ + } + + //gets the info for the python side +- Tuple outTup = new SimpleJythonRunner().runAndGetOutputWithJar(REF.getFileAbsolutePath(script), executable, null, null, null, monitor); +- String output = outTup.o1; ++ Tuple outTup = new SimpleJythonRunner().runAndGetOutputWithJar(REF.getFileAbsolutePath(script), executable, null, null, null, monitor); ++ String output = (String) outTup.o1; + + InterpreterInfo info = createInfoFromOutput(monitor, outTup); + //the executable is the jar itself + info.executableOrJar = executable; + + //we have to find the jars before we restore the compiled libs +- List jars = JavaVmLocationFinder.findDefaultJavaJars(); +- for (File jar : jars) { ++ List jars = JavaVmLocationFinder.findDefaultJavaJars(); ++ for (Iterator iter = jars.iterator(); iter.hasNext();) { ++ File jar = (File) iter.next(); ++ + info.libs.add(REF.getFileAbsolutePath(jar)); + } + +@@ -82,10 +82,9 @@ + info.restoreCompiledLibs(monitor); + + +- return new Tuple(info, output); ++ return new Tuple(info, output); + } + +- @Override + public boolean canGetInfoOnNature(IPythonNature nature) { + try { + return nature.isJython(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/interpreters/PythonInterpreterManager.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/interpreters/PythonInterpreterManager.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/interpreters/PythonInterpreterManager.java 2006-01-11 11:57:39.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/interpreters/PythonInterpreterManager.java 2006-11-05 20:59:43.000000000 +0100 +@@ -24,12 +24,10 @@ + super(prefs); + } + +- @Override + protected String getPreferenceName() { + return PYTHON_INTERPRETER_PATH; + } + +- @Override + protected String getNotConfiguredInterpreterMsg() { + return "Interpreter is not properly configured!\n" + + "Please go to window->preferences->PyDev->Python Interpreters and configure it.\n" + +@@ -37,8 +35,7 @@ + "project properties to the project you want (e.g.: Jython project)."; + } + +- @Override +- public TuplecreateInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { ++ public Tuple createInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { + return doCreateInterpreterInfo(executable, monitor); + } + +@@ -49,7 +46,7 @@ + * @return the created interpreter info + * @throws CoreException + */ +- public static Tuple doCreateInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { ++ public static Tuple doCreateInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { + boolean isJythonExecutable = InterpreterInfo.isJythonExecutable(executable); + if(isJythonExecutable){ + throw new RuntimeException("A jar cannot be used in order to get the info for the python interpreter."); +@@ -57,15 +54,14 @@ + + File script = PydevPlugin.getScriptWithinPySrc("interpreterInfo.py"); + +- Tuple outTup = new SimplePythonRunner().runAndGetOutputWithInterpreter(executable, REF.getFileAbsolutePath(script), null, null, null, monitor); ++ Tuple outTup = new SimplePythonRunner().runAndGetOutputWithInterpreter(executable, REF.getFileAbsolutePath(script), null, null, null, monitor); + InterpreterInfo info = createInfoFromOutput(monitor, outTup); + info.restoreCompiledLibs(monitor); + +- return new Tuple(info, outTup.o1); ++ return new Tuple(info, outTup.o1); + } + + +- @Override + public boolean canGetInfoOnNature(IPythonNature nature) { + try { + return nature.isPython(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/PyProjectProperties.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/PyProjectProperties.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/PyProjectProperties.java 2006-07-15 21:38:33.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/PyProjectProperties.java 2006-11-05 20:59:43.000000000 +0100 +@@ -103,7 +103,6 @@ + return new DirectoryDialog(getShell()); + } + +- @Override + protected Object getSelectionDialogAddJar() { + return new FileDialog(getShell()); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/PyProjectPythonDetails.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/PyProjectPythonDetails.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/PyProjectPythonDetails.java 2006-09-17 02:49:00.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/PyProjectPythonDetails.java 2006-11-05 20:59:43.000000000 +0100 +@@ -120,7 +120,6 @@ + return (IProject)getElement().getAdapter(IProject.class); + } + +- @Override + public Control createContents(Composite p) { + Control contents = radioController.doCreateContents(p); + setSelected(); +@@ -183,7 +182,7 @@ + "it before changing your project type."; + final String managerRelatedName = interpreterManager.getManagerRelatedName(); + MessageDialog.openError(display.getActiveShell(), "Invalid Interpreter", +- StringUtils.format(msg, managerRelatedName, managerRelatedName)); ++ StringUtils.format(msg, new Object [] {managerRelatedName, managerRelatedName})); + } + + }); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/AbstractInterpreterEditor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/AbstractInterpreterEditor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/AbstractInterpreterEditor.java 2006-09-19 03:11:55.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/AbstractInterpreterEditor.java 2006-11-05 20:59:43.000000000 +0100 +@@ -617,15 +617,13 @@ + return null; + } + +- @Override + protected void doStore() { + String s = createList(list.getItems()); + if (s != null){ + interpreterManager.setPersistedString(s); + } + } +- +- @Override ++ + protected void doLoad() { + if (list != null) { + String s = interpreterManager.getPersistedString(); +@@ -643,14 +641,12 @@ + + /** Overriden + */ +- @Override + protected String createList(String[] executables) { + return interpreterManager.getStringToPersist(executables); + } + + /** Overriden + */ +- @Override + protected String[] parseString(String stringList) { + return interpreterManager.getInterpretersFromPersistedString(stringList); + } +@@ -664,7 +660,6 @@ + this.logger = logger; + } + +- @Override + public void beginTask(String name, int totalWork) { + super.beginTask(name, totalWork); + logger.print("- Beggining task:"); +@@ -673,14 +668,12 @@ + logger.println(totalWork); + } + +- @Override + public void setTaskName(String name) { + super.setTaskName(name); + logger.print("- Setting task name:"); + logger.println(name); + } + +- @Override + public void subTask(String name) { + super.subTask(name); + logger.print("- Sub Task:"); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/AbstractInterpreterPreferencesPage.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/AbstractInterpreterPreferencesPage.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/AbstractInterpreterPreferencesPage.java 2006-09-16 17:52:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/AbstractInterpreterPreferencesPage.java 2006-11-05 20:59:43.000000000 +0100 +@@ -104,7 +104,7 @@ + * @param allButTheseInterpreters + * @param monitor + */ +- protected void doClear(final List allButTheseInterpreters, IProgressMonitor monitor){ ++ protected void doClear(final List allButTheseInterpreters, IProgressMonitor monitor){ + IInterpreterManager iMan = getInterpreterManager(); + iMan.clearAllBut(allButTheseInterpreters); + } +@@ -143,7 +143,7 @@ + protected void restoreModules() { + + if(pathEditor.getExesList().getItemCount() <= 0){ +- doClear(new ArrayList(),new NullProgressMonitor()); ++ doClear(new ArrayList(),new NullProgressMonitor()); + return; + + } else{ +@@ -152,10 +152,12 @@ + ProgressMonitorDialog monitorDialog = new ProgressMonitorDialog(this.getShell()); + monitorDialog.setBlockOnOpen(false); + +- final List exesToKeep = new ArrayList(); ++ final List exesToKeep = new ArrayList(); + org.eclipse.swt.widgets.List exesList = pathEditor.getExesList(); + String[] items = exesList.getItems(); +- for (String exeToKeep : items) { ++ for (int i = 0; i < items.length; i++) { ++ String exeToKeep = items[i]; ++ + exesToKeep.add(exeToKeep); + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/InterpreterInfo.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/InterpreterInfo.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/InterpreterInfo.java 2006-10-30 17:10:25.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/InterpreterInfo.java 2006-11-05 21:52:44.000000000 +0100 +@@ -55,7 +55,7 @@ + /** + * folders - they should be passed to the pythonpath + */ +- public java.util.List libs = new ArrayList(); ++ public java.util.List libs = new ArrayList(); + + /** + * Those libraries are not really used in python (they are found in the system pythonpath), and +@@ -66,7 +66,7 @@ + * + * for jython, the jars should appear here. + */ +- public java.util.List dllLibs = new ArrayList(); ++ public java.util.List dllLibs = new ArrayList(); + + /** + * __builtin__, os, math, etc for python +@@ -76,7 +76,7 @@ + * + * for jython, this should + */ +- public Set forcedLibs = new TreeSet(); ++ public Set forcedLibs = new TreeSet(); + + /** + * module management for the system is always binded to an interpreter (binded in this class) +@@ -86,7 +86,7 @@ + */ + public SystemModulesManager modulesManager = new SystemModulesManager(forcedLibs); + +- public static ICallback, List>> configurePathsCallback = null; ++ public static ICallback configurePathsCallback = null; + + /** + * This is the version for the python interpreter (it is regarded as a String with Major and Minor version +@@ -94,18 +94,18 @@ + */ + private String version; + +- public InterpreterInfo(String version, String exe, Collection libs0){ ++ public InterpreterInfo(String version, String exe, Collection libs0){ + this.executableOrJar = exe; + this.version = version; + libs.addAll(libs0); + } + +- public InterpreterInfo(String version, String exe, Collection libs0, Collection dlls){ ++ public InterpreterInfo(String version, String exe, Collection libs0, Collection dlls){ + this(version, exe, libs0); + dllLibs.addAll(dlls); + } + +- public InterpreterInfo(String version, String exe, List libs0, List dlls, List forced) { ++ public InterpreterInfo(String version, String exe, List libs0, List dlls, List forced) { + this(version, exe, libs0, dlls); + forcedLibs.addAll(forced); + } +@@ -177,8 +177,8 @@ + + + +- final ArrayList l = new ArrayList(); +- final ArrayList toAsk = new ArrayList(); ++ final ArrayList l = new ArrayList(); ++ final ArrayList toAsk = new ArrayList(); + for (int i = 1; i < exeAndLibs1.length; i++) { //start at 1 (0 is exe) + String trimmed = exeAndLibs1[i].trim(); + if(trimmed.length() > 0){ +@@ -206,7 +206,7 @@ + + if(ProjectModulesManager.IN_TESTS){ + if(InterpreterInfo.configurePathsCallback != null){ +- InterpreterInfo.configurePathsCallback.call(new Tuple, List>(toAsk, l)); ++ InterpreterInfo.configurePathsCallback.call(new Tuple(toAsk, l)); + } + }else{ + if(toAsk.size() > 0){ +@@ -216,9 +216,8 @@ + ListSelectionDialog dialog = new ListSelectionDialog(Display.getDefault().getActiveShell(), toAsk, + new IStructuredContentProvider(){ + +- @SuppressWarnings("unchecked") + public Object[] getElements(Object inputElement) { +- List elements = (List) inputElement; ++ List elements = (List) inputElement; + return elements.toArray(new String[0]); + } + +@@ -260,7 +259,8 @@ + dialog.open(); + Object[] result = dialog.getResult(); + l.clear(); +- for (Object string : result) { ++ for (int i = 0; i < result.length; i++) { ++ Object string = result[i]; + l.add((String) string); + } + +@@ -277,7 +277,7 @@ + } + } + +- ArrayList l1 = new ArrayList(); ++ ArrayList l1 = new ArrayList(); + if(libsSplit.length > 1){ + String dllLibs = libsSplit[1]; + String[] dllLibs1 = dllLibs.split("\\|"); +@@ -289,7 +289,7 @@ + } + } + +- ArrayList l2 = new ArrayList(); ++ ArrayList l2 = new ArrayList(); + if(forcedSplit.length > 1){ + String forcedLibs = forcedSplit[1]; + String[] forcedLibs1 = forcedLibs.split("\\|"); +@@ -352,11 +352,11 @@ + + }; + +- List dlls = new ArrayList(); ++ List dlls = new ArrayList(); + for (Iterator iter = libs.iterator(); iter.hasNext();) { + String folder = iter.next().toString(); + +- List[] below = PydevPlugin.getPyFilesBelow(new File(folder), filter, monitor, false); ++ List[] below = PydevPlugin.getPyFilesBelow(new File(folder), filter, monitor, false); + dlls.addAll(below[0]); + } + +@@ -442,7 +442,9 @@ + '>', + '|'}; + String systemValid = new String(REF.encodeBase64(executableOrJar.getBytes())); +- for (char c : invalidChars) { ++ for (int i = 0; i < invalidChars.length; i++) { ++ char c = invalidChars[i]; ++ + systemValid = systemValid.replace(c, '_'); + } + return systemValid; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/JythonInterpreterEditor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/JythonInterpreterEditor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/JythonInterpreterEditor.java 2006-02-22 01:26:15.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/JythonInterpreterEditor.java 2006-11-05 20:59:43.000000000 +0100 +@@ -15,7 +15,6 @@ + super(IInterpreterManager.JYTHON_INTERPRETER_PATH, labelText, parent, interpreterManager); + } + +- @Override + public String[] getInterpreterFilterExtensions() { + return new String[] { "*.jar", "*.*" }; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/JythonInterpreterPreferencesPage.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/JythonInterpreterPreferencesPage.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/JythonInterpreterPreferencesPage.java 2006-09-19 03:11:55.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/JythonInterpreterPreferencesPage.java 2006-11-05 20:59:43.000000000 +0100 +@@ -41,7 +41,6 @@ + addField(new DirectoryFieldEditor(IInterpreterManager.JYTHON_CACHE_DIR, "-Dpython.cachedir", getFieldEditorParent())); + } + +- @Override + protected void doRestore(String defaultSelectedInterpreter, IProgressMonitor monitor) { + IInterpreterManager iMan = getInterpreterManager(); + iMan.restorePythopathFor(defaultSelectedInterpreter, monitor); +@@ -51,7 +50,6 @@ + AbstractShell.stopServerShell(IPythonNature.JYTHON_RELATED, AbstractShell.COMPLETION_SHELL); + } + +- @Override + protected IInterpreterManager getInterpreterManager() { + return PydevPlugin.getJythonInterpreterManager(true); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/PythonInterpreterEditor.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/PythonInterpreterEditor.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/PythonInterpreterEditor.java 2006-02-22 01:26:15.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/PythonInterpreterEditor.java 2006-11-05 20:59:43.000000000 +0100 +@@ -13,7 +13,6 @@ + super(IInterpreterManager.PYTHON_INTERPRETER_PATH, labelText, parent, interpreterManager); + } + +- @Override + public String[] getInterpreterFilterExtensions() { + if (SimplePythonRunner.isWindowsPlatform()) { + return new String[] { "*.exe", "*.*" }; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/PythonInterpreterPreferencesPage.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/PythonInterpreterPreferencesPage.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/PythonInterpreterPreferencesPage.java 2006-09-16 17:52:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/pythonpathconf/PythonInterpreterPreferencesPage.java 2006-11-05 20:59:43.000000000 +0100 +@@ -42,7 +42,6 @@ + iMan.restorePythopathFor(defaultSelectedInterpreter, monitor); + } + +- @Override + protected IInterpreterManager getInterpreterManager() { + return PydevPlugin.getPythonInterpreterManager(true); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/AbstractPythonWizard.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/AbstractPythonWizard.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/AbstractPythonWizard.java 2006-01-22 19:24:34.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/AbstractPythonWizard.java 2006-11-05 20:59:43.000000000 +0100 +@@ -70,7 +70,6 @@ + /** + * User clicks Finish + */ +- @Override + public boolean performFinish() { + try { + // Create file object +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonAbstractPathPage.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonAbstractPathPage.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonAbstractPathPage.java 2006-10-30 02:06:38.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonAbstractPathPage.java 2006-11-05 21:53:38.000000000 +0100 +@@ -101,7 +101,6 @@ + } + } + +- @Override + public void setVisible(boolean visible) { + super.setVisible(visible); + if(visible == true){ +@@ -387,7 +386,8 @@ + if(nature != null){ + String[] srcPaths = PythonNature.getStrAsStrItems(nature.getProjectSourcePath()); + String relFolder = f.getFullPath().toString()+"/"; +- for (String src : srcPaths) { ++ for (int i = 0; i < srcPaths.length; i++) { ++ String src = srcPaths[i]; + if(relFolder.startsWith(src+"/")){ + return src; + } +@@ -512,7 +512,9 @@ + //there are certainly other invalid chars, but let's leave it like that... + char[] invalid = new char[]{'/', '\\', ',', '*', '(', ')', '{', '}','[',']' + }; +- for (char c : invalid){ ++ for (int i = 0; i < invalid.length; i++) { ++ char c = invalid[i]; ++ + if(text.indexOf(c) != -1){ + return "The name must not contain '"+c+"'."; + } +@@ -583,7 +585,9 @@ + } + String full = resource.getFullPath().toString(); + String[] srcPaths = PythonNature.getStrAsStrItems(nature.getProjectSourcePath()); +- for (String str : srcPaths) { ++ for (int i = 0; i < srcPaths.length; i++) { ++ String str = srcPaths[i]; ++ + if(str.equals(full)){ + validatedSourceFolder = (IContainer) resource; + return null; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonModuleWizard.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonModuleWizard.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonModuleWizard.java 2006-06-08 18:59:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonModuleWizard.java 2006-11-05 20:59:43.000000000 +0100 +@@ -22,11 +22,9 @@ + + public static final String WIZARD_ID = "org.python.pydev.ui.wizards.files.PythonModuleWizard"; + +- @Override + protected PythonAbstractPathPage createPathPage() { + return new PythonAbstractPathPage("Create a new Python module", selection){ + +- @Override + protected boolean shouldCreatePackageSelect() { + return true; + } +@@ -40,7 +38,6 @@ + * @param monitor + * @throws CoreException + */ +- @Override + protected IFile doCreateNew(IProgressMonitor monitor) throws CoreException { + IContainer validatedSourceFolder = filePage.getValidatedSourceFolder(); + if(validatedSourceFolder == null){ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonPackageWizard.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonPackageWizard.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonPackageWizard.java 2006-06-08 18:59:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonPackageWizard.java 2006-11-05 20:59:43.000000000 +0100 +@@ -19,11 +19,9 @@ + + public static final String WIZARD_ID = "org.python.pydev.ui.wizards.files.PythonPackageWizard"; + +- @Override + protected PythonAbstractPathPage createPathPage() { + return new PythonAbstractPathPage("Create a new Python package", selection){ + +- @Override + protected boolean shouldCreatePackageSelect() { + return false; + } +@@ -35,7 +33,6 @@ + * We will create the complete package path given by the user (all filled with __init__) + * and we should return the last __init__ module created. + */ +- @Override + protected IFile doCreateNew(IProgressMonitor monitor) throws CoreException { + IContainer validatedSourceFolder = filePage.getValidatedSourceFolder(); + IFile lastFile = null; +@@ -45,7 +42,9 @@ + IContainer parent = validatedSourceFolder; + String validatedName = filePage.getValidatedName(); + String[] packageParts = FullRepIterable.dotSplit(validatedName); +- for (String packagePart : packageParts) { ++ for (int i = 0; i < packageParts.length; i++) { ++ String packagePart = packageParts[i]; ++ + IFolder folder = parent.getFolder(new Path(packagePart)); + if(!folder.exists()){ + folder.create(true, true, monitor); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonSourceFolderWizard.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonSourceFolderWizard.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonSourceFolderWizard.java 2006-04-06 17:58:52.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/ui/wizards/files/PythonSourceFolderWizard.java 2006-11-05 20:59:43.000000000 +0100 +@@ -16,16 +16,13 @@ + + public static final String WIZARD_ID = "org.python.pydev.ui.wizards.files.PythonSourceFolderWizard"; + +- @Override + protected PythonAbstractPathPage createPathPage() { + return new PythonAbstractPathPage("Create a new Source Folder", selection){ + +- @Override + protected boolean shouldCreateSourceFolderSelect() { + return false; + } + +- @Override + protected boolean shouldCreatePackageSelect() { + return false; + } +@@ -33,7 +30,6 @@ + }; + } + +- @Override + protected IFile doCreateNew(IProgressMonitor monitor) throws CoreException { + IProject project = filePage.getValidatedProject(); + String name = filePage.getValidatedName(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/utils/CounterThread.java eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/utils/CounterThread.java +--- eclipse-pydev-1.2.5/org.python.pydev/src/org/python/pydev/utils/CounterThread.java 2006-06-07 23:54:33.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/src/org/python/pydev/utils/CounterThread.java 2006-11-05 20:59:43.000000000 +0100 +@@ -26,13 +26,12 @@ + setName("Callback (CounterThread)"); + } + +- @Override + public void run() { + try { + for (int i = 0; i < stopWhenReaches; i++) { + try { + sleep(elapseTime); +- callback.call(i); ++ callback.call(new Integer(i)); + } catch (Exception e) { + Log.log(e); + return; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/actions/PySelectionTest.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/actions/PySelectionTest.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/actions/PySelectionTest.java 2006-06-02 21:52:58.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/actions/PySelectionTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -210,7 +210,7 @@ + String s = "def m1(self, a, b)"; + doc = new Document(s); + ps = new PySelection(doc, new TextSelection(doc, 0,0)); +- List insideParentesisToks = ps.getInsideParentesisToks(false).o1; ++ List insideParentesisToks = (List) ps.getInsideParentesisToks(false).o1; + assertEquals(2, insideParentesisToks.size()); + assertEquals("a", insideParentesisToks.get(0)); + assertEquals("b", insideParentesisToks.get(1)); +@@ -218,7 +218,7 @@ + s = "def m1(self, a, b, )"; + doc = new Document(s); + ps = new PySelection(doc, new TextSelection(doc, 0,0)); +- insideParentesisToks = ps.getInsideParentesisToks(false).o1; ++ insideParentesisToks = (List) ps.getInsideParentesisToks(false).o1; + assertEquals(2, insideParentesisToks.size()); + assertEquals("a", insideParentesisToks.get(0)); + assertEquals("b", insideParentesisToks.get(1)); +@@ -227,7 +227,7 @@ + s = "def m1(self, a, b=None)"; + doc = new Document(s); + ps = new PySelection(doc, new TextSelection(doc, 0,0)); +- insideParentesisToks = ps.getInsideParentesisToks(true).o1; ++ insideParentesisToks = (List) ps.getInsideParentesisToks(true).o1; + assertEquals(3, insideParentesisToks.size()); + assertEquals("self", insideParentesisToks.get(0)); + assertEquals("a", insideParentesisToks.get(1)); +@@ -237,7 +237,7 @@ + s = "def m1(self, a, b=None)"; + doc = new Document(s); + ps = new PySelection(doc, new TextSelection(doc, 0,0)); +- insideParentesisToks = ps.getInsideParentesisToks(false).o1; ++ insideParentesisToks = (List) ps.getInsideParentesisToks(false).o1; + assertEquals(2, insideParentesisToks.size()); + assertEquals("a", insideParentesisToks.get(0)); + assertEquals("b", insideParentesisToks.get(1)); +@@ -245,7 +245,7 @@ + s = "def m1(self, a, (b,c) )"; + doc = new Document(s); + ps = new PySelection(doc, new TextSelection(doc, 0,0)); +- insideParentesisToks = ps.getInsideParentesisToks(false).o1; ++ insideParentesisToks = (List) ps.getInsideParentesisToks(false).o1; + assertEquals(3, insideParentesisToks.size()); + assertEquals("a", insideParentesisToks.get(0)); + assertEquals("b", insideParentesisToks.get(1)); +@@ -254,7 +254,7 @@ + s = "def m1(self, a, b, \nc,\nd )"; + doc = new Document(s); + ps = new PySelection(doc, new TextSelection(doc, 0,0)); +- insideParentesisToks = ps.getInsideParentesisToks(false).o1; ++ insideParentesisToks = (List) ps.getInsideParentesisToks(false).o1; + assertEquals(4, insideParentesisToks.size()); + assertEquals("a", insideParentesisToks.get(0)); + assertEquals("b", insideParentesisToks.get(1)); +@@ -325,28 +325,28 @@ + doc = new Document(s); + + ps = new PySelection(doc, 0); +- assertEquals(new Tuple("",0), ps.getCurrToken()); ++ assertEquals(new Tuple("",new Integer(0)), ps.getCurrToken()); + + ps = new PySelection(doc, 1); +- assertEquals(new Tuple("aa",1), ps.getCurrToken()); ++ assertEquals(new Tuple("aa",new Integer(1)), ps.getCurrToken()); + + ps = new PySelection(doc, 2); +- assertEquals(new Tuple("aa",1), ps.getCurrToken()); ++ assertEquals(new Tuple("aa",new Integer(1)), ps.getCurrToken()); + + ps = new PySelection(doc, doc.getLength()-1); +- assertEquals(new Tuple("bb",6), ps.getCurrToken()); ++ assertEquals(new Tuple("bb",new Integer(6)), ps.getCurrToken()); + + ps = new PySelection(doc, doc.getLength()); +- assertEquals(new Tuple( "bb",6), ps.getCurrToken()); ++ assertEquals(new Tuple( "bb",new Integer(6)), ps.getCurrToken()); + + s =" aa = bb "; + doc = new Document(s); + + ps = new PySelection(doc, doc.getLength()); +- assertEquals(new Tuple("",9), ps.getCurrToken()); ++ assertEquals(new Tuple("", new Integer(9)), ps.getCurrToken()); + + ps = new PySelection(doc, doc.getLength()-1); +- assertEquals(new Tuple("bb",6), ps.getCurrToken()); ++ assertEquals(new Tuple("bb",new Integer(6)), ps.getCurrToken()); + } + + public void testGetLine() throws Exception { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/PythonShellTest.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/PythonShellTest.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/PythonShellTest.java 2006-04-19 21:44:14.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/PythonShellTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -7,6 +7,7 @@ + + import java.io.IOException; + import java.util.ArrayList; ++import java.util.Iterator; + import java.util.List; + + import org.eclipse.core.runtime.CoreException; +@@ -65,7 +66,7 @@ + } + + public void testGetGlobalCompletions() throws IOException, CoreException { +- List list = shell.getImportCompletions("math", new ArrayList()).o2; ++ List list = (List) shell.getImportCompletions("math", new ArrayList()).o2; + + Object[] element = null; + element = (Object[]) list.get(0); +@@ -77,7 +78,7 @@ + + + public void testErrorOnCompletions() throws IOException, CoreException { +- List list = shell.getImportCompletions("dfjslkfjds\n\n", getPythonpath()).o2; ++ List list = (List) shell.getImportCompletions("dfjslkfjds\n\n", getPythonpath()).o2; + assertEquals(0, list.size()); + //don't show completion errors! + } +@@ -92,7 +93,7 @@ + + public void testGlu() throws IOException, CoreException { + if(TestDependent.HAS_GLU_INSTALLED){ +- List list = shell.getImportCompletions("OpenGL.GLUT", getPythonpath()).o2; ++ List list = (List) shell.getImportCompletions("OpenGL.GLUT", getPythonpath()).o2; + + assertTrue(list.size() > 10); + assertIsIn(list, "glutInitDisplayMode"); +@@ -100,13 +101,15 @@ + } + + private void assertIsIn(List list, String expected) { +- for (Object object : list) { ++ for (Iterator iter = list.iterator(); iter.hasNext();) { ++ Object object = (Object) iter.next(); ++ + Object o[] = (Object[]) object; + if(o[0].equals(expected)){ + return; + } + } +- fail(StringUtils.format("The string %s was not found in the returned completions", expected)); ++ fail(StringUtils.format("The string %s was not found in the returned completions", new Object [] {expected})); + } + + } +\ No newline at end of file +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/CodeCompletionTestsBase.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/CodeCompletionTestsBase.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/CodeCompletionTestsBase.java 2006-09-16 15:16:15.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/CodeCompletionTestsBase.java 2006-11-05 20:59:43.000000000 +0100 +@@ -6,6 +6,7 @@ + package org.python.pydev.editor.codecompletion.revisited; + + import java.io.File; ++import java.util.Iterator; + import java.util.List; + + import junit.framework.TestCase; +@@ -134,11 +135,10 @@ + + public static PythonNature createStaticNature() { + return new PythonNature(){ +- @Override + public boolean isJython() throws CoreException { + return false; + } +- @Override ++ + public boolean isPython() throws CoreException { + return true; + } +@@ -230,7 +230,7 @@ + * same as the restorePythonPath function but also includes the site packages in the distribution + */ + public void restorePythonPath(String path, boolean force){ +- restoreSystemPythonPath(force, path); ++ restoreSystemPythonPath(force, path); + restoreProjectPythonPath(force, TestDependent.TEST_PYSRC_LOC); + restoreProjectPythonPath2(force, TestDependent.TEST_PYSRC_LOC2); + checkSize(); +@@ -420,8 +420,10 @@ + return requestCompl(strDoc, new String[]{retCompl}); + } + +- public static void assertContains(List found, String toFind) { +- for (String str : found) { ++ public static void assertContains(List found, String toFind) { ++ for (Iterator iter = found.iterator(); iter.hasNext();) { ++ String str = (String) iter.next(); ++ + if (str.equals(toFind)){ + return; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/jython/JythonCodeCompletionTestsBase.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/jython/JythonCodeCompletionTestsBase.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/jython/JythonCodeCompletionTestsBase.java 2006-09-16 15:16:15.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/jython/JythonCodeCompletionTestsBase.java 2006-11-05 20:59:43.000000000 +0100 +@@ -5,6 +5,7 @@ + + import java.io.File; + import java.util.ArrayList; ++import java.util.Iterator; + + import org.eclipse.core.runtime.CoreException; + import org.python.copiedfromeclipsesrc.JavaVmLocationFinder; +@@ -22,7 +23,6 @@ + protected boolean calledJavaExecutable = false; + protected boolean calledJavaJars = false; + +- @Override + protected void setUp() throws Exception { + super.setUp(); + //we also need to set from where the info on the java env +@@ -37,21 +37,22 @@ + JavaVmLocationFinder.callbackJavaJars = new ICallback(){ + public Object call(Object args) { + calledJavaJars = true; +- ArrayList jars = new ArrayList(); ++ ArrayList jars = new ArrayList(); + jars.add(new File(TestDependent.JAVA_RT_JAR_LOCATION)); + return jars; + } + }; + } + +- @Override + protected void afterRestorSystemPythonPath(InterpreterInfo info) { + super.afterRestorSystemPythonPath(info); + assertTrue(calledJavaExecutable); + assertTrue(calledJavaJars); + + boolean foundRtJar = false; +- for(Object lib: info.libs){ ++ for (Iterator iter = info.libs.iterator(); iter.hasNext();) { ++ Object lib = (Object) iter.next(); ++ + String s = (String) lib; + if(s.endsWith("rt.jar")){ + foundRtJar = true; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/jython/JythonInterpreterManagerStub.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/jython/JythonInterpreterManagerStub.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/jython/JythonInterpreterManagerStub.java 2006-02-22 01:26:17.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/jython/JythonInterpreterManagerStub.java 2006-11-05 20:59:43.000000000 +0100 +@@ -6,6 +6,7 @@ + import org.eclipse.core.runtime.CoreException; + import org.eclipse.core.runtime.IProgressMonitor; + import org.eclipse.core.runtime.Preferences; ++import org.python.pydev.core.IInterpreterInfo; + import org.python.pydev.core.IPythonNature; + import org.python.pydev.core.TestDependent; + import org.python.pydev.core.Tuple; +@@ -42,9 +43,9 @@ + /** + * @see org.python.pydev.core.IInterpreterManager#getInterpreterInfo(java.lang.String, org.eclipse.core.runtime.IProgressMonitor) + */ +- public InterpreterInfo getInterpreterInfo(String executable, IProgressMonitor monitor) { ++ public IInterpreterInfo getInterpreterInfo(String executable, IProgressMonitor monitor) { + +- InterpreterInfo info = super.getInterpreterInfo(executable, monitor); ++ InterpreterInfo info = (InterpreterInfo) super.getInterpreterInfo(executable, monitor); + if(!info.executableOrJar.equals(TestDependent.JYTHON_JAR_LOCATION)){ + throw new RuntimeException("expected same"); + } +@@ -58,22 +59,18 @@ + return TestDependent.JAVA_LOCATION; + } + +- @Override + protected String getPreferenceName() { + return "pref name"; + } + +- @Override + protected String getNotConfiguredInterpreterMsg() { + return "getNotConfiguredInterpreterMsg"; + } + +- @Override +- public Tuple createInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { ++ public Tuple createInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { + return JythonInterpreterManager.doCreateInterpreterInfo(executable, monitor); + } + +- @Override + public boolean canGetInfoOnNature(IPythonNature nature) { + return true; + } +@@ -87,7 +84,6 @@ + return false; + } + +- @Override + public String getManagerRelatedName() { + return "jython"; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/PythonInterpreterManagerStub.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/PythonInterpreterManagerStub.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/PythonInterpreterManagerStub.java 2006-02-22 01:26:16.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/PythonInterpreterManagerStub.java 2006-11-05 20:59:43.000000000 +0100 +@@ -9,6 +9,7 @@ + import org.eclipse.core.runtime.CoreException; + import org.eclipse.core.runtime.IProgressMonitor; + import org.eclipse.core.runtime.Preferences; ++import org.python.pydev.core.IInterpreterInfo; + import org.python.pydev.core.IInterpreterManager; + import org.python.pydev.core.IPythonNature; + import org.python.pydev.core.TestDependent; +@@ -46,9 +47,9 @@ + /** + * @see org.python.pydev.core.IInterpreterManager#getInterpreterInfo(java.lang.String, org.eclipse.core.runtime.IProgressMonitor) + */ +- public InterpreterInfo getInterpreterInfo(String executable, IProgressMonitor monitor) { ++ public IInterpreterInfo getInterpreterInfo(String executable, IProgressMonitor monitor) { + +- InterpreterInfo info = super.getInterpreterInfo(executable, monitor); ++ InterpreterInfo info = (InterpreterInfo) super.getInterpreterInfo(executable, monitor); + if(!InterpreterInfo.isJythonExecutable(executable)){ + TestDependent.PYTHON_EXE = info.executableOrJar; + } +@@ -62,22 +63,18 @@ + throw new RuntimeException("not impl"); + } + +- @Override + protected String getPreferenceName() { + return "pref name"; + } + +- @Override + protected String getNotConfiguredInterpreterMsg() { + return "getNotConfiguredInterpreterMsg"; + } + +- @Override +- public Tuple createInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { ++ public Tuple createInterpreterInfo(String executable, IProgressMonitor monitor) throws CoreException { + return PythonInterpreterManager.doCreateInterpreterInfo(executable, monitor); + } + +- @Override + public boolean canGetInfoOnNature(IPythonNature nature) { + return true; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/visitors/AbstractVisitorTest.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/visitors/AbstractVisitorTest.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/visitors/AbstractVisitorTest.java 2006-09-16 15:16:15.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/codecompletion/revisited/visitors/AbstractVisitorTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -40,10 +40,10 @@ + } + + public void testImportCreation1() throws Exception { +- Iterator iterator = createModuleAndGetImports("import os.path", Import.class); ++ Iterator iterator = createModuleAndGetImports("import os.path", Import.class); + +- SimpleNode simpleNode = iterator.next().node; +- List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), MODULE_NAME, true); ++ SimpleNode simpleNode = ((ASTEntry)iterator.next()).node; ++ List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), MODULE_NAME, true); + assertEquals(2, toks.size()); + + SourceToken token = (SourceToken) toks.get(0); +@@ -54,10 +54,10 @@ + } + + public void testImportCreation2() throws Exception { +- Iterator iterator = createModuleAndGetImports("from os import path, notDefined", ImportFrom.class); ++ Iterator iterator = createModuleAndGetImports("from os import path, notDefined", ImportFrom.class); + +- SimpleNode simpleNode = iterator.next().node; +- List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), MODULE_NAME, true); ++ SimpleNode simpleNode = ((ASTEntry)iterator.next()).node; ++ List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), MODULE_NAME, true); + assertEquals(2, toks.size()); + + SourceToken token = (SourceToken) toks.get(0); +@@ -68,10 +68,10 @@ + } + + public void testImportCreation3() throws Exception { +- Iterator iterator = createModuleAndGetImports("from os import path as tt, notDefined as aa", ImportFrom.class); ++ Iterator iterator = createModuleAndGetImports("from os import path as tt, notDefined as aa", ImportFrom.class); + +- SimpleNode simpleNode = iterator.next().node; +- List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), MODULE_NAME, true); ++ SimpleNode simpleNode = ((ASTEntry)iterator.next()).node; ++ List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), MODULE_NAME, true); + assertEquals(2, toks.size()); + + SourceToken token = (SourceToken) toks.get(0); +@@ -83,10 +83,10 @@ + + + public void testImportCreation4() throws Exception { +- Iterator iterator = createModuleAndGetImports("from os.path import *", ImportFrom.class); ++ Iterator iterator = createModuleAndGetImports("from os.path import *", ImportFrom.class); + +- SimpleNode simpleNode = iterator.next().node; +- List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), MODULE_NAME, true); ++ SimpleNode simpleNode = ((ASTEntry)iterator.next()).node; ++ List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), MODULE_NAME, true); + assertEquals(1, toks.size()); + + SourceToken token = (SourceToken) toks.get(0); +@@ -94,10 +94,10 @@ + } + + public void testImportCreation5() throws Exception { +- Iterator iterator = createModuleAndGetImports("from os.path import *", ImportFrom.class); ++ Iterator iterator = createModuleAndGetImports("from os.path import *", ImportFrom.class); + MODULE_NAME = "some.dotted.name"; +- SimpleNode simpleNode = iterator.next().node; +- List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), "some.dotted.name", true); ++ SimpleNode simpleNode = ((ASTEntry)iterator.next()).node; ++ List toks = AbstractVisitor.makeImportToken(simpleNode, new ArrayList(), "some.dotted.name", true); + assertEquals(1, toks.size()); + + SourceToken token = (SourceToken) toks.get(0); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/correctionassist/heuristics/AssistAssignTest.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/correctionassist/heuristics/AssistAssignTest.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/editor/correctionassist/heuristics/AssistAssignTest.java 2006-09-19 01:43:25.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/editor/correctionassist/heuristics/AssistAssignTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -5,6 +5,7 @@ + */ + package org.python.pydev.editor.correctionassist.heuristics; + ++import java.util.Iterator; + import java.util.List; + + import org.eclipse.jface.text.BadLocationException; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/runners/SimpleJythonRunnerTest.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/runners/SimpleJythonRunnerTest.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/runners/SimpleJythonRunnerTest.java 2006-03-15 01:18:35.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/runners/SimpleJythonRunnerTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -34,7 +34,7 @@ + public void testRun() throws CoreException, IOException { + SimpleJythonRunner runner = new SimpleJythonRunner(); + File absoluteFile = PydevPlugin.getBundleInfo().getRelativePath(new Path("interpreterInfo.py")).getAbsoluteFile(); +- String string = runner.runAndGetOutputWithJar(absoluteFile.getCanonicalPath(), TestDependent.JYTHON_JAR_LOCATION, null, null, null, new NullProgressMonitor()).o1; ++ String string = (String) runner.runAndGetOutputWithJar(absoluteFile.getCanonicalPath(), TestDependent.JYTHON_JAR_LOCATION, null, null, null, new NullProgressMonitor()).o1; + // String string = runner.runAndGetOutput(absoluteFile.getCanonicalPath(), (String)null, null); + assertNotNull(string); + // System.out.println(string); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/runners/SimplePythonRunnerTest.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/runners/SimplePythonRunnerTest.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/runners/SimplePythonRunnerTest.java 2006-03-15 01:18:35.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/runners/SimplePythonRunnerTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -49,7 +49,7 @@ + public void testEnv() throws CoreException, IOException { + + File relativePath = PydevPlugin.getBundleInfo().getRelativePath(new Path("PySrc/interpreterInfo.py")); +- String string = new SimplePythonRunner().runAndGetOutput(TestDependent.PYTHON_EXE+" "+relativePath.getCanonicalPath(), null).o1; ++ String string = (String) new SimplePythonRunner().runAndGetOutput(TestDependent.PYTHON_EXE+" "+relativePath.getCanonicalPath(), null).o1; + assertNotNull(string); + //System.out.println(string); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/ui/pythonpathconf/InterpreterInfoTest.java eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/ui/pythonpathconf/InterpreterInfoTest.java +--- eclipse-pydev-1.2.5/org.python.pydev/tests/org/python/pydev/ui/pythonpathconf/InterpreterInfoTest.java 2006-09-16 17:52:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev/tests/org/python/pydev/ui/pythonpathconf/InterpreterInfoTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -102,11 +102,11 @@ + String toString7 = info7.toString(); + assertEquals(info7, InterpreterInfo.fromString(toString7)); + +- List l1 = new ArrayList(); ++ List l1 = new ArrayList(); + l1.add("c:\\bin\\python24\\lib\\lib-tk"); + l1.add("c:\\bin\\python24"); +- List l2 = new ArrayList(); +- List l3 = new ArrayList(); ++ List l2 = new ArrayList(); ++ List l3 = new ArrayList(); + l3.add("__builtin__"); + l3.add("__main__"); + l3.add("_bisect"); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.ast/build.properties eclipse-pydev-1.2.5-patched/org.python.pydev.ast/build.properties +--- eclipse-pydev-1.2.5/org.python.pydev.ast/build.properties 2005-09-03 17:59:14.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.ast/build.properties 2006-11-05 20:59:43.000000000 +0100 +@@ -1,7 +1,6 @@ + bin.includes = plugin.xml,\ + ast.jar,\ +- META-INF/,\ +- retroweaver-rt.jar ++ META-INF/ + jars.compile.order = ast.jar + source.ast.jar = src/ + output.ast.jar = bin/ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/build.properties eclipse-pydev-1.2.5-patched/org.python.pydev.core/build.properties +--- eclipse-pydev-1.2.5/org.python.pydev.core/build.properties 2005-11-17 15:53:44.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/build.properties 2006-11-05 20:59:43.000000000 +0100 +@@ -3,7 +3,6 @@ + bin.includes = plugin.xml,\ + META-INF/,\ + core.jar,\ +- retroweaver-rt.jar,\ + commons-codec.jar + jars.extra.classpath = commons-codec.jar + jars.compile.order = core.jar +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/META-INF/MANIFEST.MF eclipse-pydev-1.2.5-patched/org.python.pydev.core/META-INF/MANIFEST.MF +--- eclipse-pydev-1.2.5/org.python.pydev.core/META-INF/MANIFEST.MF 2006-06-07 15:25:34.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/META-INF/MANIFEST.MF 2006-11-05 20:59:43.000000000 +0100 +@@ -4,7 +4,6 @@ + Bundle-SymbolicName: org.python.pydev.core; singleton:=true + Bundle-Version: 0.9.7.1 + Bundle-ClassPath: core.jar, +- retroweaver-rt.jar, + commons-codec.jar + Bundle-Activator: org.python.pydev.core.CorePlugin + Bundle-Vendor: Fabio Zadrozny +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/bundle/ImageCache.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/bundle/ImageCache.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/bundle/ImageCache.java 2006-04-17 18:25:28.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/bundle/ImageCache.java 2006-11-05 20:59:43.000000000 +0100 +@@ -20,7 +20,7 @@ + public class ImageCache { + + +- private Map imageHash = new HashMap(10); ++ private Map imageHash = new HashMap(10); + private URL baseURL; + private Image missing = null; + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/cache/Cache.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/cache/Cache.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/cache/Cache.java 2006-02-14 16:29:41.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/cache/Cache.java 2006-11-05 20:59:43.000000000 +0100 +@@ -5,20 +5,20 @@ + /** + * Defines the interface for a cache + */ +-public interface Cache { ++public interface Cache { + + /** + * This method returns the value for the given key. + */ +- public Val getObj(Key o); ++ public Object getObj(Object o); + + /** + * This method removes some key from the cache + */ +- public void remove(Key key); ++ public void remove(Object key); + + /** + * Adds some value to the cache + */ +- public void add(Key key, Val n); ++ public void add(Object key, Object n); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/cache/DiskCache.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/cache/DiskCache.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/cache/DiskCache.java 2006-04-22 16:05:09.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/cache/DiskCache.java 2006-11-05 20:59:43.000000000 +0100 +@@ -6,6 +6,7 @@ + import java.io.ObjectOutputStream; + import java.io.Serializable; + import java.util.HashSet; ++import java.util.Iterator; + import java.util.Set; + + import org.python.pydev.core.REF; +@@ -20,7 +21,7 @@ + * + * -- And yes, the cache itself is serializable! + */ +-public class DiskCache extends LRUCache implements Serializable{ ++public class DiskCache extends LRUCache implements Serializable{ + + private static final long serialVersionUID = 1L; + +@@ -34,7 +35,7 @@ + /** + * The keys will be in memory all the time... only the values will come and go to the disk. + */ +- private Set keys = new HashSet(); ++ private Set keys = new HashSet(); + + /** + * The files persisted should have this suffix (should start with .) +@@ -44,11 +45,10 @@ + /** + * Custom deserialization is needed. + */ +- @SuppressWarnings("unchecked") + private void readObject(ObjectInputStream aStream) throws IOException, ClassNotFoundException { + + aStream.defaultReadObject(); +- keys = (Set) aStream.readObject(); ++ keys = (Set) aStream.readObject(); + folderToPersist = (String) aStream.readObject(); + suffix = (String) aStream.readObject(); + maxSize = aStream.readInt(); +@@ -83,7 +83,7 @@ + + public synchronized Serializable getObj(String key) { + synchronized(cache){ +- Serializable v = super.getObj(key); ++ Serializable v = (Serializable) super.getObj(key); + if(v == null && keys.contains(key)){ + //miss in memory... get from disk + File file = getFileForKey(key); +@@ -144,7 +144,9 @@ + */ + public synchronized void clear() { + synchronized(cache){ +- for(String key : keys){ ++ for (Iterator iter = keys.iterator(); iter.hasNext();) { ++ String key = (String) iter.next(); ++ + super.remove(key); + File fileForKey = getFileForKey(key); + fileForKey.delete(); +@@ -156,9 +158,9 @@ + /** + * @return a copy of the keys available + */ +- public synchronized Set keys() { ++ public synchronized Set keys() { + synchronized(cache){ +- return new HashSet(keys); ++ return new HashSet(keys); + } + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/cache/LRUCache.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/cache/LRUCache.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/cache/LRUCache.java 2006-07-02 19:32:08.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/cache/LRUCache.java 2006-11-05 20:59:43.000000000 +0100 +@@ -14,8 +14,8 @@ + * + * (it is actually serializable or not depending on its keys and values) + */ +-public class LRUCache implements Cache, Serializable{ +- ++public class LRUCache implements Cache, Serializable{ ++ + protected int maxSize; + + private static final long serialVersionUID = 1L; +@@ -27,8 +27,8 @@ + cache = createMap(maxSize); + } + +- protected LinkedHashMap createMap(int maxSize) { +- return new LinkedHashMap(maxSize+1, .75F, true) { ++ protected LinkedHashMap createMap(int maxSize) { ++ return new LinkedHashMap(maxSize+1, .75F, true) { + // This method is called just after a new entry has been added + public boolean removeEldestEntry(Map.Entry eldest) { + return size() > LRUCache.this.maxSize; +@@ -41,7 +41,7 @@ + removeEntries--; + if(removeEntries == 0){ + maxSize = initialMaxSize; +- Iterator> iter = cache.entrySet().iterator(); ++ Iterator iter = cache.entrySet().iterator(); + //go to the position of the 'eldest' entries + for (int i = 0; i < cache.size() - maxSize; i++) { + iter.next(); +@@ -78,17 +78,17 @@ + } + + //Create cache +- protected LinkedHashMap cache; ++ protected LinkedHashMap cache; + +- public Val getObj(Key key) { ++ public Object getObj(Object key) { + return cache.get(key); + } + +- public void remove(Key key) { ++ public void remove(Object key) { + cache.remove(key); + } + +- public void add(Key key, Val val) { ++ public void add(Object key, Object val) { + cache.put(key, val); + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/cache/PyPreferencesCache.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/cache/PyPreferencesCache.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/cache/PyPreferencesCache.java 2006-05-19 15:47:23.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/cache/PyPreferencesCache.java 2006-11-05 20:59:43.000000000 +0100 +@@ -9,7 +9,7 @@ + public class PyPreferencesCache implements IPropertyChangeListener { + + private IPreferenceStore preferenceStore; +- private HashMap cache = new HashMap(); ++ private HashMap cache = new HashMap(); + + public PyPreferencesCache(IPreferenceStore preferenceStore) { + this.preferenceStore = preferenceStore; +@@ -19,19 +19,19 @@ + public boolean getBoolean(String key) { + Boolean b = (Boolean) cache.get(key); + if(b == null){ +- b = this.preferenceStore.getBoolean(key); ++ b = new Boolean(this.preferenceStore.getBoolean(key)); + cache.put(key, b); + } +- return b; ++ return b.booleanValue(); + } + + public int getInt(String key) { + Integer b = (Integer) cache.get(key); + if(b == null){ +- b = this.preferenceStore.getInt(key); ++ b = new Integer(this.preferenceStore.getInt(key)); + cache.put(key, b); + } +- return b; ++ return b.intValue(); + } + + public void propertyChange(PropertyChangeEvent event) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/DeltaSaver.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/DeltaSaver.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/DeltaSaver.java 2006-06-11 20:29:06.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/DeltaSaver.java 2006-11-05 20:59:43.000000000 +0100 +@@ -15,6 +15,7 @@ + import java.util.ArrayList; + import java.util.Collections; + import java.util.Comparator; ++import java.util.Iterator; + import java.util.List; + + import org.python.pydev.core.log.Log; +@@ -33,7 +34,7 @@ + * + * @author Fabio + */ +-public class DeltaSaver { ++public class DeltaSaver { + + /** + * Superclass of all commands +@@ -50,7 +51,7 @@ + + public abstract void processWith(IDeltaProcessor deltaProcessor); + +- public void readData(ICallback readFromFileMethod, ObjectInputStream in) { ++ public void readData(ICallback readFromFileMethod, ObjectInputStream in) { + this.data = readFromFileMethod.call(in); + } + +@@ -69,7 +70,6 @@ + super(o); + } + +- @SuppressWarnings("unchecked") + public void processWith(IDeltaProcessor deltaProcessor){ + deltaProcessor.processDelete(data); + } +@@ -90,7 +90,6 @@ + super(o); + } + +- @SuppressWarnings("unchecked") + public void processWith(IDeltaProcessor deltaProcessor){ + deltaProcessor.processInsert(data); + } +@@ -110,7 +109,6 @@ + super(o); + } + +- @SuppressWarnings("unchecked") + public void processWith(IDeltaProcessor deltaProcessor){ + deltaProcessor.processUpdate(data); + } +@@ -129,7 +127,7 @@ + /** + * List of commands + */ +- private List commands; ++ private List commands; + + /** + * Used to keep track of a number to use to save the command +@@ -140,16 +138,16 @@ + * This is the method that should read the data in the delta from a file... This is because of the &*(^%EO way eclipse handles this kind of stuff, + * so, we can't just serialize it from another plugin. + */ +- private ICallback readFromFileMethod; ++ private ICallback readFromFileMethod; + + /** + * @param dirToSaveDeltas this is the directory where the deltas should be saved + * @param extension this is the extension that should be given to the deltas + */ +- public DeltaSaver(File dirToSaveDeltas, String extension, ICallback readFromFileMethod) { ++ public DeltaSaver(File dirToSaveDeltas, String extension, ICallback readFromFileMethod) { + this.dirToSaveDeltas = dirToSaveDeltas; + this.suffix = "."+extension; +- this.commands = Collections.synchronizedList(new ArrayList()); ++ this.commands = Collections.synchronizedList(new ArrayList()); + this.readFromFileMethod = readFromFileMethod; + validateDir(); + loadDeltas(); +@@ -173,8 +171,10 @@ + */ + private void loadDeltas() { + synchronized(this.commands){ +- ArrayList deltasFound = findDeltas(); +- for (File file : deltasFound) { ++ ArrayList deltasFound = findDeltas(); ++ for (Iterator iter = deltasFound.iterator(); iter.hasNext();) { ++ File file = (File) iter.next(); ++ + try { + DeltaCommand cmd = (DeltaCommand) IOUtils.readFromFile(file, this.readFromFileMethod); + if(cmd != null && cmd.data != null){ +@@ -191,20 +191,24 @@ + /** + * @return a list of files with all the deltas in the dir we are acting upon + */ +- private ArrayList findDeltas() { +- ArrayList deltasFound = new ArrayList(); ++ private ArrayList findDeltas() { ++ ArrayList deltasFound = new ArrayList(); + File[] files = this.dirToSaveDeltas.listFiles(); +- for (File file : files) { ++ for (int i = 0; i < files.length; i++) { ++ File file = files[i]; ++ + if(file.exists() && file.isFile() && file.getName().endsWith(suffix)){ + deltasFound.add(file); + } + } + //also, sort by the name (which must be an integer) +- Collections.sort(deltasFound, new Comparator(){ ++ Collections.sort(deltasFound, new Comparator(){ + +- public int compare(File o1, File o2) { +- String i = FullRepIterable.headAndTail(o1.getName())[0]; +- String j = FullRepIterable.headAndTail(o2.getName())[0]; ++ public int compare(Object o1, Object o2) { ++ File o1f = (File)o1; ++ File o2f = (File)o2; ++ String i = FullRepIterable.headAndTail(o1f.getName())[0]; ++ String j = FullRepIterable.headAndTail(o2f.getName())[0]; + return new Integer(i).compareTo(new Integer(j)); + }} + ); +@@ -253,8 +257,10 @@ + * Clears all deltas in the disk (and in memory... also restarts numbering the deltas) + */ + public void clearAll() { +- ArrayList deltas = findDeltas(); +- for (File file : deltas) { ++ ArrayList deltas = findDeltas(); ++ for (Iterator iter = deltas.iterator(); iter.hasNext();) { ++ File file = (File) iter.next(); ++ + if(file.exists()){ + file.delete(); + } +@@ -263,25 +269,27 @@ + nCommands = 0; + } + +- public void addInsertCommand(X o) { ++ public void addInsertCommand(Object o) { + addCommand(new DeltaInsertCommand(o)); + } + +- public void addDeleteCommand(X o) { ++ public void addDeleteCommand(Object o) { + addCommand(new DeltaDeleteCommand(o)); + } + +- public void addUpdateCommand(X o) { ++ public void addUpdateCommand(Object o) { + addCommand(new DeltaUpdateCommand(o)); + } + + /** + * Passes the current deltas to the delta processor. + */ +- public void processDeltas(IDeltaProcessor deltaProcessor) { ++ public void processDeltas(IDeltaProcessor deltaProcessor) { + synchronized(this.commands){ + boolean processed = false; +- for (DeltaCommand cmd : this.commands) { ++ for (Iterator iter = this.commands.iterator(); iter.hasNext();) { ++ DeltaCommand cmd = (DeltaCommand) iter.next(); ++ + try { + cmd.processWith(deltaProcessor); + processed = false; +@@ -326,7 +334,7 @@ + * @param readFromFileMethod + * @return + */ +- public static Object readFromFile(File astOutputFile, ICallback readFromFileMethod) { ++ public static Object readFromFile(File astOutputFile, ICallback readFromFileMethod) { + try { + boolean deletFile = false; + //the file is not even there +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/docutils/PyDocIterator.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/docutils/PyDocIterator.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/docutils/PyDocIterator.java 2006-06-07 02:30:58.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/docutils/PyDocIterator.java 2006-11-05 20:59:43.000000000 +0100 +@@ -5,7 +5,7 @@ + import org.eclipse.jface.text.BadLocationException; + import org.eclipse.jface.text.IDocument; + +-public class PyDocIterator implements Iterator { ++public class PyDocIterator implements Iterator { + + private int offset; + private IDocument doc; +@@ -89,7 +89,7 @@ + /** + * @return the next line in the document + */ +- public String next() { ++ public Object next() { + + try { + StringBuffer buf = new StringBuffer(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/docutils/PyPartitionScanner.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/docutils/PyPartitionScanner.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/docutils/PyPartitionScanner.java 2006-05-30 02:21:11.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/docutils/PyPartitionScanner.java 2006-11-05 20:59:43.000000000 +0100 +@@ -39,21 +39,21 @@ + public class PyPartitionScanner extends RuleBasedPartitionScanner implements IPythonPartitions { + public PyPartitionScanner() { + super(); +- List rules = new ArrayList(); ++ List rules = new ArrayList(); + + addMultilineStringRule(rules); + addSinglelineStringRule(rules); + addReprRule(rules); + addCommentRule(rules); + +- setPredicateRules(rules.toArray(new IPredicateRule[0])); ++ setPredicateRules((IPredicateRule[]) rules.toArray(new IPredicateRule[0])); + } + +- private void addReprRule(List rules) { ++ private void addReprRule(List rules) { + rules.add(new SingleLineRule("`", "`", new Token(IPythonPartitions.PY_BACKQUOTES))); + } + +- private void addSinglelineStringRule(List rules) { ++ private void addSinglelineStringRule(List rules) { + // IToken singleLineString = new Token(PY_SINGLELINE_STRING); + // rules.add(new SingleLineRule("\"", "\"", singleLineString, '\\')); + // rules.add(new SingleLineRule("'", "'", singleLineString, '\\')); -- changed to the construct below because we need to continue on escape +@@ -69,7 +69,7 @@ + rules.add(new PatternRule("\"", "\"", singleLineString2, '\\', breaksOnEOL, breaksOnEOF, escapeContinuesLine)); + } + +- private void addMultilineStringRule(List rules) { ++ private void addMultilineStringRule(List rules) { + IToken multiLineString1 = new Token(IPythonPartitions.PY_MULTILINE_STRING1); + IToken multiLineString2 = new Token(IPythonPartitions.PY_MULTILINE_STRING2); + // deal with ''' and """ strings +@@ -93,7 +93,7 @@ + //I also tried creating a new token for it, but it had problems too (not the same ones, but had other problems). + } + +- private void addCommentRule(List rules) { ++ private void addCommentRule(List rules) { + IToken comment = new Token(IPythonPartitions.PY_COMMENT); + rules.add(new EndOfLineRule("#", comment)); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/docutils/PySelection.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/docutils/PySelection.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/docutils/PySelection.java 2006-09-14 03:15:31.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/docutils/PySelection.java 2006-11-05 20:59:43.000000000 +0100 +@@ -82,7 +82,7 @@ + * @return the pyselection created + */ + public static PySelection createFromNonUiThread(final ITextEditor textEditor) { +- final Tuple t = new Tuple(null, null); ++ final Tuple t = new Tuple(null, null); + Runnable r = new Runnable(){ + public void run() { + try { +@@ -93,7 +93,7 @@ + } + }; + RunInUiThread.sync(r); +- return t.o1; ++ return (PySelection) t.o1; + } + + /** +@@ -765,13 +765,13 @@ + * @return the current token and its initial offset + * @throws BadLocationException + */ +- public Tuple getCurrToken() throws BadLocationException { +- Tuple tup = extractActivationToken(doc, getAbsoluteCursorOffset(), false); +- String prefix = tup.o1; ++ public Tuple getCurrToken() throws BadLocationException { ++ Tuple tup = extractActivationToken(doc, getAbsoluteCursorOffset(), false); ++ String prefix = (String) tup.o1; + + // ok, now, get the rest of the token, as we already have its prefix + +- int start = tup.o2-prefix.length(); ++ int start = ((Integer) tup.o2).intValue() - prefix.length(); + int end = start; + while (doc.getLength() - 1 >= end) { + char ch = doc.getChar(end); +@@ -781,8 +781,8 @@ + break; + } + } +- String post = doc.get(tup.o2, end-tup.o2); +- return new Tuple(prefix+post, start); ++ String post = doc.get(((Integer)tup.o2).intValue(), end - ((Integer)tup.o2).intValue()); ++ return new Tuple(prefix+post, new Integer(start)); + } + + /** +@@ -793,8 +793,8 @@ + * @return a Tuple so that the first param is the list and + * the second the offset of the end of the parentesis it may return null if no starting parentesis was found at the current line + */ +- public Tuple, Integer> getInsideParentesisToks(boolean addSelf) { +- List l = new ArrayList(); ++ public Tuple getInsideParentesisToks(boolean addSelf) { ++ List l = new ArrayList(); + + String line = getLine(); + int openParIndex = line.indexOf('('); +@@ -820,7 +820,7 @@ + l.add(trimmed); + } + } +- return new Tuple, Integer>(l, j); ++ return new Tuple(l, new Integer(j)); + } + + +@@ -860,7 +860,7 @@ + * - a String with the line where some dedent token was found while looking for that scope. + * - a string with the lowest indent (null if none was found) + */ +- public Tuple3 getPreviousLineThatStartsScope() { ++ public Tuple3 getPreviousLineThatStartsScope() { + DocIterator iterator = new DocIterator(false); + String foundDedent = null; + int lowest = Integer.MAX_VALUE; +@@ -870,10 +870,11 @@ + String line = (String) iterator.next(); + String trimmed = line.trim(); + +- for (String dedent : PySelection.INDENT_TOKENS) { ++ for (int i = 0; i < PySelection.INDENT_TOKENS.length; i++) { ++ String dedent = PySelection.INDENT_TOKENS[i]; + if(trimmed.startsWith(dedent)){ + if(isCompleteToken(trimmed, dedent)){ +- return new Tuple3(line, foundDedent, lowestStr); ++ return new Tuple3(line, foundDedent, lowestStr); + } + } + } +@@ -929,8 +930,8 @@ + } + + +- public static List getLineBreakOffsets(String replacementString) { +- ArrayList ret = new ArrayList(); ++ public static List getLineBreakOffsets(String replacementString) { ++ ArrayList ret = new ArrayList(); + + int lineBreaks = 0; + int ignoreNextNAt = -1; +@@ -939,12 +940,12 @@ + for (int i = 0; i < replacementString.length(); i++) { + if(replacementString.charAt(i) == '\r'){ + lineBreaks++; +- ret.add(i); ++ ret.add(new Integer(i)); + ignoreNextNAt = i + 1; + } + if(replacementString.charAt(i) == '\n'){ + if(ignoreNextNAt != i){ +- ret.add(i); ++ ret.add(new Integer(i)); + lineBreaks++; + } + } +@@ -1065,19 +1066,19 @@ + } + } + +- Tuple tupPrefix = extractActivationToken(doc, documentOffset, getFullQualifier); ++ Tuple tupPrefix = extractActivationToken(doc, documentOffset, getFullQualifier); + + if(getFullQualifier == true){ + //may have changed +- documentOffset = tupPrefix.o2; ++ documentOffset = ((Integer) tupPrefix.o2).intValue(); + } + +- String activationToken = tupPrefix.o1; ++ String activationToken = (String) tupPrefix.o1; + documentOffset = documentOffset-activationToken.length()-1; + + try { + while(documentOffset >= 0 && documentOffset < doc.getLength() && doc.get(documentOffset, 1).equals(".")){ +- String tok = extractActivationToken(doc, documentOffset, false).o1; ++ String tok = (String) extractActivationToken(doc, documentOffset, false).o1; + + + String c = doc.get(documentOffset-1, 1); +@@ -1096,7 +1097,7 @@ + + }else if(c.equals(")")){ + documentOffset = eatFuncCall(doc, documentOffset-1); +- tok = extractActivationToken(doc, documentOffset, false).o1; ++ tok = (String) extractActivationToken(doc, documentOffset, false).o1; + activationToken = tok+"()."+activationToken; + documentOffset = documentOffset-tok.length()-1; + +@@ -1171,7 +1172,7 @@ + * @return a tuple with the activation token and the cursor offset (may change if we need to get the full qualifier, + * otherwise, it is the same offset passed as a parameter). + */ +- public static Tuple extractActivationToken(IDocument document, int offset, boolean getFullQualifier) { ++ public static Tuple extractActivationToken(IDocument document, int offset, boolean getFullQualifier) { + try { + if(getFullQualifier){ + //if we have to get the full qualifier, we'll have to walk the offset (cursor) forward +@@ -1188,7 +1189,7 @@ + int i= offset; + + if (i > document.getLength()) +- return new Tuple("", document.getLength()); //$NON-NLS-1$ ++ return new Tuple("", new Integer(document.getLength())); //$NON-NLS-1$ + + while (i > 0) { + char ch= document.getChar(i - 1); +@@ -1197,9 +1198,9 @@ + i--; + } + +- return new Tuple(document.get(i, offset - i), offset); ++ return new Tuple(document.get(i, offset - i), new Integer(offset)); + } catch (BadLocationException e) { +- return new Tuple("", offset); //$NON-NLS-1$ ++ return new Tuple("", new Integer(offset)); //$NON-NLS-1$ + } + } + +@@ -1326,7 +1327,8 @@ + * @return true if this line starts with a dedent token (the passed string should be already trimmed) + */ + public static boolean startsWithDedentToken(String trimmedLine) { +- for (String dedent : PySelection.DEDENT_TOKENS) { ++ for (int i = 0; i < PySelection.DEDENT_TOKENS.length; i++) { ++ String dedent = PySelection.DEDENT_TOKENS[i]; + if(trimmedLine.startsWith(dedent)){ + return isCompleteToken(trimmedLine, dedent); + } +@@ -1426,12 +1428,12 @@ + * @param offset the offset we want info on + * @return a tuple with the line, col of the passed offset in the document + */ +- public Tuple getLineAndCol(int offset) { ++ public Tuple getLineAndCol(int offset) { + try { + IRegion region = doc.getLineInformationOfOffset(offset); + int line = doc.getLineOfOffset(offset); + int col = offset - region.getOffset(); +- return new Tuple(line, col); ++ return new Tuple(new Integer(line), new Integer(col)); + } catch (BadLocationException e) { + throw new RuntimeException(e); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/docutils/StringUtils.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/docutils/StringUtils.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/docutils/StringUtils.java 2006-09-19 01:43:14.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/docutils/StringUtils.java 2006-11-05 20:59:43.000000000 +0100 +@@ -9,7 +9,7 @@ + + public class StringUtils { + +- public static String format(String str, Object ... args){ ++ public static String format(String str, Object[] args){ + StringBuffer buffer = new StringBuffer(); + int j = 0; + +@@ -88,8 +88,8 @@ + return string; + } + +- public static List splitInLines(String string) { +- ArrayList ret = new ArrayList(); ++ public static List splitInLines(String string) { ++ ArrayList ret = new ArrayList(); + int len = string.length(); + + char c; +@@ -122,7 +122,8 @@ + } + + public static boolean isSingleWord(String string) { +- for(char c: string.toCharArray()){ ++ for (int i = 0; i < string.toCharArray().length; i++) { ++ char c = string.toCharArray()[i]; + if(!Character.isJavaIdentifierStart(c)){ + return false; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ExtensionHelper.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ExtensionHelper.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ExtensionHelper.java 2006-09-25 01:14:58.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ExtensionHelper.java 2006-11-05 20:59:43.000000000 +0100 +@@ -22,9 +22,9 @@ + * This should be used to add participants at test-time. It should be the name + * of the extension point to a list (which will be returned) + */ +- public static Map testingParticipants; ++ public static Map testingParticipants; + +- private static Map extensionsCache = new HashMap(); ++ private static Map extensionsCache = new HashMap(); + + //pydev + public final static String PYDEV_COMPLETION = "org.python.pydev.pydev_completion"; +@@ -46,7 +46,7 @@ + + + private static IExtension[] getExtensions(String type) { +- IExtension[] extensions = extensionsCache.get(type); ++ IExtension[] extensions = (IExtension[]) extensionsCache.get(type); + if(extensions == null){ + IExtensionRegistry registry = Platform.getExtensionRegistry(); + if(registry != null){ // we may not be in eclipse env when testing +@@ -88,10 +88,9 @@ + * @param type the extension we want to get + * @return a list of classes created from those extensions + */ +- @SuppressWarnings("unchecked") + public static List getParticipants(String type) { + if(testingParticipants != null){ +- return testingParticipants.get(type); ++ return (List) testingParticipants.get(type); + } + + ArrayList list = new ArrayList(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/FullRepIterable.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/FullRepIterable.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/FullRepIterable.java 2006-09-17 23:29:25.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/FullRepIterable.java 2006-11-05 20:59:43.000000000 +0100 +@@ -19,9 +19,9 @@ + * + * @author Fabio + */ +-public class FullRepIterable implements Iterable{ ++public class FullRepIterable{ + +- private static final class ReverseFullRepIterator implements Iterator { ++ private static final class ReverseFullRepIterator implements Iterator { + + private String fullRep; + +@@ -33,7 +33,7 @@ + return fullRep.length() > 0; + } + +- public String next() { ++ public Object next() { + if(fullRep.length() == 0){ + throw new RuntimeException("no more items"); + } +@@ -53,7 +53,7 @@ + + } + +- private static final class FullRepIterator implements Iterator { ++ private static final class FullRepIterator implements Iterator { + private int i = -1; + private boolean lastStep; //even if there is no point, we should return the last string + private String fullRep; +@@ -68,7 +68,7 @@ + return ret; + } + +- public String next() { ++ public Object next() { + int j = fullRep.indexOf('.', i); + if(j == -1){ + lastStep = true; +@@ -107,7 +107,7 @@ + this.reverse = reverse; + } + +- public Iterator iterator() { ++ public Iterator iterator() { + if(!reverse){ + return new FullRepIterator(this.fullRep); + }else{ +@@ -214,7 +214,9 @@ + */ + public static boolean containsPart(String foundRep, String nameToFind) { + String[] strings = dotSplit(foundRep); +- for (String string : strings) { ++ for (int i = 0; i < strings.length; i++) { ++ String string = strings[i]; ++ + if(string.equals(nameToFind)){ + return true; + } +@@ -226,7 +228,7 @@ + * Splits some string given some char + */ + public static String[] split(String string, char toSplit) { +- ArrayList ret = new ArrayList(); ++ ArrayList ret = new ArrayList(); + int len = string.length(); + + int last = 0; +@@ -255,7 +257,7 @@ + + } + } +- return ret.toArray(new String[ret.size()]); ++ return (String[]) ret.toArray(new String[ret.size()]); + } + + /** +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ICallback.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ICallback.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ICallback.java 2005-10-14 03:36:17.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ICallback.java 2006-11-05 20:59:43.000000000 +0100 +@@ -3,7 +3,7 @@ + */ + package org.python.pydev.core; + +-public interface ICallback { ++public interface ICallback { + +- Ret call(Arg arg); ++ Object call(Object arg); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ICodeCompletionASTManager.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ICodeCompletionASTManager.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ICodeCompletionASTManager.java 2006-09-23 23:22:32.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ICodeCompletionASTManager.java 2006-11-05 20:59:43.000000000 +0100 +@@ -121,7 +121,7 @@ + * 1: tok (string) + * 2: actual tok + */ +- public abstract Tuple3 findOnImportedMods( IPythonNature nature, String activationToken, IModule current); ++ public abstract Tuple3 findOnImportedMods( IPythonNature nature, String activationToken, IModule current); + + /** + * This function tries to find some activation token defined in some imported module. +@@ -139,7 +139,7 @@ + * 1: tok (string) + * 2: actual tok + */ +- public abstract Tuple3 findOnImportedMods( IToken[] importedModules, IPythonNature nature, String activationToken, String currentModuleName); ++ public abstract Tuple3 findOnImportedMods( IToken[] importedModules, IPythonNature nature, String activationToken, String currentModuleName); + + /** + * Finds the tokens on the given imported modules +@@ -197,7 +197,7 @@ + * @param completions OUT this is where the completions are added. + * @return the same list that has been passed at completions + */ +- public List getBuiltinCompletions(ICompletionState state, List completions); ++ public List getBuiltinCompletions(ICompletionState state, List completions); + + /** + * This method can get the global completions for a module (the activation token is usually empty in +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IDeltaProcessor.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IDeltaProcessor.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IDeltaProcessor.java 2005-10-14 03:36:17.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IDeltaProcessor.java 2006-11-05 20:59:43.000000000 +0100 +@@ -3,22 +3,22 @@ + */ + package org.python.pydev.core; + +-public interface IDeltaProcessor { ++public interface IDeltaProcessor { + + /** + * Process some update that was added with the passed data. + */ +- void processUpdate(X data); ++ void processUpdate(Object data); + + /** + * Process some delete that was added with the passed data. + */ +- void processDelete(X data); ++ void processDelete(Object data); + + /** + * Process some insert that was added with the passed data. + */ +- void processInsert(X data); ++ void processInsert(Object data); + + /** + * Ends the processing (so that the processor might save all the delta info in a large chunck, +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IInterpreterManager.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IInterpreterManager.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IInterpreterManager.java 2006-09-19 03:11:45.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IInterpreterManager.java 2006-11-05 20:59:43.000000000 +0100 +@@ -90,7 +90,7 @@ + * All the information cached should be cleared but the information related to the passed interpreters + * @param allButTheseInterpreters name of the interpreters that should not have the information cleared + */ +- public void clearAllBut(List allButTheseInterpreters); ++ public void clearAllBut(List allButTheseInterpreters); + + /** + * @return whether this manager treats jython +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ILocalScope.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ILocalScope.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ILocalScope.java 2006-09-23 23:22:32.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ILocalScope.java 2006-11-05 20:59:43.000000000 +0100 +@@ -29,7 +29,7 @@ + /** + * @return the modules that are imported in the current (local) scope as tokens + */ +- public List getLocalImportedModules(int line, int col, String moduleName); ++ public List getLocalImportedModules(int line, int col, String moduleName); + + /** + * @return whether the last element found in this scope is a class definition +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IModule.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IModule.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IModule.java 2006-09-23 23:22:32.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IModule.java 2006-11-05 20:59:43.000000000 +0100 +@@ -65,7 +65,7 @@ + * @return array of definitions. + * @throws Exception + */ +- public abstract IDefinition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List findInfo) throws Exception; ++ public abstract IDefinition[] findDefinition(ICompletionState state, int line, int col, IPythonNature nature, List findInfo) throws Exception; + + /** + * This function should return all tokens that are global for a given token. +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IModulesManager.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IModulesManager.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IModulesManager.java 2006-07-17 01:39:59.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IModulesManager.java 2006-11-05 20:59:43.000000000 +0100 +@@ -29,7 +29,7 @@ + /** + * @return a set with the names of all available modules + */ +- public abstract Set getAllModuleNames(); ++ public abstract Set getAllModuleNames(); + + public abstract ModulesKey[] getOnlyDirectModules(); + +@@ -93,9 +93,9 @@ + /** + * @return the paths that constitute the pythonpath as a list of strings + */ +- public abstract List getCompletePythonPath(); ++ public abstract List getCompletePythonPath(); + +- public abstract SortedMap getAllModulesStartingWith(String moduleToGetTokensFrom); +- public abstract SortedMap getAllDirectModulesStartingWith(String moduleToGetTokensFrom); ++ public abstract SortedMap getAllModulesStartingWith(String moduleToGetTokensFrom); ++ public abstract SortedMap getAllDirectModulesStartingWith(String moduleToGetTokensFrom); + + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IPythonPathNature.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IPythonPathNature.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/IPythonPathNature.java 2006-10-09 03:06:16.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/IPythonPathNature.java 2006-11-05 21:54:01.000000000 +0100 +@@ -66,7 +66,7 @@ + * @return only the project source paths as a list of strings (paths are relative to the project location) + * @throws CoreException + */ +- public Set getProjectSourcePathSet() throws CoreException; ++ public Set getProjectSourcePathSet() throws CoreException; + + + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ISystemModulesManager.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ISystemModulesManager.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ISystemModulesManager.java 2006-01-16 18:17:33.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ISystemModulesManager.java 2006-11-05 20:59:43.000000000 +0100 +@@ -7,7 +7,7 @@ + + public interface ISystemModulesManager { + +- public abstract void regenerateForcedBuilltins(Collection forcedLibs); ++ public abstract void regenerateForcedBuilltins(Collection forcedLibs); + + /** + * @see org.python.pydev.editor.codecompletion.revisited.ModulesManager#getBuiltins() +@@ -17,6 +17,6 @@ + /** + * @param forcedLibs + */ +- public abstract void setBuiltins(Collection forcedLibs); ++ public abstract void setBuiltins(Collection forcedLibs); + + } +\ No newline at end of file +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/log/Log.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/log/Log.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/log/Log.java 2006-09-26 02:47:02.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/log/Log.java 2006-11-05 20:59:43.000000000 +0100 +@@ -50,12 +50,12 @@ + + public synchronized static void toLogFile(Object obj, String string) { + synchronized(lock){ +- Class class1 = obj.getClass(); ++ Class class1 = obj.getClass(); + toLogFile(string, class1); + } + } + +- public static void toLogFile(String string, Class class1) { ++ public static void toLogFile(String string, Class class1) { + StringBuffer buffer = new StringBuffer(); + buffer.append(logIndent); + buffer.append(FullRepIterable.getLastPart(class1.getName())); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ModulesKey.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ModulesKey.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ModulesKey.java 2006-01-22 21:19:08.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ModulesKey.java 2006-11-05 20:59:43.000000000 +0100 +@@ -63,7 +63,6 @@ + return this.name.hashCode(); + } + +- @Override + public String toString() { + if(file != null){ + return name+" - "+file; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ObjectsPool.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ObjectsPool.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/ObjectsPool.java 2006-04-12 21:45:52.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/ObjectsPool.java 2006-11-05 20:59:43.000000000 +0100 +@@ -28,7 +28,6 @@ + * E.g.: If an integer with the value 1 is requested, it will se if that value already exists and return it. + * If it doesn't exist, the parameter itself will be put in the pool. + */ +- @SuppressWarnings("unchecked") + public synchronized Object getFromPool(Object o){ + synchronized(pool){ + Class class_ = o.getClass(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/REF.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/REF.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/REF.java 2006-09-23 18:54:59.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/REF.java 2006-11-05 20:59:43.000000000 +0100 +@@ -183,7 +183,7 @@ + * @throws IOException + * @throws ClassNotFoundException + */ +- public static Object getStrAsObj(String persisted, ICallback readFromFileMethod) throws IOException, ClassNotFoundException { ++ public static Object getStrAsObj(String persisted, ICallback readFromFileMethod) throws IOException, ClassNotFoundException { + InputStream input = new ByteArrayInputStream(decodeBase64(persisted)); + Object o = readFromInputStreamAndCloseIt(readFromFileMethod, input); + return o; +@@ -195,7 +195,7 @@ + * @return + * @throws IOException + */ +- public static Object readFromInputStreamAndCloseIt(ICallback readFromFileMethod, InputStream input) { ++ public static Object readFromInputStreamAndCloseIt(ICallback readFromFileMethod, InputStream input) { + ObjectInputStream in = null; + Object o = null; + try { +@@ -345,7 +345,7 @@ + * @param args the arguments received for the call + * @return the return of the method + */ +- public static Object invoke(Object obj, String name, Object... args) { ++ public static Object invoke(Object obj, String name, Object [] args) { + //the args are not checked for the class because if a subclass is passed, the method is not correctly gotten + //another method might do it... + Method m = findMethod(obj, name, args); +@@ -353,7 +353,7 @@ + } + + +- public static Object invoke(Object obj, Method m, Object... args) { ++ public static Object invoke(Object obj, Method m, Object [] args) { + try { + return m.invoke(obj, args); + } catch (Exception e) { +@@ -361,24 +361,26 @@ + } + } + +- public static Method findMethod(Object obj, String name, Object... args) { ++ public static Method findMethod(Object obj, String name, Object [] args) { + return findMethod(obj.getClass(), name, args); + } + +- public static Method findMethod(Class class_, String name, Object... args) { ++ public static Method findMethod(Class class_, String name, Object [] args) { + try { + Method[] methods = class_.getMethods(); +- for (Method method : methods) { ++ for (int i = 0; i < methods.length; i++) { ++ Method method = methods[i]; + + Class[] parameterTypes = method.getParameterTypes(); + if(method.getName().equals(name) && parameterTypes.length == args.length){ + //check the parameters +- int i = 0; +- for (Class param : parameterTypes) { +- if(!param.isInstance(args[i])){ ++ ++ ++ for (int j = 0; j < parameterTypes.length; j++) { ++ Class param = parameterTypes[j]; ++ if(!param.isInstance(args[j])){ + continue; + } +- i++; + } + //invoke it + return method; +@@ -398,7 +400,8 @@ + public static String getValidProjectName(IProject project) { + String name = project.getName(); + +- for (char c : INVALID_FILESYSTEM_CHARS) { ++ for (int i = 0; i < INVALID_FILESYSTEM_CHARS.length; i++) { ++ char c = INVALID_FILESYSTEM_CHARS[i]; + name = name.replace(c, '_'); + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/structure/FastStack.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/structure/FastStack.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/structure/FastStack.java 2006-06-07 16:06:08.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/structure/FastStack.java 2006-11-05 20:59:43.000000000 +0100 +@@ -6,7 +6,7 @@ + import java.util.ListIterator; + import java.util.NoSuchElementException; + +-public class FastStack extends LinkedList { ++public class FastStack extends LinkedList { + /** + * Creates an empty Stack. + */ +@@ -24,9 +24,8 @@ + * @param item the item to be pushed onto this stack. + * @return the item argument. + */ +- public E push(E item) { ++ public void push(Object item) { + addLast(item); +- return item; + } + + /** +@@ -35,7 +34,7 @@ + * @return The object at the top of this stack (the last item of the LinkedList object). + * @exception EmptyStackException if this stack is empty. + */ +- public synchronized E pop() { ++ public synchronized Object pop() { + return removeLast(); + } + +@@ -45,7 +44,7 @@ + * @return the object at the top of this stack. + * @exception EmptyStackException if this stack is empty. + */ +- public synchronized E peek() { ++ public synchronized Object peek() { + try { + return getLast(); + } catch (NoSuchElementException e) { +@@ -84,19 +83,19 @@ + this.clear(); + } + +- public E elementAt(int i) { ++ public Object elementAt(int i) { + return this.get(i); + } + +- public Iterator topDownIterator(){ +- final ListIterator l = this.listIterator(this.size()); +- return new Iterator(){ ++ public Iterator topDownIterator(){ ++ final ListIterator l = this.listIterator(this.size()); ++ return new Iterator(){ + + public boolean hasNext() { + return l.hasPrevious(); + } + +- public E next() { ++ public Object next() { + return l.previous(); + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/Tuple3.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/Tuple3.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/Tuple3.java 2006-03-19 19:48:29.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/Tuple3.java 2006-11-05 20:59:43.000000000 +0100 +@@ -10,19 +10,18 @@ + * + * @author Fabio + */ +-public class Tuple3 implements Serializable{ ++public class Tuple3 implements Serializable{ + +- public X o1; +- public Y o2; +- public Z o3; ++ public Object o1; ++ public Object o2; ++ public Object o3; + +- public Tuple3(X o1, Y o2, Z o3) { ++ public Tuple3(Object o1, Object o2, Object o3) { + this.o1 = o1; + this.o2 = o2; + this.o3 = o3; + } + +- @Override + public boolean equals(Object obj) { + if(!(obj instanceof Tuple3)){ + return false; +@@ -41,12 +40,10 @@ + return true; + } + +- @Override + public int hashCode() { + return o1.hashCode() * o2.hashCode() * o3.hashCode(); + } + +- @Override + public String toString() { + StringBuffer buffer = new StringBuffer(); + buffer.append("Tuple ["); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/Tuple.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/Tuple.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/src/org/python/pydev/core/Tuple.java 2006-05-31 21:45:23.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/src/org/python/pydev/core/Tuple.java 2006-11-05 20:59:43.000000000 +0100 +@@ -10,17 +10,16 @@ + * + * @author Fabio + */ +-public class Tuple implements Serializable{ ++public class Tuple implements Serializable{ + +- public X o1; +- public Y o2; ++ public Object o1; ++ public Object o2; + +- public Tuple(X o1, Y o2) { ++ public Tuple(Object o1, Object o2) { + this.o1 = o1; + this.o2 = o2; + } + +- @Override + public boolean equals(Object obj) { + if(!(obj instanceof Tuple)){ + return false; +@@ -54,7 +53,6 @@ + return true; + } + +- @Override + public int hashCode() { + if(o1 != null && o2 != null){ + return o1.hashCode() * o2.hashCode(); +@@ -68,7 +66,6 @@ + return 7; + } + +- @Override + public String toString() { + StringBuffer buffer = new StringBuffer(); + buffer.append("Tuple ["); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/tests/org/python/pydev/core/cache/LRUCacheTest.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/tests/org/python/pydev/core/cache/LRUCacheTest.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/tests/org/python/pydev/core/cache/LRUCacheTest.java 2006-04-12 19:22:17.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/tests/org/python/pydev/core/cache/LRUCacheTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -20,21 +20,21 @@ + + } + public void testRegular() throws Exception { +- LRUCache cache = new LRUCache(2); +- cache.add(1,1); +- cache.add(2,2); +- cache.add(3,3); +- assertNull(cache.getObj(1)); ++ LRUCache cache = new LRUCache(2); ++ cache.add(new Integer(1),new Integer(1)); ++ cache.add(new Integer(2),new Integer(2)); ++ cache.add(new Integer(3),new Integer(3)); ++ assertNull(cache.getObj(new Integer(1))); + +- cache.add(4,4); +- assertNull(cache.getObj(2)); ++ cache.add(new Integer(4),new Integer(4)); ++ assertNull(cache.getObj(new Integer(2))); + + //there is only 3 and 4 now + cache.startGrowAsNeeded(Integer.MAX_VALUE); +- cache.add(5,5); +- cache.add(6,6); +- assertNotNull(cache.getObj(3)); +- assertNotNull(cache.getObj(4)); ++ cache.add(new Integer(5),new Integer(5)); ++ cache.add(new Integer(6),new Integer(6)); ++ assertNotNull(cache.getObj(new Integer(3))); ++ assertNotNull(cache.getObj(new Integer(4))); + + cache.stopGrowAsNeeded(); + assertEquals(2, cache.cache.size()); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/tests/org/python/pydev/core/DeltaSaverTest.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/tests/org/python/pydev/core/DeltaSaverTest.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/tests/org/python/pydev/core/DeltaSaverTest.java 2005-10-14 03:36:17.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/tests/org/python/pydev/core/DeltaSaverTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -24,15 +24,16 @@ + + protected void tearDown() throws Exception { + super.tearDown(); +- new DeltaSaver(new File("."), "deltatest", getCallBack()).clearAll(); //leave no traces ++ new DeltaSaver(new File("."), "deltatest", getCallBack()).clearAll(); //leave no traces + } + +- private ICallback getCallBack() { +- return new ICallback(){ ++ private ICallback getCallBack() { ++ return new ICallback(){ + +- public Object call(ObjectInputStream arg) { ++ public Object call(Object arg) { + try { +- return arg.readObject(); ++ ObjectInputStream arg1 = (ObjectInputStream) arg; ++ return arg1.readObject(); + } catch (IOException e) { + throw new RuntimeException(e); + } catch (ClassNotFoundException e) { +@@ -41,24 +42,24 @@ + }}; + } + +- public static class DeltaProcessor implements IDeltaProcessor{ ++ public static class DeltaProcessor implements IDeltaProcessor{ + +- public List state = new ArrayList(); ++ public List state = new ArrayList(); + + public int processed; + +- public void processUpdate(String data) { ++ public void processUpdate(Object data) { + throw new RuntimeException("should not be called"); + } + +- public void processDelete(String data) { ++ public void processDelete(Object data) { + processed+=1; + state.remove(data); + } + +- public void processInsert(String data) { ++ public void processInsert(Object data) { + processed+=1; +- state.add((String) data); ++ state.add(data); + } + + public void endProcessing() { +@@ -67,12 +68,12 @@ + } + + public void testSaveRestore() throws Exception { +- DeltaSaver saver = new DeltaSaver(new File("."), "deltatest", getCallBack()); ++ DeltaSaver saver = new DeltaSaver(new File("."), "deltatest", getCallBack()); + saver.addInsertCommand("ins1"); + saver.addInsertCommand("ins2"); + saver.addDeleteCommand("ins1"); + +- DeltaSaver restorer = new DeltaSaver(new File("."), "deltatest", getCallBack()); ++ DeltaSaver restorer = new DeltaSaver(new File("."), "deltatest", getCallBack()); + assertEquals(3, restorer.availableDeltas()); + DeltaProcessor deltaProcessor = new DeltaProcessor(); + restorer.processDeltas(deltaProcessor); +@@ -80,7 +81,7 @@ + assertEquals(1, deltaProcessor.state.size()); + assertEquals("ins2", deltaProcessor.state.get(0)); + +- restorer = new DeltaSaver(new File("."), "deltatest", getCallBack()); ++ restorer = new DeltaSaver(new File("."), "deltatest", getCallBack()); + assertEquals(0, restorer.availableDeltas()); + + } +@@ -88,22 +89,22 @@ + + + +- public static class InsertDeltaProcessor implements IDeltaProcessor{ ++ public static class InsertDeltaProcessor implements IDeltaProcessor{ + +- public List state = new ArrayList(); ++ public List state = new ArrayList(); + + public int processed; + +- public void processUpdate(Integer data) { ++ public void processUpdate(Object data) { + throw new RuntimeException("should not be called"); + } + +- public void processDelete(Integer data) { ++ public void processDelete(Object data) { + throw new RuntimeException("should not be called"); + } + +- public void processInsert(Integer data) { +- assertEquals((Object)processed, (Object)data); ++ public void processInsert(Object data) { ++ assertEquals(new Integer(processed), data); + processed+=1; + } + +@@ -114,11 +115,11 @@ + + public void testSaveRestore3() throws Exception { + //check if the order is correct +- DeltaSaver saver = new DeltaSaver(new File("."), "deltatest", getCallBack()); ++ DeltaSaver saver = new DeltaSaver(new File("."), "deltatest", getCallBack()); + for (int i = 0; i < 50; i++) { +- saver.addInsertCommand(i); ++ saver.addInsertCommand(new Integer(i)); + } +- DeltaSaver restorer = new DeltaSaver(new File("."), "deltatest", getCallBack()); ++ DeltaSaver restorer = new DeltaSaver(new File("."), "deltatest", getCallBack()); + assertEquals(50, restorer.availableDeltas()); + restorer.processDeltas(new InsertDeltaProcessor()); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.core/tests/org/python/pydev/core/FullRepIterableTest.java eclipse-pydev-1.2.5-patched/org.python.pydev.core/tests/org/python/pydev/core/FullRepIterableTest.java +--- eclipse-pydev-1.2.5/org.python.pydev.core/tests/org/python/pydev/core/FullRepIterableTest.java 2006-06-07 18:55:16.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.core/tests/org/python/pydev/core/FullRepIterableTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -57,7 +57,9 @@ + assertFalse(iterator.hasNext()); + + int i = 0; +- for(String dummy : new FullRepIterable("testlib.unittest.relative")){ ++ for (Iterator iter = new FullRepIterable("testlib.unittest.relative").iterator(); iter.hasNext();) { ++ String dummy = (String) iter.next(); ++ + i++; + } + assertEquals(3, i); +@@ -72,7 +74,9 @@ + assertFalse(iterator.hasNext()); + + int i = 0; +- for(String dummy : new FullRepIterable("testlib.unittest.relative")){ ++ for (Iterator iter = new FullRepIterable("testlib.unittest.relative").iterator(); iter.hasNext();) { ++ String dummy = (String) iter.next(); ++ + i++; + } + assertEquals(3, i); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/build.properties eclipse-pydev-1.2.5-patched/org.python.pydev.debug/build.properties +--- eclipse-pydev-1.2.5/org.python.pydev.debug/build.properties 2005-09-03 17:59:30.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/build.properties 2006-11-05 20:59:43.000000000 +0100 +@@ -3,8 +3,7 @@ + CVS/,\ + META-INF/,\ + icons/,\ +- pydev-debug.jar,\ +- retroweaver-rt.jar ++ pydev-debug.jar + jars.compile.order = pydev-debug.jar + source.pydev-debug.jar = src/ + output.pydev-debug.jar = bin/ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/codecoverage/PyCodeCoverageView.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/codecoverage/PyCodeCoverageView.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/codecoverage/PyCodeCoverageView.java 2006-06-23 01:46:17.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/codecoverage/PyCodeCoverageView.java 2006-11-05 20:59:43.000000000 +0100 +@@ -215,7 +215,7 @@ + + FileNode cache = (FileNode) PyCoverage.getPyCoverage().cache.getFile(realFile); + for (Iterator it = cache.notExecutedIterator(); it.hasNext();) { +- Map map = new HashMap(); ++ Map map = new HashMap(); + int errorLine = ((Integer) it.next()).intValue() - 1; + + IRegion region = document.getLineInformation(errorLine); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/AbstractDebugTarget.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/AbstractDebugTarget.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/AbstractDebugTarget.java 2006-09-26 12:41:00.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/AbstractDebugTarget.java 2006-11-05 20:59:43.000000000 +0100 +@@ -1,5 +1,6 @@ + package org.python.pydev.debug.model; + ++import java.util.Iterator; + import java.util.List; + import java.util.regex.Matcher; + import java.util.regex.Pattern; +@@ -232,7 +233,9 @@ + * @return an existing thread with a given id (null if none) + */ + protected PyThread findThreadByID(String thread_id) { +- for (IThread thread : threads){ ++ for (int i = 0; i < threads.length; i++) { ++ IThread thread= threads[i]; ++ + if (thread_id.equals(((PyThread)thread).getId())){ + return (PyThread)thread; + } +@@ -274,7 +277,8 @@ + PyThread[] newnewThreads = new PyThread[newSize]; + int i = 0; + +- for (PyThread newThread: newThreads){ ++ for (int j = 0; j < newThreads.length; j++) { ++ PyThread newThread = newThreads[j]; + if (!((PyThread)newThread).isPydevThread()){ + newnewThreads[i] = newThread; + i += 1; +@@ -424,7 +428,9 @@ + + // now, register all the breakpoints in all projects + IProject projects[] = ResourcesPlugin.getWorkspace().getRoot().getProjects(); +- for (IProject project : projects) { ++ for (int i = 0; i < projects.length; i++) { ++ IProject project = projects[i]; ++ + if(!project.isOpen()){ + continue; + } +@@ -434,7 +440,9 @@ + IMarker[] condMarkers = project.findMarkers(PyBreakpoint.PY_CONDITIONAL_BREAK_MARKER, true, IResource.DEPTH_INFINITE); + IBreakpointManager breakpointManager = DebugPlugin.getDefault().getBreakpointManager(); + +- for (IMarker marker : markers) { ++ for (int j = 0; j < markers.length; j++) { ++ IMarker marker = markers[j]; ++ + PyBreakpoint brk = (PyBreakpoint) breakpointManager.getBreakpoint(marker); + + if (brk.isEnabled()) { +@@ -443,7 +451,9 @@ + } + } + +- for (IMarker marker: condMarkers) { ++ for (int j = 0; j < condMarkers.length; j++) { ++ IMarker marker = condMarkers[j]; ++ + PyBreakpoint brk = (PyBreakpoint) breakpointManager.getBreakpoint(marker); + if (brk.isEnabled()) { + SetBreakpointCommand cmd = new SetBreakpointCommand(debugger, brk.getFile(), brk.getLine(), brk.getCondition()); +@@ -464,12 +474,11 @@ + * This function adds the input listener extension point, so that plugins that only care about + * the input in the console can know about it. + */ +- @SuppressWarnings("unchecked") + public void addConsoleInputListener(){ + IConsole console = DebugUITools.getConsole(this.getProcess()); + if (console instanceof ProcessConsole) { + final ProcessConsole c = (ProcessConsole) console; +- final List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_DEBUG_CONSOLE_INPUT_LISTENER); ++ final List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_DEBUG_CONSOLE_INPUT_LISTENER); + final AbstractDebugTarget target = this; + //let's listen the doc for the changes + c.getDocument().addDocumentListener(new IDocumentListener(){ +@@ -487,7 +496,9 @@ + if(event.fText.length() <= 2){ + //the user typed something + final String inputFound = p.getString(); +- for (IConsoleInputListener listener : participants) { ++ for (Iterator iter = participants.iterator(); iter.hasNext();) { ++ IConsoleInputListener listener = (IConsoleInputListener) iter.next(); ++ + listener.newLineReceived(inputFound, target); + } + } +@@ -513,7 +524,9 @@ + if(p.getType().equals(IOConsolePartition.INPUT_PARTITION_TYPE)){ + if(event.fText.length() > 2){ + //the user pasted something +- for (IConsoleInputListener listener : participants) { ++ for (Iterator iter = participants.iterator(); iter.hasNext();) { ++ IConsoleInputListener listener = (IConsoleInputListener) iter.next(); ++ + listener.pasteReceived(event.fText, target); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/DeferredWorkbenchAdapter.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/DeferredWorkbenchAdapter.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/DeferredWorkbenchAdapter.java 2006-04-13 22:02:54.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/DeferredWorkbenchAdapter.java 2006-11-05 20:59:43.000000000 +0100 +@@ -21,7 +21,6 @@ + this.parent = parent; + } + +- @Override + public boolean isContainer() { + if(parent instanceof PyVariableCollection){ + return true; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/PyStackFrame.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/PyStackFrame.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/PyStackFrame.java 2006-06-24 03:45:53.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/PyStackFrame.java 2006-11-05 20:59:43.000000000 +0100 +@@ -142,9 +142,12 @@ + * + * @return the map + */ +- public Map getVariablesAsMap() throws DebugException { +- HashMap map = new HashMap(); +- for (IVariable var : variables) { ++ public Map getVariablesAsMap() throws DebugException { ++ HashMap map = new HashMap(); ++ ++ for (int i = 0; i < variables.length; i++) { ++ IVariable var = variables[i]; ++ + map.put(var.getName(), var); + } + return map; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/remote/GetFrameCommand.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/remote/GetFrameCommand.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/remote/GetFrameCommand.java 2006-01-20 14:24:42.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/remote/GetFrameCommand.java 2006-11-05 20:59:43.000000000 +0100 +@@ -6,7 +6,6 @@ + super(debugger, locator); + } + +- @Override + protected int getCommandId() { + return CMD_GET_FRAME; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/ValueModificationChecker.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/ValueModificationChecker.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/ValueModificationChecker.java 2006-06-24 03:45:53.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/ValueModificationChecker.java 2006-11-05 20:59:43.000000000 +0100 +@@ -6,6 +6,7 @@ + + import java.util.HashMap; + import java.util.HashSet; ++import java.util.Iterator; + import java.util.Map; + + import org.eclipse.debug.core.DebugException; +@@ -31,7 +32,7 @@ + PyVariable newVariable = null; + + try { +- Map variablesAsMap = oldFrame.getVariablesAsMap(); ++ Map variablesAsMap = oldFrame.getVariablesAsMap(); + + //we have to check for each new variable + for( int i=0; i> cache = new HashMap>(); ++ private Map cache = new HashMap(); + private Object lock = new Object(); + + /** +@@ -65,13 +66,13 @@ + */ + public synchronized void verifyModified(PyStackFrame frame, IVariable[] newFrameVariables) { + synchronized(lock){ +- Map threadIdCache = cache.get(frame.getThreadId()); ++ Map threadIdCache = (Map) cache.get(frame.getThreadId()); + if(threadIdCache == null){ +- threadIdCache = new HashMap(); ++ threadIdCache = new HashMap(); + cache.put(frame.getThreadId(), threadIdCache); + } + +- PyStackFrame cacheFrame = threadIdCache.get(frame.getId()); ++ PyStackFrame cacheFrame = (PyStackFrame) threadIdCache.get(frame.getId()); + if(cacheFrame == null){ + threadIdCache.put(frame.getId(), frame); + return; +@@ -92,11 +93,13 @@ + */ + public synchronized void onlyLeaveThreads(PyThread[] threads) { + synchronized(lock){ +- HashSet ids = new HashSet(); +- for (PyThread thread : threads) { ++ HashSet ids = new HashSet(); ++ for (int i = 0; i < threads.length; i++) { ++ PyThread thread = threads[i]; + ids.add(thread.getId()); + } +- for(String id: cache.keySet()){ ++ for (Iterator i = cache.keySet().iterator(); i.hasNext();) { ++ String id = (String) i.next(); + if(!ids.contains(id)){ + cache.remove(id); + } +@@ -110,17 +113,18 @@ + */ + public synchronized void onlyLeaveStack(PyThread t, IStackFrame[] stackFrame) { + synchronized(lock){ +- Map threadIdCache = this.cache.get(t); ++ Map threadIdCache = (Map) this.cache.get(t); + if(threadIdCache == null){ + return; + } +- HashSet ids = new HashSet(); ++ HashSet ids = new HashSet(); + + for (int i = 0; i < stackFrame.length; i++) { + ids.add(((PyStackFrame)stackFrame[i]).getId()); + } + +- for(String id: threadIdCache.keySet()){ ++ for (Iterator i = threadIdCache.keySet().iterator(); i.hasNext(); ) { ++ String id = (String) i.next(); + if(!ids.contains(id)){ + threadIdCache.remove(id); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/XMLUtils.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/XMLUtils.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/model/XMLUtils.java 2006-06-24 03:45:53.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/model/XMLUtils.java 2006-11-05 20:59:43.000000000 +0100 +@@ -57,7 +57,7 @@ + static class XMLToThreadInfo extends DefaultHandler { + + public AbstractDebugTarget target; +- public List threads = new ArrayList(); ++ public List threads = new ArrayList(); + + public XMLToThreadInfo(AbstractDebugTarget target) { + this.target = target; +@@ -131,8 +131,8 @@ + static class XMLToStackInfo extends DefaultHandler { + public PyThread thread; + public String stop_reason; +- public List stack = new ArrayList(); +- public List locals; ++ public List stack = new ArrayList(); ++ public List locals; + public AbstractDebugTarget target; + PyStackFrame currentFrame; + +@@ -224,7 +224,7 @@ + XMLToStackInfo info = new XMLToStackInfo(target); + parser.parse(new ByteArrayInputStream(payload.getBytes()), info); + +- stack = info.stack.toArray(new IStackFrame[0]); ++ stack = (IStackFrame[]) info.stack.toArray(new IStackFrame[0]); + + retVal[0] = info.thread; + retVal[1] = info.stop_reason; +@@ -247,12 +247,12 @@ + static class XMLToVariableInfo extends DefaultHandler { + private AbstractDebugTarget target; + private IVariableLocator locator; +- public List vars; ++ public List vars; + + public XMLToVariableInfo(AbstractDebugTarget target, IVariableLocator locator) { + this.target = target; + this.locator = locator; +- vars = new ArrayList(); ++ vars = new ArrayList(); + } + + public void startElement(String uri, String localName, String qName, +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/BreakpointRulerAction.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/BreakpointRulerAction.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/BreakpointRulerAction.java 2006-06-10 01:12:25.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/BreakpointRulerAction.java 2006-11-05 20:59:43.000000000 +0100 +@@ -124,11 +124,11 @@ + IMarker[] markers= null; + if (resource instanceof IFile) { + markers= resource.findMarkers(PyBreakpoint.PY_BREAK_MARKER, true, IResource.DEPTH_INFINITE); +- List markerList = Arrays.asList(markers); +- ArrayList fillMarkers = new ArrayList(markerList); ++ List markerList = Arrays.asList(markers); ++ ArrayList fillMarkers = new ArrayList(markerList); + fillMarkers.addAll(Arrays.asList(resource.findMarkers(PyBreakpoint.PY_CONDITIONAL_BREAK_MARKER, true, IResource.DEPTH_INFINITE))); + markers = new IMarker[fillMarkers.size()]; +- markers = fillMarkers.toArray(markers); ++ markers = (IMarker[]) fillMarkers.toArray(markers); + } else { + IWorkspaceRoot root= ResourcesPlugin.getWorkspace().getRoot(); + markers= root.findMarkers(PyBreakpoint.PY_BREAK_MARKER, true, IResource.DEPTH_INFINITE); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/EnableDisableBreakpointRulerActionDelegate.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/EnableDisableBreakpointRulerActionDelegate.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/EnableDisableBreakpointRulerActionDelegate.java 2005-12-17 13:58:44.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/EnableDisableBreakpointRulerActionDelegate.java 2006-11-05 20:59:43.000000000 +0100 +@@ -8,7 +8,6 @@ + public class EnableDisableBreakpointRulerActionDelegate extends + AbstractRulerActionDelegate { + +- @Override + protected IAction createAction(ITextEditor editor, IVerticalRulerInfo rulerInfo) { + return new EnableDisableBreakpointRulerAction(editor, rulerInfo); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/EnableDisableBreakpointRulerAction.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/EnableDisableBreakpointRulerAction.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/EnableDisableBreakpointRulerAction.java 2005-12-17 13:58:44.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/EnableDisableBreakpointRulerAction.java 2006-11-05 20:59:43.000000000 +0100 +@@ -40,7 +40,6 @@ + } + } + +- @Override + public void run() { + + if (getBreakpoint() != null) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/PythonBreakpointPropertiesRulerActionDelegate.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/PythonBreakpointPropertiesRulerActionDelegate.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/PythonBreakpointPropertiesRulerActionDelegate.java 2005-12-17 13:58:44.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/actions/PythonBreakpointPropertiesRulerActionDelegate.java 2006-11-05 20:59:43.000000000 +0100 +@@ -18,7 +18,6 @@ + /* (non-Javadoc) + * @see org.eclipse.ui.texteditor.AbstractRulerActionDelegate#createAction(org.eclipse.ui.texteditor.ITextEditor, org.eclipse.jface.text.source.IVerticalRulerInfo) + */ +- @Override + protected IAction createAction(ITextEditor editor, + IVerticalRulerInfo rulerInfo) { + return new PythonBreakpointPropertiesRulerAction(editor, rulerInfo); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonLaunchConfigurationDelegate.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonLaunchConfigurationDelegate.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonLaunchConfigurationDelegate.java 2005-08-14 23:28:14.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonLaunchConfigurationDelegate.java 2006-11-05 20:59:43.000000000 +0100 +@@ -6,7 +6,6 @@ + + public class JythonLaunchConfigurationDelegate extends AbstractLaunchConfigurationDelegate { + +- @Override + protected String getRunnerConfigRun() { + return PythonRunnerConfig.RUN_JYTHON; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonLaunchShortcut.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonLaunchShortcut.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonLaunchShortcut.java 2006-02-22 01:25:12.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonLaunchShortcut.java 2006-11-05 20:59:43.000000000 +0100 +@@ -9,12 +9,10 @@ + + public class JythonLaunchShortcut extends AbstractLaunchShortcut{ + +- @Override + protected String getLaunchConfigurationType() { + return Constants.ID_JYTHON_LAUNCH_CONFIGURATION_TYPE; + } + +- @Override + protected IInterpreterManager getInterpreterManager() { + return PydevPlugin.getJythonInterpreterManager(); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonUnitTestLaunchShortcut.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonUnitTestLaunchShortcut.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonUnitTestLaunchShortcut.java 2006-09-12 03:05:17.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/JythonUnitTestLaunchShortcut.java 2006-11-05 20:59:43.000000000 +0100 +@@ -17,7 +17,6 @@ + } + + +- @Override + protected IInterpreterManager getInterpreterManager() { + return PydevPlugin.getJythonInterpreterManager(); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunnerConfig.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunnerConfig.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunnerConfig.java 2006-10-24 00:16:07.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunnerConfig.java 2006-11-05 20:59:43.000000000 +0100 +@@ -400,7 +400,7 @@ + * @throws CoreException + */ + public String[] getCommandLine() throws CoreException { +- List cmdArgs = new ArrayList(); ++ List cmdArgs = new ArrayList(); + + if(isJython()){ + //"java.exe" -classpath "C:\bin\jython21\jython.jar" org.python.util.jython script %ARGS% +@@ -524,7 +524,7 @@ + * @param cmdArgs + * @throws CoreException + */ +- private void addVmArgs(List cmdArgs) throws CoreException { ++ private void addVmArgs(List cmdArgs) throws CoreException { + String[] vmArguments = getVMArguments(configuration); + if(vmArguments != null){ + for (int i = 0; i < vmArguments.length; i++){ +@@ -548,7 +548,7 @@ + String[] args; + try { + args = getCommandLine(); +- return SimpleRunner.getCommandLineAsString(args); ++ return SimpleRunner.getCommandLineAsString(args, new String[] {}); + } catch (CoreException e) { + throw new RuntimeException(e); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunner.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunner.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunner.java 2006-06-24 16:42:42.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/launching/PythonRunner.java 2006-11-05 20:59:43.000000000 +0100 +@@ -80,7 +80,7 @@ + "python interpreter (or vice-versa), so, you have to change the project type in the " + + "project properties."; + MessageDialog.openError(display.getActiveShell(), "Invalid Interpreter", +- StringUtils.format(msg, config.interpreterLocation, interpreterManager.getManagerRelatedName())); ++ StringUtils.format(msg, new Object [] {config.interpreterLocation, interpreterManager.getManagerRelatedName()})); + } + + }); +@@ -156,7 +156,7 @@ + + // Launch & connect to the debugger + subMonitor.subTask("Constructing command_line..."); +- String commandLineAsString = SimpleRunner.getCommandLineAsString(cmdLine); ++ String commandLineAsString = SimpleRunner.getCommandLineAsString(cmdLine, new String[] {}); + System.out.println("running command line: "+commandLineAsString); + Map processAttributes = new HashMap(); + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/MainModuleTab.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/MainModuleTab.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/MainModuleTab.java 2006-02-22 01:25:12.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/MainModuleTab.java 2006-11-05 20:59:43.000000000 +0100 +@@ -174,7 +174,6 @@ + return "Main"; + } + +- @Override + public Image getImage() { + return PydevPlugin.getImageCache().get(Constants.MAIN_ICON); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/propertypages/PythonBreakpointPage.java eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/propertypages/PythonBreakpointPage.java +--- eclipse-pydev-1.2.5/org.python.pydev.debug/src/org/python/pydev/debug/ui/propertypages/PythonBreakpointPage.java 2005-12-17 13:58:45.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.debug/src/org/python/pydev/debug/ui/propertypages/PythonBreakpointPage.java 2006-11-05 20:59:43.000000000 +0100 +@@ -65,7 +65,6 @@ + public static final String ATTR_DELETE_ON_CANCEL = PyDebugModelPresentation.PY_DEBUG_MODEL_ID + ".ATTR_DELETE_ON_CANCEL"; //$NON-NLS-1$ + + +- @Override + protected Control createContents(Composite parent) { + noDefaultAndApplyButton(); + Composite mainComposite = createComposite(parent, 1); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.jython/build.properties eclipse-pydev-1.2.5-patched/org.python.pydev.jython/build.properties +--- eclipse-pydev-1.2.5/org.python.pydev.jython/build.properties 2006-04-06 18:12:37.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.jython/build.properties 2006-11-05 20:59:43.000000000 +0100 +@@ -2,7 +2,6 @@ + pydev-jython.jar,\ + jython.jar,\ + jysrc/,\ +- retroweaver-rt.jar,\ + plugin.xml,\ + Lib/ + jars.compile.order = pydev-jython.jar +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.jython/META-INF/MANIFEST.MF eclipse-pydev-1.2.5-patched/org.python.pydev.jython/META-INF/MANIFEST.MF +--- eclipse-pydev-1.2.5/org.python.pydev.jython/META-INF/MANIFEST.MF 2006-04-17 20:05:57.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.jython/META-INF/MANIFEST.MF 2006-11-05 20:59:43.000000000 +0100 +@@ -4,7 +4,6 @@ + Bundle-SymbolicName: org.python.pydev.jython; singleton:=true + Bundle-Version: 0.9.7.1 + Bundle-ClassPath: pydev-jython.jar, +- retroweaver-rt.jar, + jython.jar + Bundle-Activator: org.python.pydev.jython.JythonPlugin + Bundle-Vendor: Fabio Zadrozny +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.jython/src/org/python/pydev/jython/JythonPlugin.java eclipse-pydev-1.2.5-patched/org.python.pydev.jython/src/org/python/pydev/jython/JythonPlugin.java +--- eclipse-pydev-1.2.5/org.python.pydev.jython/src/org/python/pydev/jython/JythonPlugin.java 2006-09-12 02:15:57.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.jython/src/org/python/pydev/jython/JythonPlugin.java 2006-11-05 20:59:43.000000000 +0100 +@@ -4,10 +4,11 @@ + import java.io.FileFilter; + import java.util.ArrayList; + import java.util.HashMap; ++import java.util.Iterator; + import java.util.List; + import java.util.Map; + import java.util.Properties; +- ++ + import org.eclipse.core.runtime.IPath; + import org.eclipse.core.runtime.IStatus; + import org.eclipse.core.runtime.Path; +@@ -110,7 +111,6 @@ + setPackageNames(bundles); + } + +- @SuppressWarnings("unchecked") + public Class loadClass(String className) throws ClassNotFoundException { + try { + return super.loadClass(className); +@@ -139,7 +139,7 @@ + * Set the package names available given the bundles that we can access + */ + private void setPackageNames(Bundle[] bundles) { +- List names = new ArrayList(); ++ List names = new ArrayList(); + for (int i = 0; i < bundles.length; ++i) { + String packages = (String) bundles[i].getHeaders().get("Provide-Package"); + if (packages != null) { +@@ -267,12 +267,12 @@ + * @return any error that happened while executing the script + * + */ +- public static Throwable exec(HashMap locals, String fileToExec, IPythonInterpreter interpreter) { ++ public static Throwable exec(HashMap locals, String fileToExec, IPythonInterpreter interpreter) { + File fileWithinJySrc = JythonPlugin.getFileWithinJySrc(fileToExec); + return exec(locals, interpreter, fileWithinJySrc, new File[]{fileWithinJySrc.getParentFile()}); + } + +- public static List execAll(HashMap locals, final String startingWith, IPythonInterpreter interpreter) { ++ public static List execAll(HashMap locals, final String startingWith, IPythonInterpreter interpreter) { + //exec files beneath jysrc in org.python.pydev.jython + File jySrc = JythonPlugin.getJySrcDirFile(); + File additionalScriptingLocation = JyScriptingPreferencesPage.getAdditionalScriptingLocation(); +@@ -286,9 +286,10 @@ + * @param beneathFolders the folders we want to get the scripts from + * @return the errors that occured while executing the scripts + */ +- public static List execAll(HashMap locals, final String startingWith, IPythonInterpreter interpreter, File[] beneathFolders) { +- List errors = new ArrayList(); +- for (File file : beneathFolders) { ++ public static List execAll(HashMap locals, final String startingWith, IPythonInterpreter interpreter, File[] beneathFolders) { ++ List errors = new ArrayList(); ++ for (int i = 0; i < beneathFolders.length; i++) { ++ File file = beneathFolders[i]; + if(file != null){ + if(!file.exists()){ + String msg = "The folder:"+file+" does not exist and therefore cannot be used to " + +@@ -298,7 +299,8 @@ + } + File[] files = getFilesBeneathFolder(startingWith, file); + if(files != null){ +- for(File f : files){ ++ for (int j = 0; j < files.length; j++) { ++ File f = files[j]; + Throwable throwable = exec(locals, interpreter, f, beneathFolders); + if(throwable != null){ + errors.add(throwable); +@@ -332,16 +334,16 @@ + * Holds a cache with the name of the created code to a tuple with the file timestamp and the Code Object + * that was generated with the contents of that timestamp. + */ +- private static Map> codeCache = new HashMap>(); ++ private static Map codeCache = new HashMap(); //> + + /** + * @param pythonpathFolders folders that should be in the pythonpath when executing the script + * @see JythonPlugin#exec(HashMap, String, PythonInterpreter) + * Same as before but the file to execute is passed as a parameter + */ +- public static synchronized Throwable exec(HashMap locals, IPythonInterpreter interpreter, File fileToExec, File[] pythonpathFolders) { ++ public static synchronized Throwable exec(HashMap locals, IPythonInterpreter interpreter, File fileToExec, File[] pythonpathFolders) { + if(locals == null){ +- locals = new HashMap(); ++ locals = new HashMap(); + } + synchronized (codeCache) { //hold on there... one at a time... please? + try { +@@ -352,14 +354,16 @@ + String codeObjName = "code"+fileName.substring(0, fileName.indexOf('.')); + final String codeObjTimestampName = codeObjName+"Timestamp"; + +- for (Map.Entry entry : locals.entrySet()) { +- interpreter.set(entry.getKey(), entry.getValue()); ++ for (Iterator iter = locals.entrySet().iterator(); iter.hasNext();) { ++ Map.Entry entry = (Map.Entry) iter.next(); ++ ++ interpreter.set((String) entry.getKey(), entry.getValue()); + } + + boolean regenerate = false; +- Tuple timestamp = codeCache.get(fileToExec); ++ Tuple timestamp = (Tuple) codeCache.get(fileToExec); + final long lastModified = fileToExec.lastModified(); +- if(timestamp == null || timestamp.o1 != lastModified){ ++ if(timestamp == null || ((Long)timestamp.o1).longValue() != lastModified){ + //the file timestamp changed, so, we have to regenerate it + regenerate = true; + } +@@ -385,7 +389,8 @@ + + StringBuffer strPythonPathFolders = new StringBuffer(); + strPythonPathFolders.append("["); +- for (File file : pythonpathFolders) { ++ for (int i = 0; i < pythonpathFolders.length; i++) { ++ File file = pythonpathFolders[i]; + if (file != null){ + strPythonPathFolders.append("r'"); + strPythonPathFolders.append(REF.getFileAbsolutePath(file)); +@@ -409,18 +414,18 @@ + addToSysPath.append(strPythonPathFolders); + addToSysPath.append("\n"); + +- String toExec = StringUtils.format(LOAD_FILE_SCRIPT, path, path, addToSysPath.toString()); ++ String toExec = StringUtils.format(LOAD_FILE_SCRIPT, new Object [] {path, path, addToSysPath.toString()}); + interpreter.exec(toExec); +- String exec = StringUtils.format("%s = compile(toExec, r'%s', 'exec')", codeObjName, path); ++ String exec = StringUtils.format("%s = compile(toExec, r'%s', 'exec')", new Object []{codeObjName, path}); + interpreter.exec(exec); + //set its timestamp +- interpreter.set(codeObjTimestampName, lastModified); ++ interpreter.set(codeObjTimestampName, new Long(lastModified)); + + Object codeObj = interpreter.get(codeObjName); +- codeCache.put(fileToExec, new Tuple(lastModified, codeObj)); ++ codeCache.put(fileToExec, new Tuple(new Long(lastModified), codeObj)); + } + +- interpreter.exec(StringUtils.format("exec(%s)" , codeObjName)); ++ interpreter.exec(StringUtils.format("exec(%s)" , new Object [] {codeObjName})); + } catch (Throwable e) { + if(!IN_TESTS && JythonPlugin.getDefault() == null){ + //it is already disposed +@@ -487,8 +492,8 @@ + interpreter.setOut(new ScriptOutput(getBlack(), getConsole())); + interpreter.setErr(new ScriptOutput(getRed(), getConsole())); + } +- interpreter.set("False", 0); +- interpreter.set("True", 1); ++ interpreter.set("False", new Integer(0)); ++ interpreter.set("True", new Integer(1)); + return interpreter; + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.jython/src/org/python/pydev/jython/ScriptingExtensionInitializer.java eclipse-pydev-1.2.5-patched/org.python.pydev.jython/src/org/python/pydev/jython/ScriptingExtensionInitializer.java +--- eclipse-pydev-1.2.5/org.python.pydev.jython/src/org/python/pydev/jython/ScriptingExtensionInitializer.java 2006-03-22 00:20:05.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.jython/src/org/python/pydev/jython/ScriptingExtensionInitializer.java 2006-11-05 20:59:43.000000000 +0100 +@@ -8,7 +8,6 @@ + public class ScriptingExtensionInitializer extends AbstractPreferenceInitializer{ + public static final String DEFAULT_SCOPE = "org.python.pydev.jython"; + +- @Override + public void initializeDefaultPreferences() { + Preferences node = new DefaultScope().getNode(DEFAULT_SCOPE); + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.jython/src/org/python/pydev/jython/ScriptOutput.java eclipse-pydev-1.2.5-patched/org.python.pydev.jython/src/org/python/pydev/jython/ScriptOutput.java +--- eclipse-pydev-1.2.5/org.python.pydev.jython/src/org/python/pydev/jython/ScriptOutput.java 2006-03-22 02:42:15.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.jython/src/org/python/pydev/jython/ScriptOutput.java 2006-11-05 20:59:43.000000000 +0100 +@@ -71,7 +71,6 @@ + /** + * OutputStream interface + */ +- @Override + public void write(int b) throws IOException { + if(writeToConsole){ + IOConsoleOutputStream out = getOutputStream(); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.jython/src/org/python/pydev/jython/ui/JyScriptingPreferencesPage.java eclipse-pydev-1.2.5-patched/org.python.pydev.jython/src/org/python/pydev/jython/ui/JyScriptingPreferencesPage.java +--- eclipse-pydev-1.2.5/org.python.pydev.jython/src/org/python/pydev/jython/ui/JyScriptingPreferencesPage.java 2006-04-21 21:31:01.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.jython/src/org/python/pydev/jython/ui/JyScriptingPreferencesPage.java 2006-11-05 20:59:43.000000000 +0100 +@@ -29,7 +29,6 @@ + public void init(IWorkbench workbench) { + } + +- @Override + public void createFieldEditors() { + Composite p = getFieldEditorParent(); + addField(new BooleanFieldEditor(SHOW_SCRIPTING_OUTPUT, "Show the output given from the scripting to some console?", p)); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/build.properties eclipse-pydev-1.2.5-patched/org.python.pydev.parser/build.properties +--- eclipse-pydev-1.2.5/org.python.pydev.parser/build.properties 2005-09-03 17:59:02.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/build.properties 2006-11-05 20:59:43.000000000 +0100 +@@ -2,5 +2,4 @@ + output.parser.jar = bin/ + bin.includes = plugin.xml,\ + META-INF/,\ +- parser.jar,\ +- retroweaver-rt.jar ++ parser.jar +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/.classpath eclipse-pydev-1.2.5-patched/org.python.pydev.parser/.classpath +--- eclipse-pydev-1.2.5/org.python.pydev.parser/.classpath 2005-07-18 15:04:39.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/.classpath 2006-11-05 20:59:43.000000000 +0100 +@@ -3,6 +3,5 @@ + + + +- + + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/JJTPythonGrammar24State.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/JJTPythonGrammar24State.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/JJTPythonGrammar24State.java 2006-09-16 14:15:43.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/JJTPythonGrammar24State.java 2006-11-05 20:59:43.000000000 +0100 +@@ -11,7 +11,7 @@ + import org.python.pydev.parser.jython.SimpleNode; + + class JJTPythonGrammar24State { +- private FastStack nodes; ++ private FastStack nodes; + private IntStack marks; + private IntStack lines; + private IntStack columns; +@@ -23,7 +23,7 @@ + TreeBuilder24 builder; + + JJTPythonGrammar24State() { +- nodes = new FastStack(); ++ nodes = new FastStack(); + marks = new IntStack(); + lines = new IntStack(); + columns = new IntStack(); +@@ -51,7 +51,7 @@ + /* Returns the root node of the AST. It only makes sense to call + this after a successful parse. */ + Node rootNode() { +- return nodes.getFirst(); ++ return (Node) nodes.getFirst(); + } + + /* Pushes a node on to the stack. */ +@@ -66,12 +66,12 @@ + if (--sp < mk) { + mk = marks.pop(); + } +- return nodes.pop(); ++ return (SimpleNode) nodes.pop(); + } + + /* Returns the node currently on the top of the stack. */ + SimpleNode peekNode() { +- return nodes.peek(); ++ return (SimpleNode) nodes.peek(); + } + + /* Returns the number of children on the stack in the current node +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/PythonGrammar24.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/PythonGrammar24.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/PythonGrammar24.java 2006-09-16 14:15:43.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/PythonGrammar24.java 2006-11-05 20:59:43.000000000 +0100 +@@ -82,7 +82,7 @@ + Object next = iter.next(); + int strategy = STRATEGY_ADD_AFTER_PREV; // default strategy + if (next instanceof Object[]) { +- strategy = (Integer) ((Object[]) next)[1]; ++ strategy = ((Integer) ((Object[]) next)[1]).intValue(); + next = ((Object[]) next)[0]; + } + +@@ -137,12 +137,12 @@ + } + + private void addSpecialToken(Object o, int strategy) { +- token_source.specialTokens.add(new Object[]{o, strategy}); ++ token_source.specialTokens.add(new Object[]{o, new Integer(strategy)}); + } + + private void addSpecialToken(Object o) { + //the default is adding after the previous token +- token_source.specialTokens.add(new Object[]{o, STRATEGY_ADD_AFTER_PREV}); ++ token_source.specialTokens.add(new Object[]{o, new Integer(STRATEGY_ADD_AFTER_PREV)}); + } + + +@@ -189,7 +189,7 @@ + */ + private boolean findTokenAndAdd(String token, String put, boolean searchOnLast) throws ParseException { + Object s = createSpecialStr(token, put, searchOnLast); +- token_source.specialTokens.add(new Object[]{s, STRATEGY_ADD_AFTER_PREV}); ++ token_source.specialTokens.add(new Object[]{s, new Integer(STRATEGY_ADD_AFTER_PREV)}); + return s instanceof SpecialStr; + } + +@@ -249,7 +249,7 @@ + //raw string (does not decode slashes) + String str = s.substring(quotes+start+1, s.length()-quotes); + //System.out.println("out: "+str); +- return new Object[]{str,ustring, true, getType(s.charAt(start+1), quotes)}; ++ return new Object[]{str, new Boolean(ustring), new Boolean(true), new Integer(getType(s.charAt(start+1), quotes))}; + + } else { + int n = s.length()-quotes; +@@ -257,7 +257,7 @@ + + String str = hostLiteralMkr.decode_UnicodeEscape(s, i, n, "strict", ustring); + //System.out.println("out: "+str); +- return new Object[]{str, ustring, false, getType(s.charAt(start), quotes)}; ++ return new Object[]{str, new Boolean(ustring), new Boolean(false), new Integer(getType(s.charAt(start), quotes))}; + } + } + +@@ -524,7 +524,7 @@ + } + + //file_input: (NEWLINE | stmt)* ENDMARKER +- final public modType file_input() throws ParseException { ++ final public SimpleNode file_input() throws ParseException { + /*@bgen(jjtree) file_input */ + SimpleNode jjtn000 = jjtree.builder.openNode( JJTFILE_INPUT); + boolean jjtc000 = true; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/TreeBuilder24.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/TreeBuilder24.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/TreeBuilder24.java 2006-09-26 14:09:55.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar24/TreeBuilder24.java 2006-11-05 20:59:43.000000000 +0100 +@@ -172,7 +172,7 @@ + case JJTUNICODE: + case JJTSTRING: + Object[] image = (Object[]) n.getImage(); +- return new Str((String)image[0], (Integer)image[3], (Boolean)image[1], (Boolean)image[2]); ++ return new Str((String)image[0], ((Integer)image[3]).intValue(), ((Boolean)image[1]).booleanValue(), ((Boolean)image[2]).booleanValue()); + + case JJTSUITE: + stmtType[] stmts = new stmtType[arity]; +@@ -321,8 +321,8 @@ + case JJTBEGIN_DECORATOR: + return new decoratorsType(null,null,null,null, null); + case JJTDECORATORS: +- ArrayList list2 = new ArrayList(); +- ArrayList listArgs = new ArrayList(); ++ ArrayList list2 = new ArrayList(); ++ ArrayList listArgs = new ArrayList(); + while(stack.nodeArity() > 0){ + SimpleNode node = stack.popNode(); + while(!(node instanceof decoratorsType)){ +@@ -664,8 +664,8 @@ + + exprType[] values = new exprType[3]; + int k = 0; +- java.util.List specialsBefore = new ArrayList(); +- java.util.List specialsAfter = new ArrayList(); ++ java.util.List specialsBefore = new ArrayList(); ++ java.util.List specialsAfter = new ArrayList(); + for (int j = 0; j < arity; j++) { + if (arr[j].getId() == JJTCOLON){ + if(arr[j].specialsBefore != null){ +@@ -852,15 +852,15 @@ + } + + +- SimpleNode makeDecorator(java.util.List nodes){ ++ SimpleNode makeDecorator(java.util.List nodes){ + exprType starargs = null; + exprType kwargs = null; + + exprType func = null; +- ArrayList keywordsl = new ArrayList(); +- ArrayList argsl = new ArrayList(); +- for (Iterator iter = nodes.iterator(); iter.hasNext();) { +- SimpleNode node = iter.next(); ++ ArrayList keywordsl = new ArrayList(); ++ ArrayList argsl = new ArrayList(); ++ for (Iterator iter = nodes.iterator(); iter.hasNext();) { ++ SimpleNode node = (SimpleNode) iter.next(); + + + if (node.getId() == JJTEXTRAKEYWORDVALUELIST) { +@@ -933,11 +933,11 @@ + return false; + } + +- NameTok[] getVargAndKwarg(java.util.List args) throws Exception { ++ NameTok[] getVargAndKwarg(java.util.List args) throws Exception { + NameTok varg = null; + NameTok kwarg = null; +- for (Iterator iter = args.iterator(); iter.hasNext();) { +- SimpleNode node = iter.next(); ++ for (Iterator iter = args.iterator(); iter.hasNext();) { ++ SimpleNode node = (SimpleNode) iter.next(); + if(node.getId() == JJTEXTRAKEYWORDLIST){ + ExtraArg a = (ExtraArg)node; + kwarg = a.tok; +@@ -999,7 +999,7 @@ + l--; + addSpecialsAndClearOriginal(node, stararg); + } +- ArrayList list = new ArrayList(); ++ ArrayList list = new ArrayList(); + for (int i = l-1; i >= 0; i--) { + list.add((DefaultArg) stack.popNode()); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/JJTPythonGrammar25State.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/JJTPythonGrammar25State.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/JJTPythonGrammar25State.java 2006-09-22 01:02:05.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/JJTPythonGrammar25State.java 2006-11-05 20:59:43.000000000 +0100 +@@ -11,7 +11,7 @@ + import org.python.pydev.parser.jython.SimpleNode; + + class JJTPythonGrammar25State { +- private FastStack nodes; ++ private FastStack nodes; + private IntStack marks; + private IntStack lines; + private IntStack columns; +@@ -23,7 +23,7 @@ + TreeBuilder25 builder; + + JJTPythonGrammar25State() { +- nodes = new FastStack(); ++ nodes = new FastStack(); + marks = new IntStack(); + lines = new IntStack(); + columns = new IntStack(); +@@ -51,7 +51,7 @@ + /* Returns the root node of the AST. It only makes sense to call + this after a successful parse. */ + Node rootNode() { +- return nodes.getFirst(); ++ return (Node) nodes.getFirst(); + } + + /* Pushes a node on to the stack. */ +@@ -66,12 +66,12 @@ + if (--sp < mk) { + mk = marks.pop(); + } +- return nodes.pop(); ++ return (SimpleNode) nodes.pop(); + } + + /* Returns the node currently on the top of the stack. */ + SimpleNode peekNode() { +- return nodes.peek(); ++ return (SimpleNode) nodes.peek(); + } + + /* Returns the number of children on the stack in the current node +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/PythonGrammar25.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/PythonGrammar25.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/PythonGrammar25.java 2006-09-22 01:02:05.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/PythonGrammar25.java 2006-11-05 20:59:43.000000000 +0100 +@@ -90,7 +90,7 @@ + Object next = iter.next(); + int strategy = STRATEGY_ADD_AFTER_PREV; // default strategy + if (next instanceof Object[]) { +- strategy = (Integer) ((Object[]) next)[1]; ++ strategy = ((Integer) ((Object[]) next)[1]).intValue(); + next = ((Object[]) next)[0]; + } + +@@ -145,12 +145,12 @@ + } + + private void addSpecialToken(Object o, int strategy) { +- token_source.specialTokens.add(new Object[]{o, strategy}); ++ token_source.specialTokens.add(new Object[]{o, new Integer(strategy)}); + } + + private void addSpecialToken(Object o) { + //the default is adding after the previous token +- token_source.specialTokens.add(new Object[]{o, STRATEGY_ADD_AFTER_PREV}); ++ token_source.specialTokens.add(new Object[]{o, new Integer(STRATEGY_ADD_AFTER_PREV)}); + } + + +@@ -197,7 +197,7 @@ + */ + private boolean findTokenAndAdd(String token, String put, boolean searchOnLast) throws ParseException { + Object s = createSpecialStr(token, put, searchOnLast); +- token_source.specialTokens.add(new Object[]{s, STRATEGY_ADD_AFTER_PREV}); ++ token_source.specialTokens.add(new Object[]{s, new Integer(STRATEGY_ADD_AFTER_PREV)}); + return s instanceof SpecialStr; + } + +@@ -257,7 +257,7 @@ + //raw string (does not decode slashes) + String str = s.substring(quotes+start+1, s.length()-quotes); + //System.out.println("out: "+str); +- return new Object[]{str,ustring, true, getType(s.charAt(start+1), quotes)}; ++ return new Object[]{str,new Boolean(ustring), new Boolean(true), new Integer(getType(s.charAt(start+1), quotes))}; + + } else { + int n = s.length()-quotes; +@@ -265,7 +265,7 @@ + + String str = hostLiteralMkr.decode_UnicodeEscape(s, i, n, "strict", ustring); + //System.out.println("out: "+str); +- return new Object[]{str, ustring, false, getType(s.charAt(start), quotes)}; ++ return new Object[]{str, new Boolean(ustring), new Boolean(false), new Integer(getType(s.charAt(start), quotes))}; + } + } + +@@ -534,7 +534,7 @@ + } + + //file_input: (NEWLINE | stmt)* ENDMARKER +- final public modType file_input() throws ParseException { ++ final public SimpleNode file_input() throws ParseException { + /*@bgen(jjtree) file_input */ + SimpleNode jjtn000 = jjtree.builder.openNode( JJTFILE_INPUT); + boolean jjtc000 = true; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/TreeBuilder25.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/TreeBuilder25.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/TreeBuilder25.java 2006-09-22 01:02:05.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/grammar25/TreeBuilder25.java 2006-11-05 20:59:43.000000000 +0100 +@@ -171,7 +171,7 @@ + case JJTUNICODE: + case JJTSTRING: + Object[] image = (Object[]) n.getImage(); +- return new Str((String)image[0], (Integer)image[3], (Boolean)image[1], (Boolean)image[2]); ++ return new Str((String)image[0], ((Integer)image[3]).intValue(), ((Boolean)image[1]).booleanValue(), ((Boolean)image[2]).booleanValue()); + + case JJTSUITE: + stmtType[] stmts = new stmtType[arity]; +@@ -320,8 +320,8 @@ + case JJTBEGIN_DECORATOR: + return new decoratorsType(null,null,null,null, null); + case JJTDECORATORS: +- ArrayList list2 = new ArrayList(); +- ArrayList listArgs = new ArrayList(); ++ ArrayList list2 = new ArrayList(); ++ ArrayList listArgs = new ArrayList(); + while(stack.nodeArity() > 0){ + SimpleNode node = stack.popNode(); + while(!(node instanceof decoratorsType)){ +@@ -714,8 +714,8 @@ + + exprType[] values = new exprType[3]; + int k = 0; +- java.util.List specialsBefore = new ArrayList(); +- java.util.List specialsAfter = new ArrayList(); ++ java.util.List specialsBefore = new ArrayList(); ++ java.util.List specialsAfter = new ArrayList(); + for (int j = 0; j < arity; j++) { + if (arr[j].getId() == JJTCOLON){ + if(arr[j].specialsBefore != null){ +@@ -800,7 +800,7 @@ + col = new ComprehensionCollection(); + } + +- ArrayList ifs = new ArrayList(); ++ ArrayList ifs = new ArrayList(); + for (int i = arity-3; i >= 0; i--) { + SimpleNode ifsNode = stack.popNode(); + ifs.add((exprType) ifsNode); +@@ -808,10 +808,10 @@ + iter = (exprType) stack.popNode(); + target = (exprType) stack.popNode(); + ctx.setStore(target); +- col.added.add(new Comprehension(target, iter, ifs.toArray(new exprType[0]))); ++ col.added.add(new Comprehension(target, iter, (exprType []) ifs.toArray(new exprType[0]))); + return col; + case JJTIMPORTFROM: +- ArrayList aliastL = new ArrayList(); ++ ArrayList aliastL = new ArrayList(); + while(arity > 0 && stack.peekNode() instanceof aliasType){ + aliastL.add(0, (aliasType) stack.popNode()); + arity--; +@@ -822,7 +822,7 @@ + }else{ + nT = new NameTok("", NameTok.ImportModule); + } +- return new ImportFrom((NameTokType)nT, aliastL.toArray(new aliasType[0]), 0); ++ return new ImportFrom((NameTokType)nT, (aliasType []) aliastL.toArray(new aliasType[0]), 0); + case JJTIMPORT: + return new Import(makeAliases(arity)); + +@@ -922,15 +922,15 @@ + } + + +- SimpleNode makeDecorator(java.util.List nodes){ ++ SimpleNode makeDecorator(java.util.List nodes){ + exprType starargs = null; + exprType kwargs = null; + + exprType func = null; +- ArrayList keywordsl = new ArrayList(); +- ArrayList argsl = new ArrayList(); +- for (Iterator iter = nodes.iterator(); iter.hasNext();) { +- SimpleNode node = iter.next(); ++ ArrayList keywordsl = new ArrayList(); ++ ArrayList argsl = new ArrayList(); ++ for (Iterator iter = nodes.iterator(); iter.hasNext();) { ++ SimpleNode node = (SimpleNode) iter.next(); + + + if (node.getId() == JJTEXTRAKEYWORDVALUELIST) { +@@ -1006,11 +1006,11 @@ + return false; + } + +- NameTok[] getVargAndKwarg(java.util.List args) throws Exception { ++ NameTok[] getVargAndKwarg(java.util.List args) throws Exception { + NameTok varg = null; + NameTok kwarg = null; +- for (Iterator iter = args.iterator(); iter.hasNext();) { +- SimpleNode node = iter.next(); ++ for (Iterator iter = args.iterator(); iter.hasNext();) { ++ SimpleNode node = (SimpleNode) iter.next(); + if(node.getId() == JJTEXTRAKEYWORDLIST){ + ExtraArg a = (ExtraArg)node; + kwarg = a.tok; +@@ -1072,7 +1072,7 @@ + l--; + addSpecialsAndClearOriginal(node, stararg); + } +- ArrayList list = new ArrayList(); ++ ArrayList list = new ArrayList(); + for (int i = l-1; i >= 0; i--) { + SimpleNode popped = null; + try{ +@@ -1090,13 +1090,13 @@ + + + class ComprehensionCollection extends SimpleNode{ +- public ArrayList added = new ArrayList(); ++ public ArrayList added = new ArrayList(); + + public comprehensionType[] getGenerators() { +- ArrayList f = added; ++ ArrayList f = added; + added = null; + Collections.reverse(f); +- return f.toArray(new comprehensionType[0]); ++ return (comprehensionType []) f.toArray(new comprehensionType[0]); + } + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/IParserObserver2.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/IParserObserver2.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/IParserObserver2.java 2006-05-15 15:47:28.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/IParserObserver2.java 2006-11-05 20:59:43.000000000 +0100 +@@ -9,11 +9,11 @@ + /** + * Has the argsToReparse additional Parameter + */ +- void parserChanged(SimpleNode root, IAdaptable file, IDocument doc, Object ... argsToReparse); ++ void parserChanged(SimpleNode root, IAdaptable file, IDocument doc, Object[] argsToReparse); + + /** + * Has the argsToReparse additional Parameter + */ +- void parserError(Throwable error, IAdaptable file, IDocument doc, Object ... argsToReparse); ++ void parserError(Throwable error, IAdaptable file, IDocument doc, Object[] argsToReparse); + + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/jython/SimpleNode.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/jython/SimpleNode.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/jython/SimpleNode.java 2006-09-15 03:19:18.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/jython/SimpleNode.java 2006-11-05 20:59:43.000000000 +0100 +@@ -4,6 +4,7 @@ + import java.io.DataOutputStream; + import java.io.IOException; + import java.util.ArrayList; ++import java.util.Iterator; + import java.util.List; + + import org.python.pydev.parser.grammar25.PythonGrammar25; +@@ -26,8 +27,8 @@ + * + * They are only initialized 'on-demand' + */ +- public List specialsBefore; +- public List specialsAfter; ++ public List specialsBefore; ++ public List specialsAfter; + + public SimpleNode() { } + +@@ -86,16 +87,16 @@ + } + } + +- public List getSpecialsBefore() { ++ public List getSpecialsBefore() { + if(specialsBefore == null){ +- specialsBefore = new ArrayList(); ++ specialsBefore = new ArrayList(); + } + return specialsBefore; + } + +- public List getSpecialsAfter() { ++ public List getSpecialsAfter() { + if(specialsAfter == null){ +- specialsAfter = new ArrayList(); ++ specialsAfter = new ArrayList(); + } + return specialsAfter; + } +@@ -137,7 +138,9 @@ + return 0; + } + int i=0; +- for(Object o : l){ ++ for (Iterator iter = l.iterator(); iter.hasNext();) { ++ Object o = (Object) iter.next(); ++ + int[] existing = getLineCol(o); + if(existing == null){ + //do nothing... (will be after it) +@@ -177,7 +180,9 @@ + return 0; + } + int i=0; +- for(Object o : l){ ++ for (Iterator iter = l.iterator(); iter.hasNext();) { ++ Object o = (Object) iter.next(); ++ + if (o instanceof String || o instanceof SpecialStr){ + i++; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/jython/SpecialStr.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/jython/SpecialStr.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/jython/SpecialStr.java 2006-03-20 20:37:35.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/jython/SpecialStr.java 2006-11-05 20:59:43.000000000 +0100 +@@ -11,17 +11,14 @@ + this.beginCol = beginCol; + } + +- @Override + public String toString() { + return str; + } + +- @Override + public int hashCode() { + return str.hashCode(); + } + +- @Override + public boolean equals(Object obj) { + if(!(obj instanceof SpecialStr)){ + return false; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/ParserScheduler.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/ParserScheduler.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/ParserScheduler.java 2006-06-07 23:54:45.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/ParserScheduler.java 2006-11-05 20:59:43.000000000 +0100 +@@ -62,13 +62,13 @@ + + + public void parseNow() { +- parseNow(false); ++ parseNow(false, new Object[] {}); + } + + /** + * The arguments passed in argsToReparse will be passed to the reparseDocument, and then on to fireParserChanged / fireParserError + */ +- public void parseNow(boolean force, Object ... argsToReparse) { ++ public void parseNow(boolean force, Object[] argsToReparse) { + if(!force){ + if(state != STATE_WAITING_FOR_ELAPSE && state != STATE_DOING_PARSE){ + //waiting or parse later +@@ -108,7 +108,7 @@ + */ + private boolean checkCreateAndStartParsingThread() { + if(parsingThread == null){ +- parsingThread = new ParsingThread(this); ++ parsingThread = new ParsingThread(this, new Object[] {}); + parsingThread.setPriority(Thread.MIN_PRIORITY); //parsing is low priority + parsingThread.start(); + return true; +@@ -122,7 +122,6 @@ + //ok, the time for this request is: + timeParseLaterRequested = System.currentTimeMillis(); + Thread thread = new Thread(){ +- @Override + public void run() { + try { + sleep(TIME_TO_PARSE_LATER); +@@ -147,7 +146,7 @@ + * + * The argsToReparse will be passed to the IParserObserver2 + */ +- public void reparseDocument(Object ... argsToReparse) { ++ public void reparseDocument(Object[] argsToReparse) { + parser.reparseDocument(argsToReparse); + } + +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/ParsingThread.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/ParsingThread.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/ParsingThread.java 2006-05-15 15:47:28.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/ParsingThread.java 2006-11-05 20:59:43.000000000 +0100 +@@ -15,7 +15,7 @@ + private ParserScheduler parser; + private Object[] argsToReparse; + +- ParsingThread(ParserScheduler parser, Object ... argsToReparse) { ++ ParsingThread(ParserScheduler parser, Object[] argsToReparse) { + super(); + this.parser = parser; + this.argsToReparse = argsToReparse; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/PyParser.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/PyParser.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/PyParser.java 2006-09-17 14:43:57.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/PyParser.java 2006-11-05 20:59:43.000000000 +0100 +@@ -92,7 +92,7 @@ + /** + * listeners that get notified of succesfull or unsuccessful parser achievements + */ +- private ArrayList parserListeners; ++ private ArrayList parserListeners; + + /** + * used to enable tracing in the grammar +@@ -124,7 +124,7 @@ + */ + public PyParser(IGrammarVersionProvider grammarVersionProvider) { + this.grammarVersionProvider = grammarVersionProvider; +- parserListeners = new ArrayList(); ++ parserListeners = new ArrayList(); + scheduler = new ParserScheduler(this); + + documentListener = new IDocumentListener() { +@@ -179,10 +179,10 @@ + + public void notifySaved() { + //force parse on save +- parseNow(true); ++ parseNow(true, new Object[] {}); + } + +- public void parseNow(boolean force, Object ... argsToReparse){ ++ public void parseNow(boolean force, Object[] argsToReparse){ + scheduler.parseNow(force, argsToReparse); + } + +@@ -207,7 +207,7 @@ + + if(addToScheduler){ + // Reparse document on the initial set (force it) +- scheduler.parseNow(true); ++ scheduler.parseNow(true, new Object[] {}); + } + } + +@@ -236,11 +236,12 @@ + * stock listener implementation event is fired whenever we get a new root + * @param original + */ +- @SuppressWarnings("unchecked") +- protected void fireParserChanged(SimpleNode root, IAdaptable file, IDocument doc, Object ... argsToReparse) { ++ protected void fireParserChanged(SimpleNode root, IAdaptable file, IDocument doc, Object[] argsToReparse) { + this.root = root; + synchronized(parserListeners){ +- for (IParserObserver l : new ArrayList(parserListeners)) { //work on a copy (because listeners may want to remove themselves and we cannot afford concurrent modifications here) ++ for (Iterator iter = (new ArrayList(parserListeners)).iterator(); iter.hasNext();) { //work on a copy (because listeners may want to remove themselves and we cannot afford concurrent modifications here) ++ IParserObserver l = (IParserObserver) iter.next(); ++ + if(l instanceof IParserObserver2){ + ((IParserObserver2)l).parserChanged(root, file, doc, argsToReparse); + }else{ +@@ -248,8 +249,10 @@ + } + } + +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_PARSER_OBSERVER); +- for (IParserObserver observer : participants) { ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_PARSER_OBSERVER); ++ for (Iterator iter = participants.iterator(); iter.hasNext();) { ++ IParserObserver observer = (IParserObserver) iter.next(); ++ + if(observer instanceof IParserObserver2){ + ((IParserObserver2)observer).parserChanged(root, file, doc, argsToReparse); + }else{ +@@ -263,18 +266,21 @@ + * stock listener implementation event is fired when parse fails + * @param original + */ +- @SuppressWarnings("unchecked") +- protected void fireParserError(Throwable error, IAdaptable file, IDocument doc, Object ... argsToReparse) { ++ protected void fireParserError(Throwable error, IAdaptable file, IDocument doc, Object [] argsToReparse) { + synchronized(parserListeners){ +- for (IParserObserver l : new ArrayList(parserListeners)) {//work on a copy (because listeners may want to remove themselves and we cannot afford concurrent modifications here) ++ for (Iterator iter = new ArrayList(parserListeners).iterator(); iter.hasNext();) { //work on a copy (because listeners may want to remove themselves and we cannot afford concurrent modifications here) ++ IParserObserver l = (IParserObserver) iter.next(); ++ + if(l instanceof IParserObserver2){ + ((IParserObserver2)l).parserError(error, file, doc, argsToReparse); + }else{ + l.parserError(error, file, doc); + } + } +- List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_PARSER_OBSERVER); +- for (IParserObserver observer : participants) { ++ List participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_PARSER_OBSERVER); ++ for (Iterator iter = participants.iterator(); iter.hasNext();) { ++ IParserObserver observer = (IParserObserver) iter.next(); ++ + if(observer instanceof IParserObserver2){ + ((IParserObserver2)observer).parserError(error, file, doc, argsToReparse); + }else{ +@@ -296,10 +302,10 @@ + * @return a tuple with the SimpleNode root(if parsed) and the error (if any). + * if we are able to recover from a reparse, we have both, the root and the error. + */ +- public Tuple reparseDocument(Object ... argsToReparse) { ++ public Tuple reparseDocument(Object [] argsToReparse) { + + //get the document ast and error in object +- Tuple obj = reparseDocument(new ParserInfo(document, true, grammarVersionProvider.getGrammarVersion())); ++ Tuple obj = reparseDocument(new ParserInfo(document, true, grammarVersionProvider.getGrammarVersion())); + + IFile original = null; + IAdaptable adaptable = null; +@@ -342,7 +348,7 @@ + + if(obj.o1 != null){ + //ok, reparse succesful, lets erase the markers that are in the editor we just parsed +- fireParserChanged(obj.o1, adaptable, document, argsToReparse); ++ fireParserChanged((SimpleNode) obj.o1, adaptable, document, argsToReparse); + } + + if(obj.o2 != null && obj.o2 instanceof ParseException){ +@@ -366,7 +372,7 @@ + public boolean stillTryToChangeCurrentLine=true; + public int currentLine=-1; + public String initial = null; +- public List linesChanged = new ArrayList(); ++ public List linesChanged = new ArrayList(); + public ParseException parseErr; + public boolean tryReparse = TRY_REPARSE; + public int grammarVersion; +@@ -391,7 +397,7 @@ + * @return a tuple with the SimpleNode root(if parsed) and the error (if any). + * if we are able to recover from a reparse, we have both, the root and the error. + */ +- public static Tuple reparseDocument(ParserInfo info) { ++ public static Tuple reparseDocument(ParserInfo info) { + // create a stream with document's data + String startDoc = info.document.get(); + if(info.initial == null){ +@@ -443,7 +449,7 @@ + Module m = (Module) newRoot; + m.addSpecial(new commentType(endingComments.toString()), true); + } +- return new Tuple(newRoot,null); ++ return new Tuple(newRoot,null); + + + } catch (ParseException parseErr) { +@@ -462,7 +468,7 @@ + newRoot = tryReparseAgain(info, info.parseErr); + } + } +- return new Tuple(newRoot, parseErr); ++ return new Tuple(newRoot, parseErr); + + + } catch (TokenMgrError tokenErr) { +@@ -474,11 +480,11 @@ + } + } + +- return new Tuple(newRoot, tokenErr); ++ return new Tuple(newRoot, tokenErr); + + } catch (Exception e) { + Log.log(e); +- return new Tuple(null, null); ++ return new Tuple(null, null); + + } catch (Throwable e) { + //PythonGrammar$LookaheadSuccess error: this happens sometimes when the file is +@@ -488,7 +494,7 @@ + }else{ + Log.log(e); + } +- return new Tuple(null, null); ++ return new Tuple(null, null); + } + } + +@@ -579,7 +585,7 @@ + Document doc = new Document(docToParse); + info.document = doc; + info.stillTryToChangeCurrentLine = false; +- return reparseDocument(info).o1; ++ return (SimpleNode) reparseDocument(info).o1; + } + return null; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/comparator/SimpleNodeComparator.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/comparator/SimpleNodeComparator.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/comparator/SimpleNodeComparator.java 2006-04-06 18:17:51.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/comparator/SimpleNodeComparator.java 2006-11-05 20:59:43.000000000 +0100 +@@ -13,16 +13,14 @@ + + class FlatVisitor extends VisitorBase{ + +- List visited = new ArrayList(); ++ List visited = new ArrayList(); + +- @Override + protected Object unhandled_node(SimpleNode node) throws Exception { + visited.add(node); + //System.out.println("adding:"+node.getClass().getName()); + return null; + } + +- @Override + public void traverse(SimpleNode node) throws Exception { + node.traverse(this); + } +@@ -38,12 +36,12 @@ + FlatVisitor flatVisitor = new FlatVisitor(); + flatVisitor.traverse(original); + +- Iterator it = flatVisitorOriginal.visited.iterator(); +- Iterator it2 = flatVisitor.visited.iterator(); ++ Iterator it = flatVisitorOriginal.visited.iterator(); ++ Iterator it2 = flatVisitor.visited.iterator(); + + while(it.hasNext() && it2.hasNext()){ +- SimpleNode node = it.next(); +- SimpleNode node2 = it2.next(); ++ SimpleNode node = (SimpleNode) it.next(); ++ SimpleNode node2 = (SimpleNode) it2.next(); + if(node.getClass() != node2.getClass()){ + throw new DifferException("Nodes differ. "+node.getClass().getName()+" != "+ node2.getClass().getName()); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/NodeUtils.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/NodeUtils.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/NodeUtils.java 2006-10-28 18:54:06.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/NodeUtils.java 2006-11-05 20:59:43.000000000 +0100 +@@ -44,7 +44,8 @@ + public static String getNodeArgs(SimpleNode node) { + if(node instanceof ClassDef){ + ClassDef c = (ClassDef) node; +- for(stmtType t: c.body){ ++ for (int i = 0; i < c.body.length; i++) { ++ stmtType t = c.body[i]; + if(t instanceof FunctionDef){ + FunctionDef def = (FunctionDef) t; + if(((NameTok)def.name).id.equals("__init__")){ +@@ -161,7 +162,9 @@ + if (node instanceof Tuple){ + StringBuffer buf = new StringBuffer(); + Tuple t = (Tuple)node; +- for ( exprType e : t.elts){ ++ for (int i = 0; i < t.elts.length; i++) { ++ exprType e = t.elts[i]; ++ + buf.append(getRepresentationString(e, useTypeRepr)); + buf.append(", "); + } +@@ -187,7 +190,9 @@ + + if (node instanceof Import){ + aliasType[] names = ((Import)node).names; +- for (aliasType n : names) { ++ for (int i = 0; i < names.length; i++) { ++ aliasType n = names[i]; ++ + if(n.asname != null){ + return ((NameTok)n.asname).id; + } +@@ -276,7 +281,9 @@ + //get it forwards + List attributeParts = getAttributeParts((Attribute) node); + StringBuffer buf = new StringBuffer(); +- for (Object part : attributeParts) { ++ for (Iterator iter = attributeParts.iterator(); iter.hasNext();) { ++ Object part = (Object) iter.next(); ++ + if(part instanceof Call){ + //stop on a call (that's what we usually want, since the end will depend on the things that + //return from the call). +@@ -536,8 +543,8 @@ + * @return a list with the attribute parts in its forward order, and not backward as presented + * in the grammar. + */ +- public static List getAttributeParts(Attribute node) { +- ArrayList nodes = new ArrayList(); ++ public static List getAttributeParts(Attribute node) { ++ ArrayList nodes = new ArrayList(); + + nodes.add(node.attr); + SimpleNode s = node.value; +@@ -569,9 +576,11 @@ + * @param onlyLastSegment determines whether we should return only the last segment if the name + * of the parent resolves to a dotted name. + */ +- public static List getParentNames(ClassDef def, boolean onlyLastSegment) { +- ArrayList ret = new ArrayList(); +- for(exprType base: def.bases){ ++ public static List getParentNames(ClassDef def, boolean onlyLastSegment) { ++ ArrayList ret = new ArrayList(); ++ for (int i = 0; i < def.bases.length; i++) { ++ exprType base = def.bases[i]; ++ + String rep = getFullRepresentationString(base); + if(onlyLastSegment){ + rep = FullRepIterable.getLastPart(rep); +@@ -603,7 +612,9 @@ + + + public static NameTok getNameForRep(aliasType[] names, String representation) { +- for (aliasType name : names) { ++ for (int i = 0; i < names.length; i++) { ++ aliasType name = names[i]; ++ + NameTok nameForAlias = getNameForAlias(name); + String aliasRep = NodeUtils.getRepresentationString(nameForAlias); + if(representation.equals(aliasRep)){ +@@ -622,10 +633,10 @@ + public static String getContextName(int lineNumber, SimpleNode ast) { + if(ast != null){ + EasyASTIteratorVisitor visitor = EasyASTIteratorVisitor.create(ast); +- Iterator classesAndMethodsIterator = visitor.getClassesAndMethodsIterator(); ++ Iterator classesAndMethodsIterator = visitor.getClassesAndMethodsIterator(); + ASTEntry last = null; + while (classesAndMethodsIterator.hasNext()) { +- ASTEntry entry = classesAndMethodsIterator.next(); ++ ASTEntry entry = (ASTEntry) classesAndMethodsIterator.next(); + if(entry.node.beginLine > lineNumber+1){ + //ok, now, let's find out which context actually contains it... + break; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/PythonLanguageUtils.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/PythonLanguageUtils.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/PythonLanguageUtils.java 2006-06-10 13:23:30.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/PythonLanguageUtils.java 2006-11-05 20:59:43.000000000 +0100 +@@ -44,11 +44,13 @@ + "yield" + }; + +- public static final SortedSet KEYWORDS_SET = createKeywordsSet(); ++ public static final SortedSet KEYWORDS_SET = createKeywordsSet(); + +- private static SortedSet createKeywordsSet() { +- TreeSet set = new TreeSet(); +- for(String k : KEYWORDS){ ++ private static SortedSet createKeywordsSet() { ++ TreeSet set = new TreeSet(); ++ for (int i = 0; i < KEYWORDS.length; i++) { ++ String k = KEYWORDS[i]; ++ + set.add(k); + } + return set; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/ASTEntryWithChildren.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/ASTEntryWithChildren.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/ASTEntryWithChildren.java 2006-06-10 20:43:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/ASTEntryWithChildren.java 2006-11-05 20:59:43.000000000 +0100 +@@ -10,7 +10,7 @@ + + public class ASTEntryWithChildren extends ASTEntry{ + +- public List children; ++ public List children; + + public ASTEntryWithChildren(ASTEntryWithChildren parent){ + super(parent); +@@ -24,7 +24,7 @@ + if(children == null){ + return null; + } +- return children.toArray(new ASTEntryWithChildren[children.size()]); ++ return (ASTEntryWithChildren[]) children.toArray(new ASTEntryWithChildren[children.size()]); + } + + public ASTEntryWithChildren getParent() { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/DefinitionsASTIteratorVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/DefinitionsASTIteratorVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/DefinitionsASTIteratorVisitor.java 2006-06-10 20:43:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/DefinitionsASTIteratorVisitor.java 2006-11-05 20:59:43.000000000 +0100 +@@ -26,7 +26,6 @@ + */ + public class DefinitionsASTIteratorVisitor extends EasyASTIteratorVisitor{ + +- @Override + public Object visitAssign(Assign node) throws Exception { + return visitAssign(this, node); + } +@@ -82,7 +81,7 @@ + /** + * Creates the iterator and transverses the passed root so that the results can be gotten. + */ +- public static DefinitionsASTIteratorVisitor create(SimpleNode root){ ++ public static EasyASTIteratorVisitor create(SimpleNode root){ + if(root == null){ + return null; + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyAstIteratorBase.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyAstIteratorBase.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyAstIteratorBase.java 2006-10-08 17:32:03.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyAstIteratorBase.java 2006-11-05 21:57:30.000000000 +0100 +@@ -22,10 +22,10 @@ + */ + public abstract class EasyAstIteratorBase extends VisitorBase{ + +- private List nodes = new ArrayList(); ++ private List nodes = new ArrayList(); + +- protected final FastStack stack = new FastStack(); +- protected final FastStack parents = new FastStack(); ++ protected final FastStack stack = new FastStack(); ++ protected final FastStack parents = new FastStack(); + + protected SimpleNode lastVisited; + +@@ -40,8 +40,10 @@ + higherLine = this.lastVisited.beginLine; + } + if(node.specialsAfter != null){ +- for(Object o : node.specialsAfter){ +- if(o instanceof SpecialStr){ ++ for (Iterator iter = node.specialsAfter.iterator(); iter.hasNext();) { ++ Object o = (Object) iter.next(); ++ ++ if(o instanceof SpecialStr){ + SpecialStr str = (SpecialStr) o; + if (str.beginLine > higherLine){ + higherLine = str.beginLine; +@@ -119,7 +121,7 @@ + protected ASTEntry createEntry() { + ASTEntry entry; + if(parents.size() > 0){ +- entry = new ASTEntry(parents.peek()); ++ entry = new ASTEntry((ASTEntry) parents.peek()); + }else{ + entry = new ASTEntry(null); + } +@@ -220,21 +222,21 @@ + /** + * @return and iterator that passes through all the nodes + */ +- public Iterator getIterator() { ++ public Iterator getIterator() { + return nodes.iterator(); + } + + /** + * @return an iterator for all the classes definitions + */ +- public Iterator getClassesIterator() { ++ public Iterator getClassesIterator() { + return getIterator(ClassDef.class); + } + + /** + * @return a list with all the class and method definitions + */ +- public List getClassesAndMethodsList() { ++ public List getClassesAndMethodsList() { + return getAsList(new Class[]{ClassDef.class, FunctionDef.class}); + } + +@@ -242,8 +244,8 @@ + * @param iter this is the iterator we want to get as a list + * @return a list with the elements of the iterator + */ +- protected List getIteratorAsList(Iterator iter) { +- ArrayList list = new ArrayList(); ++ protected List getIteratorAsList(Iterator iter) { ++ ArrayList list = new ArrayList(); + while (iter.hasNext()) { + list.add(iter.next()); + } +@@ -253,19 +255,19 @@ + /** + * @return an iterator for class and method definitions + */ +- public Iterator getClassesAndMethodsIterator() { ++ public Iterator getClassesAndMethodsIterator() { + return getIterator(new Class[]{ClassDef.class, FunctionDef.class}); + } + + /** + * @see EasyASTIteratorVisitor#getIterator(Class[]) + */ +- public Iterator getIterator(Class class_) { ++ public Iterator getIterator(Class class_) { + return getIterator(new Class[]{class_}); + } + +- public List getAsList(Class ... classes) { +- List newList = new ArrayList(); ++ public List getAsList(Class [] classes) { ++ List newList = new ArrayList(); + for (Iterator iter = nodes.iterator(); iter.hasNext();) { + ASTEntry entry = (ASTEntry) iter.next(); + if(isFromClass(entry.node, classes)){ +@@ -275,7 +277,7 @@ + return newList; + } + +- public List getAsList(Class class_) { ++ public List getAsList(Class class_) { + return getAsList(new Class[]{class_}); + } + +@@ -283,29 +285,29 @@ + * @param classes the classes we are searching for + * @return an iterator with nodes found from the passed classes + */ +- public Iterator getIterator(Class ... classes) { ++ public Iterator getIterator(Class [] classes) { + return getAsList(classes).iterator(); + } + + /** + * @return an iterator that will pass through Name and NameTok tokens + */ +- public Iterator getNamesIterator(){ ++ public Iterator getNamesIterator(){ + return new NameIterator(nodes); + } + +- public Iterator getOutline() { ++ public Iterator getOutline() { + return new OutlineIterator(nodes); + } + +- public List getAll(){ ++ public List getAll(){ + return nodes; + } + + /** + * @return an iterator that will pass all the nodes that were added in this visitor + */ +- public Iterator getAllIterator(){ ++ public Iterator getAllIterator(){ + return nodes.iterator(); + } + +@@ -315,7 +317,6 @@ + * @param classes this are the classes we are looking for + * @return true if the node is from one of the passed classes (may be some subclass too) + */ +- @SuppressWarnings("unchecked") + protected boolean isFromClass(SimpleNode node, Class[] classes) { + Class class1 = node.getClass(); + for (int i = 0; i < classes.length; i++) { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyASTIteratorVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyASTIteratorVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyASTIteratorVisitor.java 2006-04-12 03:38:02.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyASTIteratorVisitor.java 2006-11-05 20:59:43.000000000 +0100 +@@ -95,7 +95,7 @@ + return visitor; + } + +- public static Iterator createClassIterator(SimpleNode ast) { ++ public static Iterator createClassIterator(SimpleNode ast) { + EasyASTIteratorVisitor visitor = create(ast); + return visitor.getClassesIterator(); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyASTIteratorWithChildrenVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyASTIteratorWithChildrenVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyASTIteratorWithChildrenVisitor.java 2006-06-10 20:43:19.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/EasyASTIteratorWithChildrenVisitor.java 2006-11-05 20:59:43.000000000 +0100 +@@ -13,7 +13,6 @@ + * + * @see org.python.pydev.parser.visitors.scope.EasyAstIteratorBase#createEntry() + */ +- @Override + protected ASTEntry createEntry() { + ASTEntry entry; + if(parents.size() > 0){ +@@ -30,14 +29,13 @@ + * + * @see org.python.pydev.parser.visitors.scope.EasyAstIteratorBase#doAddNode(org.python.pydev.parser.visitors.scope.ASTEntry) + */ +- @Override + protected void doAddNode(ASTEntry entry) { + if(entry.parent == null){ + super.doAddNode(entry); + }else{ + ASTEntryWithChildren parent = (ASTEntryWithChildren)entry.parent; + if(parent.children == null){ +- parent.children = new ArrayList(); ++ parent.children = new ArrayList(); + } + parent.children.add((ASTEntryWithChildren) entry); + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/NameIterator.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/NameIterator.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/NameIterator.java 2006-06-09 03:19:06.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/NameIterator.java 2006-11-05 20:59:43.000000000 +0100 +@@ -12,19 +12,19 @@ + /** + * Iterator the passes the nodes getting the subclasses of Name and NameTok + */ +-public class NameIterator implements Iterator { ++public class NameIterator implements Iterator { + + private ASTEntry next = null; +- private Iterator nodesIt; ++ private Iterator nodesIt; + +- public NameIterator(List nodes) { ++ public NameIterator(List nodes) { + this.nodesIt = nodes.iterator(); + setNext(); + } + + private void setNext() { + while(nodesIt.hasNext()){ +- ASTEntry entry = nodesIt.next(); ++ ASTEntry entry = (ASTEntry) nodesIt.next(); + if(entry.node instanceof Name || entry.node instanceof NameTok){ + next = entry; + return; +@@ -37,7 +37,7 @@ + return next != null; + } + +- public ASTEntry next() { ++ public Object next() { + ASTEntry n = next; + setNext(); + return n; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/OutlineCreatorVisitor.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/OutlineCreatorVisitor.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/OutlineCreatorVisitor.java 2006-06-11 22:04:00.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/OutlineCreatorVisitor.java 2006-11-05 20:59:43.000000000 +0100 +@@ -4,6 +4,7 @@ + */ + package org.python.pydev.parser.visitors.scope; + ++import java.util.Iterator; + import java.util.List; + + import org.python.pydev.parser.jython.SimpleNode; +@@ -33,14 +34,12 @@ + + + +- @Override + public void traverse(SimpleNode node) throws Exception { + checkSpecials(node.specialsBefore); + super.traverse(node); + checkSpecials(node.specialsAfter); + } + +- @Override + public void traverse(FunctionDef node) throws Exception { + checkSpecials(node.specialsBefore); + super.traverse(node); +@@ -63,7 +62,6 @@ + return super.visitImportFrom(node); + } + +- @Override + public Object visitAssign(Assign node) throws Exception { + isInAssign = true; + try{ +@@ -77,7 +75,6 @@ + + } + +- @Override + protected void doAddNode(ASTEntry entry) { + SimpleNode node = entry.node; + +@@ -91,11 +88,13 @@ + super.doAddNode(entry); + } + +- private void checkSpecials(List specials) { ++ private void checkSpecials(List specials) { + if(specials == null || isInAssign){ + return; + } +- for (Object object : specials) { ++ for (Iterator iter = specials.iterator(); iter.hasNext();) { ++ Object object = (Object) iter.next(); ++ + if(object instanceof commentType){ + commentType type = (commentType) object; + if(type.id.trim().startsWith("#---")){ +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/OutlineIterator.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/OutlineIterator.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/OutlineIterator.java 2006-06-09 03:19:06.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/src/org/python/pydev/parser/visitors/scope/OutlineIterator.java 2006-11-05 20:59:43.000000000 +0100 +@@ -12,20 +12,20 @@ + import org.python.pydev.parser.jython.ast.FunctionDef; + import org.python.pydev.parser.jython.ast.Name; + +-public class OutlineIterator implements Iterator { ++public class OutlineIterator implements Iterator { + + + private ASTEntry next = null; +- private Iterator nodesIt; ++ private Iterator nodesIt; + +- public OutlineIterator(List nodes) { ++ public OutlineIterator(List nodes) { + this.nodesIt = nodes.iterator(); + setNext(); + } + + private void setNext() { + while(nodesIt.hasNext()){ +- ASTEntry entry = nodesIt.next(); ++ ASTEntry entry = (ASTEntry) nodesIt.next(); + + if(entry.node instanceof ClassDef || entry.node instanceof FunctionDef || + entry.node instanceof Attribute || entry.node instanceof Name ){ +@@ -41,7 +41,7 @@ + return next != null; + } + +- public ASTEntry next() { ++ public Object next() { + ASTEntry n = next; + setNext(); + return n; +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/profile/ParseBigFile.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/profile/ParseBigFile.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/profile/ParseBigFile.java 2006-04-28 15:43:41.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/profile/ParseBigFile.java 2006-11-05 20:59:43.000000000 +0100 +@@ -56,15 +56,15 @@ + String loc = TestDependent.TEST_PYDEV_PARSER_PLUGIN_LOC+"/tests/pysrc/data_string.py"; + String s = REF.getFileContents(new File(loc)); + for (int i = 0; i < 5; i++) { +- @SuppressWarnings("unused") long curr = System.currentTimeMillis(); +- SimpleNode node = parseLegalDocStr(s); ++ long curr = System.currentTimeMillis(); ++ SimpleNode node = parseLegalDocStr(s, new Object[] {}); + + PyParser.USE_FAST_STREAM = true; + //uncomment line below to see the time for parsing + //System.out.println(StringUtils.format("Took: %s secs", (System.currentTimeMillis()-curr)/1000.0)); + SequencialASTIteratorVisitor visitor = SequencialASTIteratorVisitor.create(node); + +- ASTEntry entry = visitor.getAsList(Str.class).get(0); ++ ASTEntry entry = (ASTEntry) visitor.getAsList(Str.class).get(0); + String s0 = ((Str)entry.node).s; + assertEquals(42, entry.node.beginLine); + assertEquals(8, entry.node.beginColumn); +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserPrintTest.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserPrintTest.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserPrintTest.java 2006-04-28 15:43:41.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserPrintTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -31,7 +31,7 @@ + " def met1(self, a):#comment2\n" + + " pass \n" + + "#comment3"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserTestBase.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserTestBase.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserTestBase.java 2006-09-17 15:25:57.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserTestBase.java 2006-11-05 20:59:43.000000000 +0100 +@@ -56,7 +56,7 @@ + * @param s + * @return + */ +- protected static SimpleNode parseLegalDocStr(String s, Object ... additionalErrInfo) { ++ protected static SimpleNode parseLegalDocStr(String s, Object [] additionalErrInfo) { + Document doc = new Document(s); + //by default always use the last version for parsing + return parseLegalDoc(doc, additionalErrInfo, parser); +@@ -67,7 +67,7 @@ + } + protected ParseException parseILegalDoc(IDocument doc) { + parser.setDocument(doc, false); +- Tuple objects = parser.reparseDocument(); ++ Tuple objects = parser.reparseDocument(new Object[] {}); + Object err = objects.o2; + if(err == null){ + fail("Expected a ParseException and the doc was successfully parsed."); +@@ -84,7 +84,7 @@ + */ + protected static SimpleNode parseLegalDoc(IDocument doc, Object[] additionalErrInfo, PyParser parser) { + parser.setDocument(doc, false); +- Tuple objects = parser.reparseDocument(); ++ Tuple objects = parser.reparseDocument(new Object[] {}); + Object err = objects.o2; + if(err != null){ + String s = ""; +@@ -104,7 +104,7 @@ + fail("Expected no error, received: "+err+" "+s); + } + assertNotNull(objects.o1); +- return objects.o1; ++ return (SimpleNode) objects.o1; + } + + public void testEmpty() { +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserTest.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserTest.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserTest.java 2006-09-26 14:09:55.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/PyParserTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -34,7 +34,6 @@ + } + } + +- @Override + protected void setUp() throws Exception { + super.setUp(); + PyParser.USE_FAST_STREAM = true; +@@ -45,7 +44,7 @@ + "class Class1: \n" + + " def met1(self, a):\n" + + " pass"; +- SimpleNode node = parseLegalDocStr(s); ++ SimpleNode node = parseLegalDocStr(s, new Object[] {}); + Module m = (Module) node; + ClassDef d = (ClassDef) m.body[0]; + FunctionDef f = (FunctionDef) d.body[0]; +@@ -79,7 +78,7 @@ + "really really big string\n" + + "really really big string\n" + + "'''"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testErr() { +@@ -122,7 +121,7 @@ + String s = "" + + "def m():\n" + + " yield 1"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testYield2() { +@@ -145,7 +144,7 @@ + " def m():\n" + + " pass\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testDecorator2() { +@@ -156,7 +155,7 @@ + " pass\n" + + "\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testDecorator4() { +@@ -166,7 +165,7 @@ + " pass\n" + + "\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testDecorator5() { +@@ -176,7 +175,7 @@ + " funcattrs(1)\n" + + "\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testDecorator3() { +@@ -188,7 +187,7 @@ + " pass\n" + + "\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testDecorator6() { +@@ -198,7 +197,7 @@ + " pass\n" + + "\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testOnNumarray() { +@@ -235,7 +234,7 @@ + for (int i = 0; i < files.length; i++) { + File f = files[i]; + if(f.getAbsolutePath().toLowerCase().endsWith(".py")){ +- parseLegalDocStr(REF.getFileContents(f), f); ++ parseLegalDocStr(REF.getFileContents(f), new Object[] {f}); + } + } + } +@@ -329,7 +328,7 @@ + "\n" + + "\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testNewImportParser2() { +@@ -340,7 +339,7 @@ + "\n" + + "\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testNewImportParser3() { +@@ -356,7 +355,7 @@ + + public void testParser() { + String s = "class C: pass"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testEndWithComment() { +@@ -364,7 +363,7 @@ + " pass\n" + + "#end\n" + + ""; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testParser7() { +@@ -373,7 +372,7 @@ + " False, True = 0, 1\n"+ + "\n"+ + "\n"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testParser8() { +@@ -383,7 +382,7 @@ + "\n"+ + "\n"+ + "\n"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testParser2() { +@@ -428,7 +427,7 @@ + " if match: return match\n"+ + "\n"+ + "\n"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + +@@ -440,7 +439,7 @@ + "\n"+ + "\n"+ + "\n"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + /** +@@ -452,10 +451,10 @@ + String s = "" + + "l = [ \"encode\", \"decode\" ] \n"+ + "\n"; +- SimpleNode node = parseLegalDocStr(s); +- List strs = SequencialASTIteratorVisitor.create(node).getAsList(new Class[]{Str.class}); +- assertEquals(7, strs.get(0).node.beginColumn); +- assertEquals(17, strs.get(1).node.beginColumn); ++ SimpleNode node = parseLegalDocStr(s, new Object[] {}); ++ List strs = SequencialASTIteratorVisitor.create(node).getAsList(new Class[]{Str.class}); ++ assertEquals(7, ((ASTEntry)strs.get(0)).node.beginColumn); ++ assertEquals(17, ((ASTEntry)strs.get(1)).node.beginColumn); + } + + +@@ -469,13 +468,13 @@ + " pass\n"+ + "\n"+ + "\n"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object[] {}); + } + + public void testParser12() { + String s = "" + + "m1()\n"+ + "\n"; +- parseLegalDocStr(s); ++ parseLegalDocStr(s, new Object [] {}); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/visitors/NodeUtilsTest.java eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/visitors/NodeUtilsTest.java +--- eclipse-pydev-1.2.5/org.python.pydev.parser/tests/org/python/pydev/parser/visitors/NodeUtilsTest.java 2005-10-26 16:56:32.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.parser/tests/org/python/pydev/parser/visitors/NodeUtilsTest.java 2006-11-05 20:59:43.000000000 +0100 +@@ -14,29 +14,29 @@ + + public void testFullRep() throws Exception { + SequencialASTIteratorVisitor visitor = SequencialASTIteratorVisitor.create(parseLegalDocStr( +- "print a.b.c().d.__class__")); ++ "print a.b.c().d.__class__", new Object[] {})); + +- Iterator iterator = visitor.getIterator(); ++ Iterator iterator = visitor.getIterator(); + iterator.next(); //Module + iterator.next(); //Print +- ASTEntry entry = iterator.next(); //Attribute ++ ASTEntry entry = (ASTEntry) iterator.next(); //Attribute + assertEquals("a.b.c", NodeUtils.getFullRepresentationString(entry.node)); + + + visitor = SequencialASTIteratorVisitor.create(parseLegalDocStr( +- "'r.a.s.b'.join('a')")); ++ "'r.a.s.b'.join('a')", new Object[] {})); + iterator = visitor.getIterator(); + iterator.next(); //Module + iterator.next(); //Expr +- entry = iterator.next(); //Attribute ++ entry = (ASTEntry) iterator.next(); //Attribute + assertEquals("str.join", NodeUtils.getFullRepresentationString(entry.node)); + + visitor = SequencialASTIteratorVisitor.create(parseLegalDocStr( +- "print aa.bbb.cccc[comp.id].hasSimulate")); ++ "print aa.bbb.cccc[comp.id].hasSimulate", new Object[] {})); + iterator = visitor.getIterator(); + iterator.next(); //Module + iterator.next(); //Expr +- entry = iterator.next(); //Attribute ++ entry = (ASTEntry) iterator.next(); //Attribute + assertEquals("aa.bbb.cccc", NodeUtils.getFullRepresentationString(entry.node)); + } + } +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.templates/build.properties eclipse-pydev-1.2.5-patched/org.python.pydev.templates/build.properties +--- eclipse-pydev-1.2.5/org.python.pydev.templates/build.properties 2005-09-03 20:00:51.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.templates/build.properties 2006-11-05 20:59:43.000000000 +0100 +@@ -1,5 +1,4 @@ + bin.includes = META-INF/,\ + plugin.xml,\ +- icons/,\ +- retroweaver-rt.jar ++ icons/ + jars.compile.order = +diff -ruN eclipse-pydev-1.2.5/org.python.pydev.templates/META-INF/MANIFEST.MF eclipse-pydev-1.2.5-patched/org.python.pydev.templates/META-INF/MANIFEST.MF +--- eclipse-pydev-1.2.5/org.python.pydev.templates/META-INF/MANIFEST.MF 2005-09-03 17:59:59.000000000 +0200 ++++ eclipse-pydev-1.2.5-patched/org.python.pydev.templates/META-INF/MANIFEST.MF 2006-11-05 20:59:43.000000000 +0100 +@@ -10,4 +10,3 @@ + org.eclipse.core.runtime, + org.python.pydev + Eclipse-AutoStart: true +-Bundle-ClassPath: retroweaver-rt.jar +diff -ruN eclipse-pydev-1.2.5/TestDependent/dev/null eclipse-pydev-1.2.5-patched/TestDependent/dev/null +--- eclipse-pydev-1.2.5/TestDependent/dev/null 1970-01-01 01:00:00.000000000 +0100 ++++ eclipse-pydev-1.2.5-patched/TestDependent/dev/null 2006-11-05 20:59:43.000000000 +0100 +@@ -0,0 +1,42 @@ ++/* ++ * Create a file TestDependent.java with the contents in this file and substitute the ++ * values as needed... ++ */ ++package org.python.pydev.core; ++ ++public class TestDependent { ++ ++ //NOTE: this should be gotten from some variable to point to the python lib (less system dependence, but still, some). ++ public static String PYTHON_EXE="D:/bin/Python24/python.exe"; ++ public static final String PYTHON_INSTALL="D:/bin/Python24/"; ++ public static final String PYTHON_LIB="D:/bin/Python24/Lib/"; ++ public static final String PYTHON_SITE_PACKAGES="D:/bin/Python24/Lib/site-packages/"; ++ public static final String PYTHON_WXPYTHON_PACKAGES="D:/bin/Python24/Lib/site-packages/wx-2.6-msw-ansi/"; ++ public static final String PYTHON_NUMARRAY_PACKAGES="D:/bin/Python24/Lib/site-packages/numarray/"; ++ ++ public static String CYGWIN_PYTHON_EXE="E:/install/Utils.Cygwin/bin/python2.4.exe"; ++ public static boolean HAS_CYGWIN = true; ++ ++ //NOTE: this should set to the tests pysrc location, so that it can be added to the pythonpath. ++ public static final String TEST_PYDEV_BASE_LOC = "E:/eclipse_workspace/"; ++ public static final String TEST_PYSRC_LOC=TEST_PYDEV_BASE_LOC+"org.python.pydev/tests/pysrc/"; ++ public static final String TEST_PYSRC_LOC2=TEST_PYDEV_BASE_LOC+"org.python.pydev/tests/pysrc2/"; ++ public static final String TEST_PYDEV_PLUGIN_LOC = TEST_PYDEV_BASE_LOC+"org.python.pydev/"; ++ public static final String TEST_PYDEV_JYTHON_PLUGIN_LOC = TEST_PYDEV_BASE_LOC+"org.python.pydev.jython/"; ++ public static final String TEST_PYDEV_PARSER_PLUGIN_LOC = TEST_PYDEV_BASE_LOC+"org.python.pydev.parser/"; ++ ++ //java info ++ public static final String JAVA_LOCATION="C:/Program Files/Java/jre1.5.0_04/bin/java.exe"; ++ public static final String JAVA_RT_JAR_LOCATION= "C:/Program Files/Java/jre1.5.0_04/lib/rt.jar"; ++ ++ public static final String JYTHON_JAR_LOCATION="D:/bin/jython21/jython.jar"; ++ public static final String JYTHON_LIB_LOCATION="D:/bin/jython21/lib/"; ++ ++ //we cannot test what we don't have... ++ public static final boolean HAS_WXPYTHON_INSTALLED = true; ++ public static final boolean HAS_QT_INSTALLED = true; ++ public static final boolean HAS_GLU_INSTALLED = true; ++ public static final boolean HAS_SWT_ON_PATH = false; ++ public static final boolean HAS_NUMARRAY_INSTALLED = true; ++ public static final boolean HAS_MX_DATETIME = false; ++}