Community
Participate
Working Groups
Build Identifier: M20110210-1200 "An unexpected exception occurred during condition checking. See the error log for more details." Session Data is eclipse.buildId=M20110210-1200 java.version=1.6.0_20 java.vendor=Sun Microsystems Inc. BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=fr_FR Framework arguments: -product org.eclipse.epp.package.cpp.product Command-line arguments: -data /home/devel/Documents/Michel/Recherche/Fortran/Optical_Scattering/workspace_eclipse_Linux_x86-64 -os linux -ws gtk -arch x86_64 -product org.eclipse.epp.package.cpp.product Exception Stack trace is: java.lang.reflect.InvocationTargetException at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:421) at org.eclipse.jface.dialogs.ProgressMonitorDialog.run(ProgressMonitorDialog.java:507) at org.eclipse.ui.internal.progress.ProgressMonitorJobsDialog.run(ProgressMonitorJobsDialog.java:275) at org.eclipse.ui.internal.progress.ProgressManager$5.run(ProgressManager.java:960) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70) at org.eclipse.ui.internal.progress.ProgressManager.busyCursorWhile(ProgressManager.java:995) at org.eclipse.ui.internal.progress.ProgressManager.busyCursorWhile(ProgressManager.java:970) at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation.checkInitialConditions(RefactoringWizardOpenOperation.java:205) at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation.access$0(RefactoringWizardOpenOperation.java:200) at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation$1.run(RefactoringWizardOpenOperation.java:163) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70) at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation.run(RefactoringWizardOpenOperation.java:192) at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation.run(RefactoringWizardOpenOperation.java:115) at org.eclipse.photran.internal.ui.refactoring.AbstractFortranRefactoringActionDelegate.run(AbstractFortranRefactoringActionDelegate.java:154) at org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.java:464) at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:372) at org.eclipse.jface.dialogs.ProgressMonitorDialog.run(ProgressMonitorDialog.java:507) at org.eclipse.ui.internal.progress.ProgressMonitorJobsDialog.run(ProgressMonitorJobsDialog.java:275) at org.eclipse.ui.internal.progress.ProgressManager.run(ProgressManager.java:1162) at org.eclipse.ui.internal.progress.ProgressManager$RunnableWithStatus.run(ProgressManager.java:1346) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70) at org.eclipse.ui.internal.progress.ProgressManager$7.run(ProgressManager.java:1184) at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:179) at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:150) at org.eclipse.swt.widgets.Display.syncExec(Display.java:4282) at org.eclipse.ui.internal.progress.ProgressManager.runInUI(ProgressManager.java:1182) at org.eclipse.photran.internal.ui.actions.FortranEditorActionDelegate.run(FortranEditorActionDelegate.java:78) at org.eclipse.photran.internal.ui.refactoring.AbstractFortranRefactoringActionDelegate.run(AbstractFortranRefactoringActionDelegate.java:70) at org.eclipse.ui.internal.handlers.ActionDelegateHandlerProxy.execute(ActionDelegateHandlerProxy.java:289) at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476) at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:508) at org.eclipse.ui.internal.handlers.HandlerService.executeCommand(HandlerService.java:169) at org.eclipse.ui.internal.handlers.SlaveHandlerService.executeCommand(SlaveHandlerService.java:241) at org.eclipse.ui.menus.CommandContributionItem.handleWidgetSelection(CommandContributionItem.java:820) at org.eclipse.ui.menus.CommandContributionItem.access$19(CommandContributionItem.java:806) at org.eclipse.ui.menus.CommandContributionItem$5.handleEvent(CommandContributionItem.java:796) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1258) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3540) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3161) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2640) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2604) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2438) at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:671) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:664) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:115) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:369) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:616) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:620) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:575) at org.eclipse.equinox.launcher.Main.run(Main.java:1408) at org.eclipse.equinox.launcher.Main.main(Main.java:1384) Caused by: java.lang.NullPointerException at org.eclipse.photran.internal.core.refactoring.ExtractProcedureRefactoring.findTypeDeclaration(ExtractProcedureRefactoring.java:253) at org.eclipse.photran.internal.core.refactoring.ExtractProcedureRefactoring.findArraySpecInTypeDecl(ExtractProcedureRefactoring.java:235) at org.eclipse.photran.internal.core.refactoring.ExtractProcedureRefactoring.findArraySpec(ExtractProcedureRefactoring.java:225) at org.eclipse.photran.internal.core.refactoring.ExtractProcedureRefactoring.addlLocalVariablesReferencedIn(ExtractProcedureRefactoring.java:215) at org.eclipse.photran.internal.core.refactoring.ExtractProcedureRefactoring.localVarsReferencedInDecls(ExtractProcedureRefactoring.java:160) at org.eclipse.photran.internal.core.refactoring.ExtractProcedureRefactoring.determineParameters(ExtractProcedureRefactoring.java:153) at org.eclipse.photran.internal.core.refactoring.ExtractProcedureRefactoring.doCheckInitialConditions(ExtractProcedureRefactoring.java:127) at org.eclipse.rephraserengine.core.vpg.refactoring.VPGRefactoring.checkInitialConditions(VPGRefactoring.java:72) at org.eclipse.ltk.core.refactoring.CheckConditionsOperation.run(CheckConditionsOperation.java:83) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1975) at org.eclipse.ltk.internal.ui.refactoring.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:87) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121) Reproducible: Sometimes Steps to Reproduce: 1. I selected some lines in the main program 2. Right Click and select Refactoring/Extract Procedure 3. The error occurs or not depending on the lines I select.
Created attachment 231179 [details] proposed patch to avoid the NullPointerException patch to at least avoid the NullPointerException. there may be other issues that need to be fixed as well, but this should at least clean up the error that the user sees I confirm that: (a) I wrote 100% of the code without incorporating content from elsewhere or relying on the intellectual property of others (b) I have the right to contribute the code to Eclipse (c) I have included the EPL license header in all source files.