src/value.cpp
/*!
 * \fn ~Value()
 * \brief destroys the reference to the value
 * 
 * If this instance was the last reference, the underlying value is 
 * destroyed.
 */
\fn ~Value()
\brief destroys the reference to the value

If this instance was the last reference, the underlying value is
destroyed.
\ fn ~Value () \ brief destroys the reference to the value If this instance was the last reference the underlying value is destroyed .
Value::~Value()
{
  if (d)
  {
    if (--(d->ref) == 0)
    {
      delete d;
    }
  }
}
Value :: ~ Value ( ) { if ( d ) { if ( -- ( d -> ref ) == 0 ) { delete d ; } } }
\fn ~Value()
 \brief destroys the reference to the value
\ fn ~Value () \ brief destroys the reference to the value
/// TODO : add a check for non-destructed objects (i.e. potential memory leaks)