Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Does Codan CaseBreakChecker work on HEAD?

I broke it and then I fixed it 2 days ago.

On Tue, Mar 15, 2011 at 8:46 AM, xgsa <xgsa@xxxxxxxxx> wrote:
> Hi,
>
> Recently I wanted to fix a bug #339802 on Codan checker, that checks breaks
> in switch statements. But it seems that it does not work at all on HEAD when
> it is running from Eclipse, cause there is no warnings from it and this
> stack trace is printed on console:
>
> !ENTRY org.eclipse.cdt.codan.core 4 1 2011-03-15 14:26:33.175
> !MESSAGE Internal Error
> !STACK 0
> java.lang.IllegalArgumentException: Not cached
>     at
> org.eclipse.cdt.codan.core.cxx.model.CxxModelsCache.getCommentedNodeMap(CxxModelsCache.java:99)
>     at
> org.eclipse.cdt.codan.core.cxx.CxxAstUtils.getFreestandingComment(CxxAstUtils.java:436)
>     at
> org.eclipse.cdt.codan.internal.checkers.CaseBreakChecker$SwitchVisitor.getFreestandingComment(CaseBreakChecker.java:227)
>     at
> org.eclipse.cdt.codan.internal.checkers.CaseBreakChecker$SwitchVisitor.leave(CaseBreakChecker.java:237)
>     at
> org.eclipse.cdt.internal.core.dom.parser.cpp.CPPASTCompoundStatement.accept(CPPASTCompoundStatement.java:82)
>     at
> org.eclipse.cdt.internal.core.dom.parser.cpp.CPPASTSwitchStatement.accept(CPPASTSwitchStatement.java:105)
>     at
> org.eclipse.cdt.codan.internal.checkers.CaseBreakChecker$SwitchFindingVisitor.visit(CaseBreakChecker.java:94)
>     at
> org.eclipse.cdt.internal.core.dom.parser.cpp.CPPASTSwitchStatement.accept(CPPASTSwitchStatement.java:97)
>     at
> org.eclipse.cdt.internal.core.dom.parser.cpp.CPPASTCompoundStatement.accept(CPPASTCompoundStatement.java:79)
>     at
> org.eclipse.cdt.internal.core.dom.parser.cpp.CPPASTFunctionDefinition.accept(CPPASTFunctionDefinition.java:187)
>     at
> org.eclipse.cdt.internal.core.dom.parser.cpp.CPPASTDeclarationStatement.accept(CPPASTDeclarationStatement.java:72)
>     at
> org.eclipse.cdt.internal.core.dom.parser.cpp.CPPASTCompoundStatement.accept(CPPASTCompoundStatement.java:79)
>     at
> org.eclipse.cdt.internal.core.dom.parser.cpp.CPPASTFunctionDefinition.accept(CPPASTFunctionDefinition.java:187)
>     at
> org.eclipse.cdt.internal.core.dom.parser.ASTTranslationUnit.accept(ASTTranslationUnit.java:271)
>     at
> org.eclipse.cdt.codan.internal.checkers.CaseBreakChecker.processAst(CaseBreakChecker.java:268)
>     at
> org.eclipse.cdt.codan.core.cxx.model.AbstractIndexAstChecker.processModel(AbstractIndexAstChecker.java:124)
>     at
> org.eclipse.cdt.codan.internal.core.CodanBuilder.processResource(CodanBuilder.java:141)
>     at
> org.eclipse.cdt.codan.internal.core.CodanBuilder.runInEditor(CodanBuilder.java:206)
>     at
> org.eclipse.cdt.codan.core.cxx.internal.model.CxxCodanReconciler.reconciledAst(CxxCodanReconciler.java:38)
>     at
> org.eclipse.cdt.codan.internal.ui.cxx.CodanCReconciler.reconciled(CodanCReconciler.java:92)
>     at
> org.eclipse.cdt.internal.ui.editor.CEditor.reconciled(CEditor.java:3065)
>     at
> org.eclipse.cdt.internal.ui.text.CReconcilingStrategy.reconcile(CReconcilingStrategy.java:105)
>     at
> org.eclipse.cdt.internal.ui.text.CReconcilingStrategy.reconcile(CReconcilingStrategy.java:71)
>     at
> org.eclipse.cdt.internal.ui.text.CompositeReconcilingStrategy.reconcile(CompositeReconcilingStrategy.java:84)
>     at
> org.eclipse.cdt.internal.ui.text.CCompositeReconcilingStrategy.reconcile(CCompositeReconcilingStrategy.java:90)
>     at
> org.eclipse.jface.text.reconciler.MonoReconciler.process(MonoReconciler.java:77)
>     at
> org.eclipse.cdt.internal.ui.text.CReconciler.process(CReconciler.java:408)
>     at
> org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:206)
>
> However all tests on Codan checker passed successfully. Did I miss
> something?
>
>
> _______________________________________________
> cdt-dev mailing list
> cdt-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/cdt-dev
>
>


Back to the top