| OLD | NEW |
| (Empty) |
| 1 {% from "macros.tmpl" import license -%} | |
| 2 {{ license() }} | |
| 3 | |
| 4 #include "config.h" | |
| 5 | |
| 6 #ifdef SKIP_STATIC_CONSTRUCTORS_ON_GCC | |
| 7 #define {{namespace}}_HIDE_GLOBALS 1 | |
| 8 #endif | |
| 9 | |
| 10 #include "{{namespace}}.h" | |
| 11 | |
| 12 #include "wtf/StaticConstructors.h" | |
| 13 | |
| 14 namespace WebCore { | |
| 15 namespace {{namespace}} { | |
| 16 | |
| 17 using namespace WTF; | |
| 18 | |
| 19 {%- for name in names %} | |
| 20 DEFINE_GLOBAL(AtomicString, {{name}}) | |
| 21 {%- endfor %} | |
| 22 | |
| 23 void init() | |
| 24 { | |
| 25 {%- for name in names %} | |
| 26 StringImpl* {{name}}Impl = StringImpl::createStatic("{{name}}", {{name|lengt
h}}, {{name|hash}}); | |
| 27 {%- endfor %} | |
| 28 | |
| 29 | |
| 30 {%- for name in names %} | |
| 31 new ((void*)&{{name}}) AtomicString({{name}}Impl); | |
| 32 {%- endfor %} | |
| 33 } | |
| 34 | |
| 35 } // {{namespace}} | |
| 36 } // WebCore | |
| OLD | NEW |