Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Potential bug in TranslationUnit

While trying to solve the issue I posted in a previous post
(http://eclipse.1072660.n5.nabble.com/Clone-CDT-project-td187628.html), I
came across the following code in TranslationUnit class

	@Override
	public IUsing createUsing(String usingName, boolean isDirective, ICElement
sibling,
			IProgressMonitor monitor) throws CModelException {
*		CreateIncludeOperation op = new CreateIncludeOperation(usingName,
isDirective, this);
*		if (sibling != null) {
			op.createBefore(sibling);
		}
		op.runOperation(monitor);
		return getUsing(usingName);
	}

I suppose 		

   CreateIncludeOperation op = new CreateIncludeOperation(usingName,
isDirective, this);

should be

   CreateUsingOperation op = new CreateUsingOperation(usingName,
isDirective, this);


Should we file this as a bug to be fixed in a future CDT version? 





--
View this message in context: http://eclipse.1072660.n5.nabble.com/Potential-bug-in-TranslationUnit-tp187632.html
Sent from the Eclipse CDT - Development mailing list archive at Nabble.com.


Back to the top