info.fCopy.commitWorkingCopy(overwrite, subMonitor3);
info.fCopy.commitWorkingCopy(isSynchronized || overwrite, subMonitor3);
	protected void commitWorkingCopy(IProgressMonitor monitor, Object element, final CompilationUnitInfo info, boolean overwrite) throws CoreException {		if (monitor == null)			monitor= new NullProgressMonitor();		monitor.beginTask("", 100); //$NON-NLS-1$		try {			final IProgressMonitor subMonitor1= getSubProgressMonitor(monitor, 50);			try {				SafeRunner.run(new ISafeRunnable() {					public void run() {						try {							info.fCopy.reconcile(ICompilationUnit.NO_AST, false, null, subMonitor1);						} catch (JavaModelException ex) {							handleException(ex);						} catch (OperationCanceledException ex) {							// do not log this						}					}					public void handleException(Throwable ex) {						IStatus status= new Status(IStatus.ERROR, JavaUI.ID_PLUGIN, IStatus.OK, "Error in JDT Core during reconcile while saving", ex);  //$NON-NLS-1$						JavaPlugin.getDefault().getLog().log(status);					}				});			} finally {				subMonitor1.done();			}			IDocument document= info.fTextFileBuffer.getDocument();			IResource resource= info.fCopy.getResource();			Assert.isTrue(resource instanceof IFile);			/* https://bugs.eclipse.org/bugs/show_bug.cgi?id=98327			 * Make sure file gets save in commit() if the underlying file has been deleted */			if (!resource.isSynchronized(IResource.DEPTH_ZERO) && isDeleted(element))				info.fTextFileBuffer.setDirty(true);			if (!resource.exists()) {				// underlying resource has been deleted, just recreate file, ignore the rest				IProgressMonitor subMonitor2= getSubProgressMonitor(monitor, 50);				try {					createFileFromDocument(subMonitor2, (IFile) resource, document);				} finally {					subMonitor2.done();				}				return;			}			if (fSavePolicy != null)				fSavePolicy.preSave(info.fCopy);			IProgressMonitor subMonitor3= getSubProgressMonitor(monitor, 50);			try {				fIsAboutToSave= true;				info.fCopy.commitWorkingCopy(overwrite, subMonitor3);			} catch (CoreException x) {				// inform about the failure				fireElementStateChangeFailed(element);				throw x;			} catch (RuntimeException x) {				// inform about the failure				fireElementStateChangeFailed(element);				throw x;			} finally {				fIsAboutToSave= false;				subMonitor3.done();			}			// If here, the dirty state of the editor will change to "not dirty".			// Thus, the state changing flag will be reset.			if (info.fModel instanceof AbstractMarkerAnnotationModel) {				AbstractMarkerAnnotationModel model= (AbstractMarkerAnnotationModel) info.fModel;				model.updateMarkers(document);			}			if (fSavePolicy != null) {				ICompilationUnit unit= fSavePolicy.postSave(info.fCopy);				if (unit != null && info.fModel instanceof AbstractMarkerAnnotationModel) {					IResource r= unit.getResource();					IMarker[] markers= r.findMarkers(IMarker.MARKER, true, IResource.DEPTH_ZERO);					if (markers != null && markers.length > 0) {						AbstractMarkerAnnotationModel model= (AbstractMarkerAnnotationModel) info.fModel;						for (int i= 0; i < markers.length; i++)							model.updateMarker(document, markers[i], null);					}				}			}		} finally {			monitor.done();		}	}