Skip to content
Snippets Groups Projects
  1. Feb 06, 2015
    • Steffen Müthing's avatar
      [Utility] Add infrastructure to handle operator->() for both lvalues and proxies · 7623a530
      Steffen Müthing authored
      If an iterator facade (like entity iterators) wants to allow the
      embedded implementation to return either an (internally stored)
      reference or a temporary object and expose these two behaviors to enable
      performance optimizations, operator->() needs special handling: If the
      implementation returns a reference, operator->() in the facade can
      simply return the address of the referenced object, but if the returned
      object is a temporary, we need to capture and store it in a helper
      object to make sure it outlives the member access.
      
      This patch adds a little helper function that tansparently handles both
      cases.
      7623a530
  2. Dec 18, 2014
    • Jö Fahlke's avatar
      [threads] Introduce DUNE_ASSERT_CALL_ONCE and assertCallOnce(). · 92947aaf
      Jö Fahlke authored
      These check whether std::call_once() works and provide a helpful error message
      if it does not.  They should be used in any code that uses std::call_once().
      
      Call once may not work if one forgets to _link_ with -pthread (or similar
      options).  The nasty think about this is that linking still succeeds, so this
      can only be detected at run time.  We cannot (in general) run compiled
      programs during configure, since we may be cross-compiling, so whatever we get
      from configure is at best a guess.
      
      Even if configure detects the necessary flags correctly, there may still be
      errors in the build system such that the executable is linked without them.
      
      The reason to provide such a facility is that the bug is quite difficult to
      debug when it appears.  The error message is mangled due to a different bug,
      and is quite unhelpful anyway.  And then there is the fun with weak symbols...
      92947aaf
  3. Oct 06, 2014
  4. Jul 18, 2014
  5. Mar 21, 2014
    • Christoph Grüninger's avatar
      Move final.hh to std. · a83057ba
      Christoph Grüninger authored
      DUNE_FINAL is a helper macro for C++11 and should be placed in
      std, where now all compatibility has to be placed.
      Beautify Doxygen documentation.
      a83057ba
  6. Mar 19, 2014
  7. Feb 14, 2014
  8. Dec 03, 2013
    • Christoph Gersbacher's avatar
      Implement read-only IdentityMatrix · 64df6274
      Christoph Gersbacher authored
      This implementation of an IdentityMatrix does not hold any data. It
      implements a reduced version of the DenseMatrix interface including a
      standard C++ cast operator to a Dune::FieldMatrix. This code illustrates
      the new forward capabilities of DenseMatrixAssigner.
      64df6274
  9. Oct 11, 2013
  10. Oct 02, 2013
  11. Oct 01, 2013
    • Martin Nolte's avatar
      [c++11] add support for C++11 constexpr · 45990b69
      Martin Nolte authored
      As decided on the developer meeting in Aachen, we support (but do not
      rely on) the C++11 keyword constexpr. This patch adds an m4-check for
      constexpr and a header (cxx11.hh) defining a macro DUNE_CONSTEXPR either
      as constexpr or empty (depending on the compiler support for it). It is
      then used in FieldVector and FieldMatrix on size, rows, and cols.
      45990b69
  12. Sep 27, 2013
  13. Aug 22, 2013
  14. Feb 22, 2013
  15. Feb 13, 2013
  16. Nov 25, 2012
    • Christian Engwer's avatar
      [hash] · 76733f41
      Christian Engwer authored
      Add basic support for hashing using Dune::hash
      
      This patch introduces the functor Dune::hash in a similar manner to
      other C++11 functionality by importing the definition from namespace std.
      
      Apart from that, the patch also provides some basic functionality to simplify
      making user-defined types hashable, in particular functions for combining hashes
      and hashing iterator ranges as well as a mechanism for defining the struct
      specializations required by std::hash and std::tr1::hash in the correct namespace.
      
      The current implementation will first try to use std::hash and, if that fails,
      attempt to fall back on std::tr1::hash. If that is not available either, hash
      support is disabled as there is no homegrown fallback for now.
      The extension mechanism will register the type with both std::hash and std::tr1::hash,
      if available. This should make it possible to use unordered_{set,map} from both C++11
      and TR1 without having to specify a custom hasher.
      
      Kudos to Steffen Müthing, see FS#1192
      
      [[Imported from SVN: r7065]]
      76733f41
  17. Nov 21, 2012
    • Markus Blatt's avatar
      · f2c14313
      Markus Blatt authored
      Capabilities to compute eigenvalues on non-symmetric matrices
      Code contributed by Arne Morten Kvarving.
      
      [[Imported from SVN: r7061]]
      f2c14313
  18. Oct 19, 2012
  19. Oct 09, 2012
    • Oliver Sander's avatar
      Add a new header power.hh for static computations of the power functions · 74c9a908
      Oliver Sander authored
      There are lots of power implementations all over our code.
      This is the first step of some cleanup.  It moves the class Power_m_p
      from misc.hh (like who's ever gonna find it there...) to a separate
      header power.hh.  Other implementations will be collected there as
      well, if appropriate.
      
      With the patch, including misc.hh will issue a cpp warning that people
      who include misc.hh only for Power_m_p should now include power.hh
      instead.  This is not great, because it also affects people who include
      misc.hh for something else.  Bear with this for a while; I couldn't
      think of a better solution.
      
      [[Imported from SVN: r7032]]
      74c9a908
  20. Oct 05, 2012
  21. Sep 27, 2012
  22. Sep 26, 2012
  23. Aug 28, 2012
  24. Aug 24, 2012
  25. Aug 22, 2012
    • Martin Nolte's avatar
      add SmartPtr · ee50361d
      Martin Nolte authored
      SmartPtr< T > is similar to shared_ptr< T > in its intention. However, it
      demands methods addReference and removeReference on the object it points to.
      Actually, you could implement shared_ptr< T > through a
      SmartPtr< RefCountWrapper< T > > and a few cast operators.
      
      [[Imported from SVN: r6919]]
      ee50361d
  26. Aug 14, 2012
  27. Aug 06, 2012
  28. Jul 11, 2012
  29. Jun 10, 2012
  30. Mar 20, 2012
  31. Jan 25, 2012
  32. Jan 08, 2012
  33. Aug 11, 2011
  34. Jun 08, 2011
  35. Jun 06, 2011
  36. May 04, 2011
  37. Mar 24, 2011
Loading