[Dune] [#621] Make check fails for dune-common (r5622)

Dune dune at dune-project.org
Mon Oct 5 15:08:49 CEST 2009


THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.

A new Flyspray task has been opened.  Details are below. 

User who did this - Atgeirr Flø Rasmussen (atgeirr) 

Attached to Project - Dune
Summary - Make check fails for dune-common (r5622)
Task Type - Bug Report
Category - Common
Status - Unconfirmed
Assigned To - 
Operating System - Unspecified / All
Severity - Low
Priority - Normal
Reported Version - SVN
Due in Version - Undecided
Due Date - Undecided
Details - 2 failures:

FAIL: test-stack

This program demands that FiniteStack throws an exception when calling pop() on an empty stack(), whereas FiniteStack does no such thing. Suggested changes:
1) Remove this requirement from test-stack.cc.
2) Add checks to FiniteStack, that are only active in debug mode, make test-stack also only verify this in debug mode.


FAIL: lrutest

Program fails with the following error:

testing Dune::lru<int,double>
/opt/local/include/gcc43/c++/debug/safe_iterator.h:131:error: attempt to 
    copy-construct an iterator from a singular iterator.

This is an error triggered by the -D_GLIBCXX_DEBUG libstdc++ debug define.
The error is triggered because operator[] copy constructs a default constructed
mapped_type (in our case: a list iterator) which fails. I am not sure if this is
a bug in libstdc++ or not, but changing the code to use insert() instead of
operator[] at least avoids the issue:

--- lru.hh	(revision 5622)
+++ lru.hh	(working copy)
@@ -156,7 +156,7 @@
         /* insert item as mru */
         iterator it = _data.insert(_data.begin(), x);
         /* store index */
-        _index[key] = it;
+        _index.insert(std::make_pair(key,it));
 
         return it->second;
     }


More information can be found at the following URL:
http://www.dune-project.org/flyspray/index.php?do=details&task_id=621

You are receiving this message because you have requested it from the Flyspray bugtracking system.  If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.




More information about the Dune mailing list