(editor-command-template-alist): Use char iso
[lilypond/patrick.git] / lily / global-ctor.cc
blobd6214275560764c06e3d755fec6e19c1bd75c1e8
1 /*
2 global-ctor.cc -- implement global constructors
4 source file of the GNU LilyPond music typesetter
6 (c) 1999--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
7 */
9 #include "global-ctor.hh"
11 #include "array.hh"
13 static Array<Global_ctor> *ctor_global_statics_;
15 void
16 add_constructor (Global_ctor c)
18 if (!ctor_global_statics_)
19 ctor_global_statics_ = new Array<Global_ctor>;
20 ctor_global_statics_->push (c);
23 void
24 call_constructors ()
26 for (int i = 0; i < ctor_global_statics_->size (); i++)
27 (ctor_global_statics_->elem (i)) ();