~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/temporal_format.cc

  • Committer: Olaf van der Spek
  • Date: 2011-06-23 11:06:21 UTC
  • mto: This revision was merged to the branch mainline in revision 2348.
  • Revision ID: olafvdspek@gmail.com-20110623110621-ins7o98d0q4xsy0a
Refactor

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
 
31
31
#include <config.h>
32
32
 
 
33
#include <boost/foreach.hpp>
33
34
#include <drizzled/temporal_format.h>
34
35
#include <drizzled/temporal.h>
35
36
 
41
42
 
42
43
using namespace std;
43
44
 
44
 
namespace drizzled
45
 
{
 
45
namespace drizzled {
46
46
 
47
47
TemporalFormat::TemporalFormat(const char *pattern) :
48
48
  _pattern(pattern)
302
302
/** Free all allocated temporal formats */
303
303
void deinit_temporal_formats()
304
304
{
305
 
  vector<TemporalFormat *>::iterator p= all_temporal_formats.begin();
306
 
  while (p != all_temporal_formats.end())
307
 
  {
308
 
    delete *p;
309
 
    ++p;
310
 
  }
 
305
  BOOST_FOREACH(TemporalFormat* it, all_temporal_formats)
 
306
    delete it;
311
307
  known_date_formats.clear();
312
308
  known_datetime_formats.clear();
313
309
  known_time_formats.clear();