Revision 1248

trunk/src/df1b2-separable/df1b2fn2.cpp (revision 1248)
118 118
#endif
119 119

  
120 120
/**
121
 * Description not yet available.
122
 * \param
123
 */
121
Initialize
122
*/
124 123
void df1b2variable::initialize(void)
125 124
{
126 125
#if defined(__CHECK_MEMORY__)
......
134 133
}
135 134

  
136 135
/**
137
 * Description not yet available.
138
 * \param
139
 */
136
Initialize nvariables
137

  
138
/param n nvariables
139
*/
140 140
void df1b2variable::initialize(int n)
141 141
{
142 142
  //int bs=get_blocksize(n);
......
271 271
  int no_destruct=0;
272 272

  
273 273
/**
274
 * Description not yet available.
275
 * \param
276
 */
277
  df1b2variable::~df1b2variable()
278
  {
274
Destructor
275
*/
276
df1b2variable::~df1b2variable()
277
{
279 278
    deallocate();
280
  }
279
}
281 280

  
282 281
/**
283
 * Description not yet available.
284
 * \param
285
 */
286
  void df1b2variable::deallocate(void)
282
If no other copies exist, free df1b2variable::ptr.
283
*/
284
void df1b2variable::deallocate(void)
285
{
286
  if (ptr)
287 287
  {
288
    if (ptr)
288
#if defined(__CHECK_MEMORY__)
289
    if (pchecker)
289 290
    {
290
#if defined(__CHECK_MEMORY__)
291
      if (pchecker)
291
      if (ptr == pchecker)
292 292
      {
293
        if (ptr == pchecker)
294
        {
295
          cout << "destructor called  " << endl;
296
        }
293
        cout << "destructor called  " << endl;
297 294
      }
295
    }
298 296
#endif
299
      if (*ncopies)
300
      {
301
        (*ncopies)--;
302
      }
303
      else
304
      {
305
        if (!df1b2_gradlist::no_derivatives)
306
          f1b2gradlist->write_save_pass2_tilde_values(this);
307
        ((twointsandptr*)ptr)->ptr->free(ptr);
297
    if (ncopies && *ncopies)
298
    {
299
      (*ncopies)--;
300
    }
301
    else
302
    {
303
      if (!df1b2_gradlist::no_derivatives)
304
        f1b2gradlist->write_save_pass2_tilde_values(this);
305
      ((twointsandptr*)ptr)->ptr->free(ptr);
308 306

  
309
        ptr=0;
310
      }
307
      ptr = 0;
311 308
    }
312 309
  }
310
}
313 311

  
314 312
/**
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff