mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 22:52:11 +02:00
Bug 331882 - Unnecessary calls to getProjectDescription(IProject, true) are very expensive
This commit is contained in:
parent
ec126ace3f
commit
7cf13bb21c
2 changed files with 6 additions and 4 deletions
|
@ -1,5 +1,5 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2000, 2010 QNX Software Systems and others.
|
||||
* Copyright (c) 2000, 2011 QNX Software Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
|
@ -11,6 +11,7 @@
|
|||
* IBM Corporation
|
||||
* Anton Leherbauer (Wind River Systems)
|
||||
* Warren Paul (Nokia) - Bug 218266
|
||||
* James Blackburn (Broadcom Corp.)
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.internal.core.model;
|
||||
|
||||
|
@ -704,7 +705,7 @@ public class TranslationUnit extends Openable implements ITranslationUnit {
|
|||
ICProject cProject = getCProject();
|
||||
IProject project= cProject.getProject();
|
||||
|
||||
ICProjectDescription description = CoreModel.getDefault().getProjectDescription(project, true);
|
||||
ICProjectDescription description = CoreModel.getDefault().getProjectDescription(project, false);
|
||||
ICConfigurationDescription configuration;
|
||||
|
||||
if (description == null) {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2000, 2010 QNX Software Systems and others.
|
||||
* Copyright (c) 2000, 2011 QNX Software Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
|
@ -8,6 +8,7 @@
|
|||
* Contributors:
|
||||
* QNX Software Systems - Initial API and implementation
|
||||
* IBM Corporation
|
||||
* James Blackburn (Broadcom Corp.)
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.core.resources;
|
||||
|
||||
|
@ -166,7 +167,7 @@ public abstract class ACBuilder extends IncrementalProjectBuilder implements IMa
|
|||
@SuppressWarnings("nls")
|
||||
private String cfgIdToNames(String strIds) {
|
||||
IProject project = getProject();
|
||||
ICProjectDescription prjDesc = CoreModel.getDefault().getProjectDescription(project);
|
||||
ICProjectDescription prjDesc = CoreModel.getDefault().getProjectDescription(project, false);
|
||||
if (prjDesc==null)
|
||||
return strIds;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue