14#include "arcane/utils/ArcanePrecomp.h"
16#include "arcane/utils/String.h"
17#include "arcane/utils/BadAlignmentException.h"
30BadAlignmentException::
31BadAlignmentException(
const String& awhere,
const void* ptr,Integer alignment)
32: Exception(
"BadAlignmentException",awhere)
34, m_wanted_alignment(alignment)
41BadAlignmentException::
42BadAlignmentException(
const TraceInfo& awhere,
const void* ptr,Integer alignment)
43: Exception(
"BadAlignmentException",awhere)
45, m_wanted_alignment(alignment)
52void BadAlignmentException::
53explain(std::ostream& m)
const
56 if (m_wanted_alignment>0){
57 Int64
ptr = (Int64)m_ptr;
58 alignment =
ptr % m_wanted_alignment;
60 m <<
"Bad alignment for address " << m_ptr
61 <<
" alignment=" << alignment
62 <<
" (wanted=" << m_wanted_alignment <<
").";
Lecteur des fichiers de maillage via la bibliothèque LIMA.