Bug 502176 - Replace static use of jArray with a plain old data staticJArray, introduce an autoJArray for nicer memory management. r=tglek, a=jst.
authorHenri Sivonen <hsivonen@iki.fi>
Tue, 28 Sep 2010 10:32:31 +0300
changeset 57196 e92d70898e2201a58214f536d224bba755f16147
parent 57195 b6e015e6a709fd609b2747902207e02981e028d1
child 57197 9623c20329488f0511d7a5d93805aa0243e2c91d
push id16841
push userhsivonen@iki.fi
push dateWed, 10 Nov 2010 09:25:22 +0000
treeherdermozilla-central@9623c2032948 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstglek, jst
bugs502176
milestone2.0b8pre
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 502176 - Replace static use of jArray with a plain old data staticJArray, introduce an autoJArray for nicer memory management. r=tglek, a=jst.
parser/html/jArray.h
parser/html/javasrc/ElementName.java
parser/html/javasrc/HtmlAttributes.java
parser/html/javasrc/MetaScanner.java
parser/html/javasrc/Portability.java
parser/html/javasrc/StateSnapshot.java
parser/html/javasrc/Tokenizer.java
parser/html/javasrc/TreeBuilder.java
parser/html/nsHtml5AttributeName.cpp
parser/html/nsHtml5AttributeName.h
parser/html/nsHtml5ElementName.cpp
parser/html/nsHtml5ElementName.h
parser/html/nsHtml5HtmlAttributes.cpp
parser/html/nsHtml5HtmlAttributes.h
parser/html/nsHtml5MetaScanner.cpp
parser/html/nsHtml5MetaScanner.h
parser/html/nsHtml5MetaScannerCppSupplement.h
parser/html/nsHtml5Portability.cpp
parser/html/nsHtml5Portability.h
parser/html/nsHtml5StackNode.h
parser/html/nsHtml5StateSnapshot.cpp
parser/html/nsHtml5StateSnapshot.h
parser/html/nsHtml5Tokenizer.cpp
parser/html/nsHtml5Tokenizer.h
parser/html/nsHtml5TreeBuilder.cpp
parser/html/nsHtml5TreeBuilder.h
parser/html/nsHtml5TreeBuilderCppSupplement.h
parser/html/nsHtml5UTF16Buffer.h
--- a/parser/html/jArray.h
+++ b/parser/html/jArray.h
@@ -1,10 +1,10 @@
 /*
- * Copyright (c) 2008 Mozilla Foundation
+ * Copyright (c) 2008-2010 Mozilla Foundation
  *
  * Permission is hereby granted, free of charge, to any person obtaining a
  * copy of this software and associated documentation files (the "Software"),
  * to deal in the Software without restriction, including without limitation
  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
  * and/or sell copies of the Software, and to permit persons to whom the
  * Software is furnished to do so, subject to the following conditions:
  *
@@ -15,74 +15,97 @@
  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
  * DEALINGS IN THE SOFTWARE.
  */
 
-#ifndef jArray_h__
-#define jArray_h__
+#ifndef jArray_h_
+#define jArray_h_
 
-#define J_ARRAY_STATIC(T, L, arr) \
-  jArray<T,L>( ((T*)arr), (sizeof(arr)/sizeof(arr[0])) )
+#include "nsDebug.h"
 
 template<class T, class L>
-class jArray {
+struct staticJArray {
+  const T* arr;
+  const L length;
+  operator T*() { return arr; }
+  T& operator[] (L const index) { return ((T*)arr)[index]; }
+  L binarySearch(T const elem) {
+    L lo = 0;
+    L hi = length - 1;
+    while (lo <= hi) {
+      L mid = (lo + hi) / 2;
+      if (arr[mid] > elem) {
+        hi = mid - 1;
+      } else if (arr[mid] < elem) {
+        lo = mid + 1;
+      } else {
+        return mid;
+      }
+    }
+    return -1;
+  }
+};
+
+template<class T, class L>
+struct jArray {
+  T* arr;
+  L length;
+  static jArray<T,L> newJArray(L const len) {
+    NS_ASSERTION(len >= 0, "Bad length.");
+    jArray<T,L> newArray = { new T[len], len };
+    return newArray;
+  }
+  operator T*() { return arr; }
+  T& operator[] (L const index) { return arr[index]; }
+  void operator=(staticJArray<T,L>& other) {
+    arr = (T*)other.arr;
+    length = other.length;
+  }
+};
+
+template<class T, class L>
+class autoJArray {
   private:
     T* arr;
   public:
     L length;
-    jArray(T* const a, L const len);
-    jArray(L const len);
-    jArray(const jArray<T,L>& other);
-    jArray();
+    autoJArray()
+     : arr(0)
+     , length(0)
+    {
+    }
+    autoJArray(const jArray<T,L>& other)
+     : arr(other.arr)
+     , length(other.length)
+    {
+    }
+    ~autoJArray()
+    {
+      delete[] arr;
+    }
     operator T*() { return arr; }
     T& operator[] (L const index) { return arr[index]; }
-    void release() { delete[] arr; arr = 0; length = 0; }
-    L binarySearch(T const elem);
+    operator jArray<T,L>() {
+      // WARNING! This makes it possible to goof with buffer ownership!
+      // This is needed for the getStack and getListOfActiveFormattingElements
+      // methods to work sensibly.
+      jArray<T,L> newArray = { arr, length };
+      return newArray;
+    }
+    void operator=(const jArray<T,L>& other) {
+      delete[] arr;
+      arr = other.arr;
+      length = other.length;
+    }
+    void operator=(L zero) {
+      // Make assigning null to an array in Java delete the buffer in C++
+      NS_ASSERTION(!zero, "Non-zero integer assigned to jArray.");
+      delete[] arr;
+      arr = 0;
+      length = 0;
+    }
 };
 
-template<class T, class L>
-jArray<T,L>::jArray(T* const a, L const len)
-       : arr(a), length(len)
-{
-}
-
-template<class T, class L>
-jArray<T,L>::jArray(L const len)
-       : arr(len ? new T[len] : 0), length(len)
-{
-}
-
-template<class T, class L>
-jArray<T,L>::jArray(const jArray<T,L>& other)
-       : arr(other.arr), length(other.length)
-{
-}
-
-template<class T, class L>
-jArray<T,L>::jArray()
-       : arr(0), length(0)
-{
-}
-
-template<class T, class L>
-L
-jArray<T,L>::binarySearch(T const elem)
-{
-  L lo = 0;
-  L hi = length - 1;
-  while (lo <= hi) {
-    L mid = (lo + hi) / 2;
-    if (arr[mid] > elem) {
-      hi = mid - 1;
-    } else if (arr[mid] < elem) {
-      lo = mid + 1;
-    } else {
-      return mid;
-    }
-  }
-  return -1;
-}
-
-#endif // jArray_h__
+#endif // jArray_h_
--- a/parser/html/javasrc/ElementName.java
+++ b/parser/html/javasrc/ElementName.java
@@ -49,17 +49,17 @@ public final class ElementName
     public final boolean fosterParenting;
 
     // [NOCPP[
     
     public final boolean custom;
 
     // ]NOCPP]
     
-    static ElementName elementNameByBuffer(char[] buf, int offset, int length, Interner interner) {
+    static ElementName elementNameByBuffer(@NoLength char[] buf, int offset, int length, Interner interner) {
         int hash = ElementName.bufToHash(buf, length);
         int index = Arrays.binarySearch(ElementName.ELEMENT_HASHES, hash);
         if (index < 0) {
             return new ElementName(Portability.newLocalNameFromBuffer(buf, offset, length, interner));
         } else {
             ElementName elementName = ElementName.ELEMENT_NAMES[index];
             @Local String name = elementName.name;
             if (!Portability.localEqualsBuffer(name, buf, offset, length)) {
@@ -73,17 +73,17 @@ public final class ElementName
     /**
      * This method has to return a unique integer for each well-known
      * lower-cased element name.
      * 
      * @param buf
      * @param len
      * @return
      */
-    private static int bufToHash(char[] buf, int len) {
+    private static int bufToHash(@NoLength char[] buf, int len) {
         int hash = len;
         hash <<= 5;
         hash += buf[0] - 0x60;
         int j = len;
         for (int i = 0; i < 4 && j > 0; i++) {
             j--;
             hash <<= 5;
             hash += buf[j] - 0x60;
--- a/parser/html/javasrc/HtmlAttributes.java
+++ b/parser/html/javasrc/HtmlAttributes.java
@@ -18,16 +18,17 @@
  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 
  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 
  * DEALINGS IN THE SOFTWARE.
  */
 
 package nu.validator.htmlparser.impl;
 
+import nu.validator.htmlparser.annotation.Auto;
 import nu.validator.htmlparser.annotation.IdType;
 import nu.validator.htmlparser.annotation.Local;
 import nu.validator.htmlparser.annotation.NsUri;
 import nu.validator.htmlparser.annotation.Prefix;
 import nu.validator.htmlparser.annotation.QName;
 import nu.validator.htmlparser.common.Interner;
 import nu.validator.htmlparser.common.XmlViolationPolicy;
 
@@ -53,19 +54,19 @@ public final class HtmlAttributes implem
 
     public static final HtmlAttributes EMPTY_ATTRIBUTES = new HtmlAttributes(
             AttributeName.HTML);
 
     private int mode;
 
     private int length;
 
-    private AttributeName[] names;
+    private @Auto AttributeName[] names;
 
-    private String[] values; // XXX perhaps make this @NoLength?
+    private @Auto String[] values; // XXX perhaps make this @NoLength?
 
     // [NOCPP[
 
     private String idValue;
 
     private int xmlnsLength;
 
     private AttributeName[] xmlnsNames;
@@ -108,18 +109,16 @@ public final class HtmlAttributes implem
         this.xmlnsNames = new AttributeName[other.xmlnsLength];
         this.xmlnsValues = new String[other.xmlnsLength];
         // ]NOCPP]
     }
     */
 
     void destructor() {
         clear(0);
-        Portability.releaseArray(names);
-        Portability.releaseArray(values);
     }
     
     /**
      * Only use with a static argument
      * 
      * @param name
      * @return
      */
@@ -368,21 +367,19 @@ public final class HtmlAttributes implem
         // ]NOCPP]
 
         if (names.length == length) {
             int newLen = length << 1; // The first growth covers virtually
             // 100% of elements according to
             // Hixie
             AttributeName[] newNames = new AttributeName[newLen];
             System.arraycopy(names, 0, newNames, 0, names.length);
-            Portability.releaseArray(names);
             names = newNames;
             String[] newValues = new String[newLen];
             System.arraycopy(values, 0, newValues, 0, values.length);
-            Portability.releaseArray(values);
             values = newValues;
         }
         names[length] = name;
         values[length] = value;
         length++;
     }
 
     void clear(int m) {
--- a/parser/html/javasrc/MetaScanner.java
+++ b/parser/html/javasrc/MetaScanner.java
@@ -20,16 +20,17 @@
  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 
  * DEALINGS IN THE SOFTWARE.
  */
 
 package nu.validator.htmlparser.impl;
 
 import java.io.IOException;
 
+import nu.validator.htmlparser.annotation.Auto;
 import nu.validator.htmlparser.annotation.NoLength;
 import nu.validator.htmlparser.common.ByteReadable;
 
 import org.xml.sax.SAXException;
 
 public abstract class MetaScanner {
 
     /**
@@ -120,17 +121,17 @@ public abstract class MetaScanner {
     /**
      * The currently filled length of strBuf.
      */
     private int strBufLen;
 
     /**
      * Accumulation buffer for attribute values.
      */
-    private char[] strBuf;
+    private @Auto char[] strBuf;
     
     // [NOCPP[
     
     /**
      * @param source
      * @param errorHandler
      * @param publicId
      * @param systemId
@@ -693,17 +694,16 @@ public abstract class MetaScanner {
     /**
      * Adds a character to the accumulation buffer.
      * @param c the character to add
      */
     private void addToBuffer(int c) {
         if (strBufLen == strBuf.length) {
             char[] newBuf = new char[strBuf.length + (strBuf.length << 1)];
             System.arraycopy(strBuf, 0, newBuf, 0, strBuf.length);
-            Portability.releaseArray(strBuf);
             strBuf = newBuf;
         }
         strBuf[strBufLen++] = (char)c;
     }
 
     /**
      * Attempts to extract a charset name from the accumulation buffer.
      * @return <code>true</code> if successful
--- a/parser/html/javasrc/Portability.java
+++ b/parser/html/javasrc/Portability.java
@@ -81,24 +81,16 @@ public final class Portability {
     /**
      * This MUST be a no-op on locals that are known at compile time.
      * @param local
      */
     public static void releaseLocal(@Local String local) {
         // No-op in Java
     }
     
-    /**
-     * Releases a Java array. This method is magically replaced by a macro in C++.
-     * @param arr
-     */
-    public static void releaseArray(Object arr) {
-        // No-op in Java
-    }    
-    
     // [NOCPP[
     // These are no longer used in Gecko. Need to decide what to do about these in the long term.    
     
     public static void retainElement(Object elt) {
         // No-op in Java
     }
 
     public static void releaseElement(Object elt) {
--- a/parser/html/javasrc/StateSnapshot.java
+++ b/parser/html/javasrc/StateSnapshot.java
@@ -1,10 +1,10 @@
 /*
- * Copyright (c) 2009 Mozilla Foundation
+ * Copyright (c) 2009-2010 Mozilla Foundation
  *
  * Permission is hereby granted, free of charge, to any person obtaining a 
  * copy of this software and associated documentation files (the "Software"), 
  * to deal in the Software without restriction, including without limitation 
  * the rights to use, copy, modify, merge, publish, distribute, sublicense, 
  * and/or sell copies of the Software, and to permit persons to whom the 
  * Software is furnished to do so, subject to the following conditions:
  *
@@ -17,22 +17,24 @@
  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 
  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 
  * DEALINGS IN THE SOFTWARE.
  */
 
 package nu.validator.htmlparser.impl;
 
+import nu.validator.htmlparser.annotation.Auto;
+
 
 public class StateSnapshot<T> implements TreeBuilderState<T> {
 
-    private final StackNode<T>[] stack;
+    private final @Auto StackNode<T>[] stack;
 
-    private final StackNode<T>[] listOfActiveFormattingElements;
+    private final @Auto StackNode<T>[] listOfActiveFormattingElements;
 
     private final T formPointer;
 
     private final T headPointer;
 
     private final T deepTreeSurrogateParent;
 
     private final int mode;
@@ -178,18 +180,16 @@ public class StateSnapshot<T> implements
     public int getStackLength() {
         return stack.length;
     }
 
     @SuppressWarnings("unused") private void destructor() {
         for (int i = 0; i < stack.length; i++) {
             stack[i].release();
         }
-        Portability.releaseArray(stack);
         for (int i = 0; i < listOfActiveFormattingElements.length; i++) {
             if (listOfActiveFormattingElements[i] != null) {
                 listOfActiveFormattingElements[i].release();                
             }
         }
-        Portability.releaseArray(listOfActiveFormattingElements);
         Portability.retainElement(formPointer);
     }
 }
--- a/parser/html/javasrc/Tokenizer.java
+++ b/parser/html/javasrc/Tokenizer.java
@@ -30,16 +30,17 @@
  * That document came with this statement:
  * "© Copyright 2004-2010 Apple Computer, Inc., Mozilla Foundation, and 
  * Opera Software ASA. You are granted a license to use, reproduce and 
  * create derivative works of this document."
  */
 
 package nu.validator.htmlparser.impl;
 
+import nu.validator.htmlparser.annotation.Auto;
 import nu.validator.htmlparser.annotation.Const;
 import nu.validator.htmlparser.annotation.Inline;
 import nu.validator.htmlparser.annotation.Local;
 import nu.validator.htmlparser.annotation.NoLength;
 import nu.validator.htmlparser.common.EncodingDeclarationHandler;
 import nu.validator.htmlparser.common.Interner;
 import nu.validator.htmlparser.common.TokenHandler;
 import nu.validator.htmlparser.common.XmlViolationPolicy;
@@ -367,60 +368,60 @@ public class Tokenizer implements Locato
      * The SAX system id for the resource being tokenized. (Only passed to back
      * as part of locator data.)
      */
     private String systemId;
 
     /**
      * Buffer for short identifiers.
      */
-    private char[] strBuf;
+    private @Auto char[] strBuf;
 
     /**
      * Number of significant <code>char</code>s in <code>strBuf</code>.
      */
     private int strBufLen;
 
     /**
      * <code>-1</code> to indicate that <code>strBuf</code> is used or otherwise
      * an offset to the main buffer.
      */
     // private int strBufOffset = -1;
     /**
      * Buffer for long strings.
      */
-    private char[] longStrBuf;
+    private @Auto char[] longStrBuf;
 
     /**
      * Number of significant <code>char</code>s in <code>longStrBuf</code>.
      */
     private int longStrBufLen;
 
     /**
      * <code>-1</code> to indicate that <code>longStrBuf</code> is used or
      * otherwise an offset to the main buffer.
      */
     // private int longStrBufOffset = -1;
 
     /**
      * Buffer for expanding NCRs falling into the Basic Multilingual Plane.
      */
-    private final char[] bmpChar;
+    private final @Auto char[] bmpChar;
 
     /**
      * Buffer for expanding astral NCRs.
      */
-    private final char[] astralChar;
+    private final @Auto char[] astralChar;
 
     /**
      * The element whose end tag closes the current CDATA or RCDATA element.
      */
     protected ElementName endTagExpectation = null;
 
-    private char[] endTagExpectationAsArray;
+    private char[] endTagExpectationAsArray; // not @Auto!
 
     /**
      * <code>true</code> if tokenizing an end tag
      */
     protected boolean endTag;
 
     /**
      * The current tag token name.
@@ -550,21 +551,16 @@ public class Tokenizer implements Locato
     }
 
     public void initLocation(String newPublicId, String newSystemId) {
         this.systemId = newSystemId;
         this.publicId = newPublicId;
 
     }
 
-    void destructor() {
-        Portability.releaseArray(bmpChar);
-        Portability.releaseArray(astralChar);
-    }
-
     // [NOCPP[
 
     /**
      * Returns the mappingLangToXmlLang.
      * 
      * @return the mappingLangToXmlLang
      */
     public boolean isMappingLangToXmlLang() {
@@ -671,20 +667,19 @@ public class Tokenizer implements Locato
      *            the expected end tag for transitioning back to normal
      */
     public void setStateAndEndTagExpectation(int specialTokenizerState,
             @Local String endTagExpectation) {
         this.stateSave = specialTokenizerState;
         if (specialTokenizerState == Tokenizer.DATA) {
             return;
         }
-        char[] asArray = Portability.newCharArrayFromLocal(endTagExpectation);
+        @Auto char[] asArray = Portability.newCharArrayFromLocal(endTagExpectation);
         this.endTagExpectation = ElementName.elementNameByBuffer(asArray, 0,
                 asArray.length, interner);
-        Portability.releaseArray(asArray);
         endTagExpectationToArray();
     }
 
     /**
      * Sets the tokenizer state and the associated element name. This should 
      * only ever used to put the tokenizer into one of the states that have
      * a special end tag expectation.
      * 
@@ -817,17 +812,16 @@ public class Tokenizer implements Locato
      * 
      * @param c
      *            the UTF-16 code unit to append
      */
     private void appendStrBuf(char c) {
         if (strBufLen == strBuf.length) {
             char[] newBuf = new char[strBuf.length + Tokenizer.BUFFER_GROW_BY];
             System.arraycopy(strBuf, 0, newBuf, 0, strBuf.length);
-            Portability.releaseArray(strBuf);
             strBuf = newBuf;
         }
         strBuf[strBufLen++] = c;
     }
 
     /**
      * The smaller buffer as a String. Currently only used for error reporting.
      * 
@@ -877,17 +871,16 @@ public class Tokenizer implements Locato
      * 
      * @param c
      *            the UTF-16 code unit to append
      */
     private void appendLongStrBuf(char c) {
         if (longStrBufLen == longStrBuf.length) {
             char[] newBuf = new char[longStrBufLen + (longStrBufLen >> 1)];
             System.arraycopy(longStrBuf, 0, newBuf, 0, longStrBuf.length);
-            Portability.releaseArray(longStrBuf);
             longStrBuf = newBuf;
         }
         longStrBuf[longStrBufLen++] = c;
     }
 
     @Inline private void appendSecondHyphenToBogusComment() throws SAXException {
         // [NOCPP[
         switch (commentPolicy) {
@@ -945,22 +938,21 @@ public class Tokenizer implements Locato
                 break;
             case FATAL:
                 fatal("The document is not mappable to XML 1.0 due to two consecutive hyphens in a comment.");
                 break;
         }
         // ]NOCPP]
     }
 
-    private void appendLongStrBuf(char[] buffer, int offset, int length) {
+    private void appendLongStrBuf(@NoLength char[] buffer, int offset, int length) {
         int reqLen = longStrBufLen + length;
         if (longStrBuf.length < reqLen) {
             char[] newBuf = new char[reqLen + (reqLen >> 1)];
             System.arraycopy(longStrBuf, 0, newBuf, 0, longStrBuf.length);
-            Portability.releaseArray(longStrBuf);
             longStrBuf = newBuf;
         }
         System.arraycopy(buffer, offset, longStrBuf, longStrBufLen, length);
         longStrBufLen = reqLen;
     }
 
     /**
      * Append the contents of the smaller buffer to the larger one.
@@ -6487,19 +6479,17 @@ public class Tokenizer implements Locato
         if ((returnState & DATA_AND_RCDATA_MASK) != 0) {
             appendLongStrBuf(val[0]);
         } else {
             tokenHandler.characters(val, 0, 1);
         }
     }
 
     public void end() throws SAXException {
-        Portability.releaseArray(strBuf);
         strBuf = null;
-        Portability.releaseArray(longStrBuf);
         longStrBuf = null;
         Portability.releaseLocal(doctypeName);
         doctypeName = null;
         if (systemIdentifier != null) {
             Portability.releaseString(systemIdentifier);
             systemIdentifier = null;
         }
         if (publicIdentifier != null) {
@@ -6576,17 +6566,17 @@ public class Tokenizer implements Locato
         // line = 1; XXX line numbers
         lastCR = false;
         index = 0;
         forceQuirks = false;
         additional = '\u0000';
         entCol = -1;
         firstCharKey = -1;
         lo = 0;
-        hi = (NamedCharacters.NAMES.length - 1);
+        hi = 0; // will always be overwritten before use anyway
         candidate = -1;
         strBufMark = 0;
         prevValue = -1;
         value = 0;
         seenDigits = false;
         endTag = false;
         shouldSuspend = false;
         initDoctypeFields();
@@ -6608,24 +6598,22 @@ public class Tokenizer implements Locato
             // [NOCPP[
         }
         // ]NOCPP]
     }
 
     public void loadState(Tokenizer other) throws SAXException {
         strBufLen = other.strBufLen;
         if (strBufLen > strBuf.length) {
-            Portability.releaseArray(strBuf);
             strBuf = new char[strBufLen];
         }
         System.arraycopy(other.strBuf, 0, strBuf, 0, strBufLen);
 
         longStrBufLen = other.longStrBufLen;
         if (longStrBufLen > longStrBuf.length) {
-            Portability.releaseArray(longStrBuf);
             longStrBuf = new char[longStrBufLen];
         }
         System.arraycopy(other.longStrBuf, 0, longStrBuf, 0, longStrBufLen);
 
         stateSave = other.stateSave;
         returnStateSave = other.returnStateSave;
         endTagExpectation = other.endTagExpectation;
         endTagExpectationAsArray = other.endTagExpectationAsArray;
--- a/parser/html/javasrc/TreeBuilder.java
+++ b/parser/html/javasrc/TreeBuilder.java
@@ -34,16 +34,17 @@
  */
 
 package nu.validator.htmlparser.impl;
 
 import java.util.Arrays;
 import java.util.HashMap;
 import java.util.Map;
 
+import nu.validator.htmlparser.annotation.Auto;
 import nu.validator.htmlparser.annotation.Const;
 import nu.validator.htmlparser.annotation.IdType;
 import nu.validator.htmlparser.annotation.Inline;
 import nu.validator.htmlparser.annotation.Literal;
 import nu.validator.htmlparser.annotation.Local;
 import nu.validator.htmlparser.annotation.NoLength;
 import nu.validator.htmlparser.annotation.NsUri;
 import nu.validator.htmlparser.common.DoctypeExpectation;
@@ -380,34 +381,34 @@ public abstract class TreeBuilder<T> imp
     private boolean fragment;
 
     private @Local String contextName;
 
     private @NsUri String contextNamespace;
 
     private T contextNode;
 
-    private StackNode<T>[] stack;
+    private @Auto StackNode<T>[] stack;
 
     private int currentPtr = -1;
 
-    private StackNode<T>[] listOfActiveFormattingElements;
+    private @Auto StackNode<T>[] listOfActiveFormattingElements;
 
     private int listPtr = -1;
 
     private T formPointer;
 
     private T headPointer;
 
     /**
      * Used to work around Gecko limitations. Not used in Java.
      */
     private T deepTreeSurrogateParent;
 
-    protected char[] charBuffer;
+    protected @Auto char[] charBuffer;
 
     protected int charBufferLen = 0;
 
     private boolean quirks = false;
 
     // [NOCPP[
 
     private boolean reportingDoctype = true;
@@ -1398,36 +1399,31 @@ public abstract class TreeBuilder<T> imp
         headPointer = null;
         Portability.releaseElement(deepTreeSurrogateParent);
         deepTreeSurrogateParent = null;
         if (stack != null) {
             while (currentPtr > -1) {
                 stack[currentPtr].release();
                 currentPtr--;
             }
-            Portability.releaseArray(stack);
             stack = null;
         }
         if (listOfActiveFormattingElements != null) {
             while (listPtr > -1) {
                 if (listOfActiveFormattingElements[listPtr] != null) {
                     listOfActiveFormattingElements[listPtr].release();
                 }
                 listPtr--;
             }
-            Portability.releaseArray(listOfActiveFormattingElements);
             listOfActiveFormattingElements = null;
         }
         // [NOCPP[
         idLocations.clear();
         // ]NOCPP]
-        if (charBuffer != null) {
-            Portability.releaseArray(charBuffer);
-            charBuffer = null;
-        }
+        charBuffer = null;
         end();
     }
 
     public final void startTag(ElementName elementName,
             HtmlAttributes attributes, boolean selfClosing) throws SAXException {
         flushCharacters();
         // [NOCPP[
         if (errorHandler != null) {
@@ -2073,20 +2069,19 @@ public abstract class TreeBuilder<T> imp
                                         ElementName.HR,
                                         HtmlAttributes.EMPTY_ATTRIBUTES);
                                 appendToCurrentNodeAndPushElementMayFoster(
                                         "http://www.w3.org/1999/xhtml",
                                         ElementName.LABEL,
                                         HtmlAttributes.EMPTY_ATTRIBUTES);
                                 int promptIndex = attributes.getIndex(AttributeName.PROMPT);
                                 if (promptIndex > -1) {
-                                    char[] prompt = Portability.newCharArrayFromString(attributes.getValue(promptIndex));
+                                    @Auto char[] prompt = Portability.newCharArrayFromString(attributes.getValue(promptIndex));
                                     appendCharacters(stack[currentPtr].node,
                                             prompt, 0, prompt.length);
-                                    Portability.releaseArray(prompt);
                                 } else {
                                     appendIsindexPrompt(stack[currentPtr].node);
                                 }
                                 HtmlAttributes inputAttributes = new HtmlAttributes(
                                         0);
                                 inputAttributes.addAttribute(
                                         AttributeName.NAME,
                                         Portability.newStringFromLiteral("isindex")
@@ -2948,17 +2943,17 @@ public abstract class TreeBuilder<T> imp
      * @throws StopSniffingException
      */
     public static String extractCharsetFromContent(String attributeValue) {
         // This is a bit ugly. Converting the string to char array in order to
         // make the portability layer smaller.
         int charsetState = CHARSET_INITIAL;
         int start = -1;
         int end = -1;
-        char[] buffer = Portability.newCharArrayFromString(attributeValue);
+        @Auto char[] buffer = Portability.newCharArrayFromString(attributeValue);
 
         charsetloop: for (int i = 0; i < buffer.length; i++) {
             char c = buffer[i];
             switch (charsetState) {
                 case CHARSET_INITIAL:
                     switch (c) {
                         case 'c':
                         case 'C':
@@ -3096,17 +3091,16 @@ public abstract class TreeBuilder<T> imp
         String charset = null;
         if (start != -1) {
             if (end == -1) {
                 end = buffer.length;
             }
             charset = Portability.newStringFromBuffer(buffer, start, end
                     - start);
         }
-        Portability.releaseArray(buffer);
         return charset;
     }
 
     private void checkMetaCharset(HtmlAttributes attributes)
             throws SAXException {
         String content = attributes.getValue(AttributeName.CONTENT);
         String internalCharsetLegacy = null;
         if (content != null) {
@@ -4235,41 +4229,38 @@ public abstract class TreeBuilder<T> imp
         return true;
     }
 
     @SuppressWarnings("unchecked") private void push(StackNode<T> node) throws SAXException {
         currentPtr++;
         if (currentPtr == stack.length) {
             StackNode<T>[] newStack = new StackNode[stack.length + 64];
             System.arraycopy(stack, 0, newStack, 0, stack.length);
-            Portability.releaseArray(stack);
             stack = newStack;
         }
         stack[currentPtr] = node;
         elementPushed(node.ns, node.popName, node.node);
     }
 
     @SuppressWarnings("unchecked") private void silentPush(StackNode<T> node) throws SAXException {
         currentPtr++;
         if (currentPtr == stack.length) {
             StackNode<T>[] newStack = new StackNode[stack.length + 64];
             System.arraycopy(stack, 0, newStack, 0, stack.length);
-            Portability.releaseArray(stack);
             stack = newStack;
         }
         stack[currentPtr] = node;
     }
 
     @SuppressWarnings("unchecked") private void append(StackNode<T> node) {
         listPtr++;
         if (listPtr == listOfActiveFormattingElements.length) {
             StackNode<T>[] newList = new StackNode[listOfActiveFormattingElements.length + 64];
             System.arraycopy(listOfActiveFormattingElements, 0, newList, 0,
                     listOfActiveFormattingElements.length);
-            Portability.releaseArray(listOfActiveFormattingElements);
             listOfActiveFormattingElements = newList;
         }
         listOfActiveFormattingElements[listPtr] = node;
     }
 
     @Inline private void insertMarker() {
         append(null);
     }
@@ -5076,17 +5067,16 @@ public abstract class TreeBuilder<T> imp
     // [NOCPP[
     
     private final void accumulateCharactersForced(@Const @NoLength char[] buf,
             int start, int length) throws SAXException {
         int newLen = charBufferLen + length;
         if (newLen > charBuffer.length) {
             char[] newBuf = new char[newLen];
             System.arraycopy(charBuffer, 0, newBuf, 0, charBufferLen);
-            Portability.releaseArray(charBuffer);
             charBuffer = newBuf;
         }
         System.arraycopy(buf, start, charBuffer, charBufferLen, length);
         charBufferLen = newLen;
     }
     
     // ]NOCPP]
     
@@ -5452,26 +5442,24 @@ public abstract class TreeBuilder<T> imp
         int listLen = snapshot.getListOfActiveFormattingElementsLength();
         
         for (int i = 0; i <= listPtr; i++) {
             if (listOfActiveFormattingElements[i] != null) {
                 listOfActiveFormattingElements[i].release();
             }
         }
         if (listOfActiveFormattingElements.length < listLen) {
-            Portability.releaseArray(listOfActiveFormattingElements);
             listOfActiveFormattingElements = new StackNode[listLen];
         }
         listPtr = listLen - 1;
 
         for (int i = 0; i <= currentPtr; i++) {
             stack[i].release();
         }
         if (stack.length < stackLen) {
-            Portability.releaseArray(stack);
             stack = new StackNode[stackLen];
         }
         currentPtr = stackLen - 1;
 
         for (int i = 0; i < listLen; i++) {
             StackNode<T> node = listCopy[i];
             if (node != null) {
                 StackNode<T> newNode = new StackNode<T>(node.group, node.ns,
--- a/parser/html/nsHtml5AttributeName.cpp
+++ b/parser/html/nsHtml5AttributeName.cpp
@@ -54,16 +54,24 @@
 #include "nsHtml5StackNode.h"
 #include "nsHtml5UTF16Buffer.h"
 #include "nsHtml5StateSnapshot.h"
 #include "nsHtml5Portability.h"
 
 #include "nsHtml5AttributeName.h"
 #include "nsHtml5ReleasableAttributeName.h"
 
+PRInt32* nsHtml5AttributeName::ALL_NO_NS = 0;
+PRInt32* nsHtml5AttributeName::XMLNS_NS = 0;
+PRInt32* nsHtml5AttributeName::XML_NS = 0;
+PRInt32* nsHtml5AttributeName::XLINK_NS = 0;
+nsIAtom** nsHtml5AttributeName::ALL_NO_PREFIX = 0;
+nsIAtom** nsHtml5AttributeName::XMLNS_PREFIX = 0;
+nsIAtom** nsHtml5AttributeName::XLINK_PREFIX = 0;
+nsIAtom** nsHtml5AttributeName::XML_PREFIX = 0;
 nsIAtom** 
 nsHtml5AttributeName::SVG_DIFFERENT(nsIAtom* name, nsIAtom* camel)
 {
   nsIAtom** arr = new nsIAtom*[4];
   arr[0] = name;
   arr[1] = name;
   arr[2] = camel;
   return arr;
@@ -187,17 +195,600 @@ nsHtml5AttributeName::getPrefix(PRInt32 
 }
 
 PRBool 
 nsHtml5AttributeName::equalsAnother(nsHtml5AttributeName* another)
 {
   return this->getLocal(NS_HTML5ATTRIBUTE_NAME_HTML) == another->getLocal(NS_HTML5ATTRIBUTE_NAME_HTML);
 }
 
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_D = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_R = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_X = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_Y = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_Z = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_G2 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_G1 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K4 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K2 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K3 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K1 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ID = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_U2 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_U1 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TO = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_Y2 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_Y1 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_X1 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_X2 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DIR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DUR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_END = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IN2 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MAX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MIN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOW = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REV = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SRC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AXIS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ABBR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BBOX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CITE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CODE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BIAS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLIP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CHAR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EDGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATA = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FROM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FORM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HIGH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HREF = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OPEN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ICON = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NAME = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MODE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MASK = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LINK = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LANG = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LIST = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WHEN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WRAP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REFX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REFY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SEED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPAN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STEP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XREF = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ASYNC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALINK = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALIGN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLOSE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLASS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLEAR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BEGIN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DEPTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DEFER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FENCE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FRAME = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ISMAP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONEND = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_INDEX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ORDER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OTHER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCUT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NARGS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MEDIA = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LABEL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOCAL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WIDTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TITLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VLINK = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VALUE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SLOPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SHAPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCOPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCALE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPEED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STYLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RULES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STEMH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STEMV = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_START = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XMLNS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCEPT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCENT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ASCENT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACTIVE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALTIMG = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACTION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BORDER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CURSOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COORDS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILTER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FORMAT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HIDDEN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HEIGHT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOVE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONLOAD = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAG = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ORIGIN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONZOOM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONHELP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSTOP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDROP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBLUR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OBJECT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OFFSET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ORIENT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCOPY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOWRAP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOHREF = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MACROS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_METHOD = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOWSRC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LQUOTE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_USEMAP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WIDTHS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TARGET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VALUES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VALIGN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POSTER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PROMPT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCOPED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STRING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCHEME = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RADIUS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RESULT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROTATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RQUOTE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALTTEXT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARCHIVE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AZIMUTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLOSURE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CHECKED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLASSID = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CHAROFF = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BGCOLOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLSPAN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CHARSET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COMPACT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTENT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ENCTYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATASRC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATAFLD = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DECLARE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DISPLAY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DIVISOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DEFAULT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DESCENT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KERNING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HANGING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HEADERS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONPASTE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCLICK = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OPTIMUM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEGIN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONKEYUP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFOCUS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONERROR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONINPUT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONABORT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSTART = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONRESET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OPACITY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOSHADE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MINSIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MAXSIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOOPEND = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LARGEOP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNICODE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TARGETX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TARGETY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VIEWBOX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERSION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATTERN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PROFILE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPACING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RESTART = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWSPAN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SANDBOX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SUMMARY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STANDBY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPLACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AUTOPLAY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ADDITIVE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CALCMODE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CODETYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CODEBASE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTROLS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BEVELLED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASELINE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EXPONENT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EDGEMODE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ENCODING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPHREF = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATETIME = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DISABLED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONTSIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KEYTIMES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PANOSE_1 = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HREFLANG = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONRESIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCHANGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBOUNCE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONUNLOAD = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFINISH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSCROLL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OPERATOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OVERFLOW = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSUBMIT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONREPEAT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSELECT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOTATION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NORESIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MANIFEST = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHSIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MULTIPLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LONGDESC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LANGUAGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEMPLATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TABINDEX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_READONLY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SELECTED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWLINES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SEAMLESS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWALIGN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STRETCHY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REQUIRED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XML_BASE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XML_LANG = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_X_HEIGHT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_OWNS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AUTOFOCUS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_SORT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCESSKEY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_BUSY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_GRAB = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AMPLITUDE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_LIVE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLIP_RULE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLIP_PATH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EQUALROWS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ELEVATION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DIRECTION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DRAGGABLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILTERRES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILL_RULE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONTSTYLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_SIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KEYPOINTS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HIDEFOCUS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMESSAGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_INTERCEPT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGEND = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOVEEND = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONINVALID = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONKEYDOWN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFOCUSIN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEUP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_INPUTMODE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONROWEXIT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHCOLOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MASKUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MAXLENGTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LINEBREAK = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOOPSTART = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TRANSFORM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_V_HANGING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VALUETYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTSATZ = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTSATX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTSATY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PLAYCOUNT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SYMMETRIC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCROLLING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEATDUR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SELECTION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SEPARATOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XML_SPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AUTOSUBMIT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALPHABETIC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACTIONTYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCUMULATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_LEVEL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNSPAN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CAP_HEIGHT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BACKGROUND = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPH_NAME = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GROUPALIGN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONTFAMILY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONTWEIGHT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_STYLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KEYSPLINES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HTTP_EQUIV = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONACTIVATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OCCURRENCE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IRRELEVANT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDBLCLICK = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGDROP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONKEYPRESS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONROWENTER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGOVER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFOCUSOUT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEOUT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NUMOCTAVES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKER_MID = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKER_END = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXTLENGTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VISIBILITY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VIEWTARGET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERT_ADV_Y = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATHLENGTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT_MAX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RADIOGROUP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STOP_COLOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SEPARATORS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT_MIN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWSPACING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ZOOMANDPAN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_TYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_ROLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_HREF = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_SHOW = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCENTUNDER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_SECRET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_ATOMIC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_HIDDEN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_FLOWTO = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARABIC_FORM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CELLPADDING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CELLSPACING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNWIDTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNALIGN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNLINES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTEXTMENU = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASEPROFILE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_FAMILY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FRAMEBORDER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILTERUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FLOOD_COLOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_WEIGHT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HORIZ_ADV_X = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGLEAVE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEMOVE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ORIENTATION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEDOWN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEOVER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGENTER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IDEOGRAPHIC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFORECUT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFORMINPUT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGSTART = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOVESTART = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKERUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHVARIANT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARGINWIDTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKERWIDTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXT_ANCHOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TABLEVALUES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCRIPTLEVEL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEATCOUNT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STITCHTILES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STARTOFFSET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCROLLDELAY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XMLNS_XLINK = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_TITLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_INVALID = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_PRESSED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_CHECKED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AUTOCOMPLETE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_SETSIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_CHANNEL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EQUALCOLUMNS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DISPLAYSTYLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATAFORMATAS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILL_OPACITY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_VARIANT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_STRETCH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FRAMESPACING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KERNELMATRIX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDEACTIVATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONROWSDELETE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSELEAVE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFORMCHANGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCELLCHANGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEWHEEL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEENTER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONAFTERPRINT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFORECOPY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARGINHEIGHT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKERHEIGHT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKER_START = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHEMATICAL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LENGTHADJUST = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNSELECTABLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNICODE_BIDI = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNITS_PER_EM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WORD_SPACING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WRITING_MODE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_V_ALPHABETIC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATTERNUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPREADMETHOD = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SURFACESCALE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_WIDTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT_START = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STDDEVIATION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STOP_OPACITY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_CONTROLS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_HASPOPUP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCENT_HEIGHT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_VALUENOW = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_RELEVANT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_POSINSET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_VALUEMAX = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_READONLY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_SELECTED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_REQUIRED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_EXPANDED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_DISABLED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ATTRIBUTETYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ATTRIBUTENAME = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_DATATYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_VALUEMIN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASEFREQUENCY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNSPACING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_PROFILE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLIPPATHUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DEFINITIONURL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GRADIENTUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FLOOD_OPACITY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONAFTERUPDATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONERRORUPDATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREPASTE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONLOSECAPTURE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCONTEXTMENU = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSELECTSTART = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREPRINT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MOVABLELIMITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LINETHICKNESS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNICODE_RANGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_THINMATHSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERT_ORIGIN_X = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERT_ORIGIN_Y = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_V_IDEOGRAPHIC = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PRESERVEALPHA = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCRIPTMINSIZE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPECIFICATION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_ACTUATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_ARCROLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCEPT_CHARSET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALIGNMENTSCOPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_MULTILINE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASELINE_SHIFT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HORIZ_ORIGIN_X = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HORIZ_ORIGIN_Y = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREUPDATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFILTERCHANGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONROWSINSERTED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREUNLOAD = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHBACKGROUND = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LETTER_SPACING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LIGHTING_COLOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_THICKMATHSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXT_RENDERING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_V_MATHEMATICAL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTER_EVENTS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PRIMITIVEUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SYSTEMLANGUAGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_LINECAP = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SUBSCRIPTSHIFT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_OPACITY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_DROPEFFECT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_LABELLEDBY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_TEMPLATEID = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_RENDERING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTENTEDITABLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DIFFUSECONSTANT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDATAAVAILABLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCONTROLSELECT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IMAGE_RENDERING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MEDIUMMATHSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXT_DECORATION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SHAPE_RENDERING = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_LINEJOIN = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT_TEMPLATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_DESCRIBEDBY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTENTSTYLETYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_SIZE_ADJUST = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KERNELUNITLENGTH = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREACTIVATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONPROPERTYCHANGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDATASETCHANGED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MASKCONTENTUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATTERNTRANSFORM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REQUIREDFEATURES = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RENDERING_INTENT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPECULAREXPONENT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPECULARCONSTANT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SUPERSCRIPTSHIFT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_DASHARRAY = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XCHANNELSELECTOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_YCHANNELSELECTOR = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_AUTOCOMPLETE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTENTSCRIPTTYPE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ENABLE_BACKGROUND = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DOMINANT_BASELINE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GRADIENTTRANSFORM = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFORDEACTIVATE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDATASETCOMPLETE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OVERLINE_POSITION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREEDITFOCUS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LIMITINGCONEANGLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERYTHINMATHSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_DASHOFFSET = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_MITERLIMIT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALIGNMENT_BASELINE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONREADYSTATECHANGE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OVERLINE_THICKNESS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNDERLINE_POSITION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERYTHICKMATHSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REQUIREDEXTENSIONS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_INTERPOLATION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNDERLINE_THICKNESS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PRESERVEASPECTRATIO = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATTERNCONTENTUNITS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_MULTISELECTABLE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCRIPTSIZEMULTIPLIER = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_ACTIVEDESCENDANT = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERYVERYTHINMATHSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERYVERYTHICKMATHSPACE = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STRIKETHROUGH_POSITION = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STRIKETHROUGH_THICKNESS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EXTERNALRESOURCESREQUIRED = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPH_ORIENTATION_VERTICAL = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_INTERPOLATION_FILTERS = nsnull;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPH_ORIENTATION_HORIZONTAL = nsnull;
+nsHtml5AttributeName** nsHtml5AttributeName::ATTRIBUTE_NAMES = 0;
 static PRInt32 const ATTRIBUTE_HASHES_DATA[] = { 1153, 1383, 1601, 1793, 1827, 1857, 68600, 69146, 69177, 70237, 70270, 71572, 71669, 72415, 72444, 74846, 74904, 74943, 75001, 75276, 75590, 84742, 84839, 85575, 85963, 85992, 87204, 88074, 88171, 89130, 89163, 3207892, 3283895, 3284791, 3338752, 3358197, 3369562, 3539124, 3562402, 3574260, 3670335, 3696933, 3721879, 135280021, 135346322, 136317019, 136475749, 136548517, 136652214, 136884919, 136902418, 136942992, 137292068, 139120259, 139785574, 142250603, 142314056, 142331176, 142519584, 144752417, 145106895, 146147200, 146765926, 148805544, 149655723, 149809441, 150018784, 150445028, 150923321, 152528754, 152536216, 152647366, 152962785, 155219321, 155654904, 157317483, 157350248, 157437941, 157447478, 157604838, 157685404, 157894402, 158315188, 166078431, 169409980, 169700259, 169856932, 170007032, 170409695, 170466488, 170513710, 170608367, 173028944, 173896963, 176090625, 176129212, 179390001, 179489057, 179627464, 179840468, 179849042, 180004216, 181779081, 183027151, 183645319, 183698797, 185922012, 185997252, 188312483, 188675799, 190977533, 190992569, 191006194, 191033518, 191038774, 191096249, 191166163, 191194426, 191522106, 191568039, 200104642, 202506661, 202537381, 202602917, 203070590, 203120766, 203389054, 203690071, 203971238, 203986524, 209040857, 209125756, 212055489, 212322418, 212746849, 213002877, 213055164, 213088023, 213259873, 213273386, 213435118, 213437318, 213438231, 213493071, 213532268, 213542834, 213584431, 213659891, 215285828, 215880731, 216112976, 216684637, 217369699, 217565298, 217576549, 218186795, 219743185, 220082234, 221623802, 221986406, 222283890, 223089542, 223138630, 223311265, 224547358, 224587256, 224589550, 224655650, 224785518, 224810917, 224813302, 225429618, 225432950, 225440869, 236107233, 236709921, 236838947, 237117095, 237143271, 237172455, 237209953, 237354143, 237372743, 237668065, 237703073, 237714273, 239743521, 240512803, 240522627, 240560417, 240656513, 241015715, 241062755, 241065383, 243523041, 245865199, 246261793, 246556195, 246774817, 246923491, 246928419, 246981667, 247014847, 247058369, 247112833, 247118177, 247119137, 247128739, 247316903, 249533729, 250235623, 250269543, 251083937, 251402351, 252339047, 253260911, 253293679, 254844367, 255547879, 256077281, 256345377, 258124199, 258354465, 258605063, 258744193, 258845603, 258856961, 258926689, 269869248, 270174334, 270709417, 270778994, 270781796, 271102503, 271478858, 271490090, 272870654, 273335275, 273369140, 273924313, 274108530, 274116736, 276818662, 277476156, 279156579, 279349675, 280108533, 280128712, 280132869, 280162403, 280280292, 280413430, 280506130, 280677397, 280678580, 280686710, 280689066, 282736758, 283110901, 283275116, 283823226, 283890012, 284479340, 284606461, 286700477, 286798916, 291557706, 291665349, 291804100, 292138018, 292166446, 292418738, 292451039, 300298041, 300374839, 300597935, 303073389, 303083839, 303266673, 303354997, 303430688, 303576261, 303724281, 303819694, 304242723, 304382625, 306247792, 307227811, 307468786, 307724489, 309671175, 310252031, 310358241, 310373094, 311015256, 313357609, 313683893, 313701861, 313706996, 313707317, 313710350, 314027746, 314038181, 314091299, 314205627, 314233813, 316741830, 316797986, 317486755, 317794164, 318721061, 320076137, 322657125, 322887778, 323506876, 323572412, 323605180, 323938869, 325060058, 325320188, 325398738, 325541490, 325671619, 333868843, 336806130, 337212108, 337282686, 337285434, 337585223, 338036037, 338298087, 338566051, 340943551, 341190970, 342995704, 343352124, 343912673, 344585053, 346977248, 347218098, 347262163, 347278576, 347438191, 347655959, 347684788, 347726430, 347727772, 347776035, 347776629, 349500753, 350880161, 350887073, 353384123, 355496998, 355906922, 355979793, 356545959, 358637867, 358905016, 359164318, 359247286, 359350571, 359579447, 365560330, 367399355, 367420285, 367510727, 368013212, 370234760, 370353345, 370710317, 371074566, 371122285, 371194213, 371448425, 371448430, 371545055, 371596922, 371758751, 371964792, 372151328, 376550136, 376710172, 376795771, 376826271, 376906556, 380514830, 380774774, 380775037, 381030322, 381136500, 381281631, 381282269, 381285504, 381330595, 381331422, 381335911, 381336484, 383907298, 383917408, 384595009, 384595013, 387799894, 387823201, 392581647, 392584937, 392742684, 392906485, 393003349, 400644707, 400973830, 404428547, 404432113, 404432865, 404469244, 404478897, 404694860, 406887479, 408294949, 408789955, 410022510, 410467324, 410586448, 410945965, 411845275, 414327152, 414327932, 414329781, 414346257, 414346439, 414639928, 414835998, 414894517, 414986533, 417465377, 417465381, 417492216, 418259232, 419310946, 420103495, 420242342, 420380455, 420658662, 420717432, 423183880, 424539259, 425929170, 425972964, 426050649, 426126450, 426142833, 426607922, 437289840, 437347469, 437412335, 437423943, 437455540, 437462252, 437597991, 437617485, 437986305, 437986507, 437986828, 437987072, 438015591, 438034813, 438038966, 438179623, 438347971, 438483573, 438547062, 438895551, 441592676, 442032555, 443548979, 447881379, 447881655, 447881895, 447887844, 448416189, 448445746, 448449012, 450942191, 452816744, 453668677, 454434495, 456610076, 456642844, 456738709, 457544600, 459451897, 459680944, 468058810, 468083581, 470964084, 471470955, 471567278, 472267822, 481177859, 481210627, 481435874, 481455115, 481485378, 481490218, 485105638, 486005878, 486383494, 487988916, 488103783, 490661867, 491574090, 491578272, 493041952, 493441205, 493582844, 493716979, 504577572, 504740359, 505091638, 505592418, 505656212, 509516275, 514998531, 515571132, 515594682, 518712698, 521362273, 526592419, 526807354, 527348842, 538294791, 539214049, 544689535, 545535009, 548544752, 548563346, 548595116, 551679010, 558034099, 560329411, 560356209, 560671018, 560671152, 560692590, 560845442, 569212097, 569474241, 572252718, 572768481, 575326764, 576174758, 576190819, 582099184, 582099438, 582372519, 582558889, 586552164, 591325418, 594231990, 594243961, 605711268, 615672071, 616086845, 621792370, 624879850, 627432831, 640040548, 654392808, 658675477, 659420283, 672891587, 694768102, 705890982, 725543146, 759097578, 761686526, 795383908, 843809551, 878105336, 908643300, 945213471 };
+staticJArray<PRInt32,PRInt32> nsHtml5AttributeName::ATTRIBUTE_HASHES = { ATTRIBUTE_HASHES_DATA, NS_ARRAY_LENGTH(ATTRIBUTE_HASHES_DATA) };
 void
 nsHtml5AttributeName::initializeStatics()
 {
   ALL_NO_NS = new PRInt32[3];
   ALL_NO_NS[0] = kNameSpaceID_None;
   ALL_NO_NS[1] = kNameSpaceID_None;
   ALL_NO_NS[2] = kNameSpaceID_None;
   XMLNS_NS = new PRInt32[3];
@@ -1386,17 +1977,16 @@ nsHtml5AttributeName::initializeStatics(
   ATTRIBUTE_NAMES[573] = ATTR_VERYVERYTHINMATHSPACE;
   ATTRIBUTE_NAMES[574] = ATTR_VERYVERYTHICKMATHSPACE;
   ATTRIBUTE_NAMES[575] = ATTR_STRIKETHROUGH_POSITION;
   ATTRIBUTE_NAMES[576] = ATTR_STRIKETHROUGH_THICKNESS;
   ATTRIBUTE_NAMES[577] = ATTR_EXTERNALRESOURCESREQUIRED;
   ATTRIBUTE_NAMES[578] = ATTR_GLYPH_ORIENTATION_VERTICAL;
   ATTRIBUTE_NAMES[579] = ATTR_COLOR_INTERPOLATION_FILTERS;
   ATTRIBUTE_NAMES[580] = ATTR_GLYPH_ORIENTATION_HORIZONTAL;
-  ATTRIBUTE_HASHES = jArray<PRInt32,PRInt32>((PRInt32*)ATTRIBUTE_HASHES_DATA, 581);
 }
 
 void
 nsHtml5AttributeName::releaseStatics()
 {
   delete[] ALL_NO_NS;
   delete[] XMLNS_NS;
   delete[] XML_NS;
--- a/parser/html/nsHtml5AttributeName.h
+++ b/parser/html/nsHtml5AttributeName.h
@@ -674,615 +674,21 @@ class nsHtml5AttributeName
     static nsHtml5AttributeName* ATTR_STRIKETHROUGH_POSITION;
     static nsHtml5AttributeName* ATTR_STRIKETHROUGH_THICKNESS;
     static nsHtml5AttributeName* ATTR_EXTERNALRESOURCESREQUIRED;
     static nsHtml5AttributeName* ATTR_GLYPH_ORIENTATION_VERTICAL;
     static nsHtml5AttributeName* ATTR_COLOR_INTERPOLATION_FILTERS;
     static nsHtml5AttributeName* ATTR_GLYPH_ORIENTATION_HORIZONTAL;
   private:
     static nsHtml5AttributeName** ATTRIBUTE_NAMES;
-    static jArray<PRInt32,PRInt32> ATTRIBUTE_HASHES;
+    static staticJArray<PRInt32,PRInt32> ATTRIBUTE_HASHES;
   public:
     static void initializeStatics();
     static void releaseStatics();
 };
 
-#ifdef nsHtml5AttributeName_cpp__
-PRInt32* nsHtml5AttributeName::ALL_NO_NS = nsnull;
-PRInt32* nsHtml5AttributeName::XMLNS_NS = nsnull;
-PRInt32* nsHtml5AttributeName::XML_NS = nsnull;
-PRInt32* nsHtml5AttributeName::XLINK_NS = nsnull;
-nsIAtom** nsHtml5AttributeName::ALL_NO_PREFIX = nsnull;
-nsIAtom** nsHtml5AttributeName::XMLNS_PREFIX = nsnull;
-nsIAtom** nsHtml5AttributeName::XLINK_PREFIX = nsnull;
-nsIAtom** nsHtml5AttributeName::XML_PREFIX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_D = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_R = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_X = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_Y = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_Z = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_G2 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_G1 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K4 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K2 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K3 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_K1 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ID = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_U2 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_U1 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TO = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_Y2 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_Y1 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_X1 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_X2 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DIR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DUR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_END = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IN2 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MAX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MIN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOW = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REV = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SRC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AXIS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ABBR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BBOX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CITE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CODE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BIAS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLIP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CHAR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EDGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATA = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FROM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FORM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HIGH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HREF = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OPEN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ICON = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NAME = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MODE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MASK = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LINK = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LANG = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LIST = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WHEN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WRAP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REFX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REFY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SEED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPAN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STEP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XREF = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ASYNC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALINK = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALIGN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLOSE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLASS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLEAR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BEGIN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DEPTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DEFER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FENCE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FRAME = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ISMAP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONEND = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_INDEX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ORDER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OTHER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCUT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NARGS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MEDIA = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LABEL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOCAL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WIDTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TITLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VLINK = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VALUE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SLOPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SHAPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCOPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCALE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPEED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STYLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RULES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STEMH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STEMV = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_START = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XMLNS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCEPT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCENT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ASCENT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACTIVE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALTIMG = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACTION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BORDER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CURSOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COORDS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILTER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FORMAT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HIDDEN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HEIGHT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOVE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONLOAD = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAG = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ORIGIN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONZOOM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONHELP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSTOP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDROP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBLUR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OBJECT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OFFSET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ORIENT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCOPY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOWRAP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOHREF = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MACROS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_METHOD = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOWSRC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LQUOTE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_USEMAP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WIDTHS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TARGET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VALUES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VALIGN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POSTER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PROMPT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCOPED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STRING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCHEME = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RADIUS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RESULT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROTATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RQUOTE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALTTEXT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARCHIVE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AZIMUTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLOSURE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CHECKED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLASSID = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CHAROFF = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BGCOLOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLSPAN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CHARSET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COMPACT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTENT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ENCTYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATASRC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATAFLD = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DECLARE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DISPLAY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DIVISOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DEFAULT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DESCENT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KERNING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HANGING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HEADERS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONPASTE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCLICK = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OPTIMUM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEGIN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONKEYUP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFOCUS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONERROR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONINPUT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONABORT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSTART = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONRESET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OPACITY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOSHADE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MINSIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MAXSIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOOPEND = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LARGEOP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNICODE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TARGETX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TARGETY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VIEWBOX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERSION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATTERN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PROFILE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPACING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RESTART = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWSPAN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SANDBOX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SUMMARY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STANDBY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPLACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AUTOPLAY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ADDITIVE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CALCMODE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CODETYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CODEBASE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTROLS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BEVELLED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASELINE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EXPONENT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EDGEMODE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ENCODING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPHREF = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATETIME = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DISABLED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONTSIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KEYTIMES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PANOSE_1 = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HREFLANG = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONRESIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCHANGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBOUNCE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONUNLOAD = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFINISH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSCROLL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OPERATOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OVERFLOW = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSUBMIT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONREPEAT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSELECT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOTATION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NORESIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MANIFEST = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHSIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MULTIPLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LONGDESC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LANGUAGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEMPLATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TABINDEX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_READONLY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SELECTED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWLINES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SEAMLESS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWALIGN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STRETCHY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REQUIRED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XML_BASE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XML_LANG = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_X_HEIGHT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_OWNS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AUTOFOCUS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_SORT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCESSKEY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_BUSY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_GRAB = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AMPLITUDE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_LIVE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLIP_RULE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLIP_PATH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EQUALROWS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ELEVATION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DIRECTION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DRAGGABLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILTERRES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILL_RULE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONTSTYLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_SIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KEYPOINTS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HIDEFOCUS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMESSAGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_INTERCEPT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGEND = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOVEEND = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONINVALID = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONKEYDOWN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFOCUSIN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEUP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_INPUTMODE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONROWEXIT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHCOLOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MASKUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MAXLENGTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LINEBREAK = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LOOPSTART = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TRANSFORM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_V_HANGING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VALUETYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTSATZ = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTSATX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTSATY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PLAYCOUNT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SYMMETRIC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCROLLING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEATDUR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SELECTION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SEPARATOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XML_SPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AUTOSUBMIT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALPHABETIC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACTIONTYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCUMULATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_LEVEL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNSPAN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CAP_HEIGHT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BACKGROUND = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPH_NAME = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GROUPALIGN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONTFAMILY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONTWEIGHT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_STYLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KEYSPLINES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HTTP_EQUIV = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONACTIVATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OCCURRENCE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IRRELEVANT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDBLCLICK = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGDROP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONKEYPRESS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONROWENTER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGOVER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFOCUSOUT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEOUT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NUMOCTAVES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKER_MID = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKER_END = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXTLENGTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VISIBILITY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VIEWTARGET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERT_ADV_Y = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATHLENGTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT_MAX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RADIOGROUP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STOP_COLOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SEPARATORS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT_MIN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ROWSPACING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ZOOMANDPAN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_TYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_ROLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_HREF = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_SHOW = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCENTUNDER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_SECRET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_ATOMIC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_HIDDEN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_FLOWTO = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARABIC_FORM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CELLPADDING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CELLSPACING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNWIDTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNALIGN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNLINES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTEXTMENU = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASEPROFILE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_FAMILY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FRAMEBORDER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILTERUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FLOOD_COLOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_WEIGHT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HORIZ_ADV_X = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGLEAVE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEMOVE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ORIENTATION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEDOWN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEOVER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGENTER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IDEOGRAPHIC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFORECUT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFORMINPUT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDRAGSTART = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOVESTART = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKERUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHVARIANT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARGINWIDTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKERWIDTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXT_ANCHOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TABLEVALUES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCRIPTLEVEL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEATCOUNT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STITCHTILES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STARTOFFSET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCROLLDELAY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XMLNS_XLINK = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_TITLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_INVALID = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_PRESSED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_CHECKED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_AUTOCOMPLETE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_SETSIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_CHANNEL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EQUALCOLUMNS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DISPLAYSTYLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DATAFORMATAS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FILL_OPACITY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_VARIANT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_STRETCH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FRAMESPACING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KERNELMATRIX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDEACTIVATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONROWSDELETE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSELEAVE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFORMCHANGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCELLCHANGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEWHEEL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONMOUSEENTER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONAFTERPRINT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFORECOPY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARGINHEIGHT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKERHEIGHT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MARKER_START = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHEMATICAL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LENGTHADJUST = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNSELECTABLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNICODE_BIDI = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNITS_PER_EM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WORD_SPACING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_WRITING_MODE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_V_ALPHABETIC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATTERNUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPREADMETHOD = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SURFACESCALE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_WIDTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT_START = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STDDEVIATION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STOP_OPACITY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_CONTROLS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_HASPOPUP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCENT_HEIGHT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_VALUENOW = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_RELEVANT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_POSINSET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_VALUEMAX = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_READONLY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_SELECTED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_REQUIRED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_EXPANDED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_DISABLED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ATTRIBUTETYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ATTRIBUTENAME = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_DATATYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_VALUEMIN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASEFREQUENCY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLUMNSPACING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_PROFILE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CLIPPATHUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DEFINITIONURL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GRADIENTUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FLOOD_OPACITY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONAFTERUPDATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONERRORUPDATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREPASTE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONLOSECAPTURE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCONTEXTMENU = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSELECTSTART = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREPRINT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MOVABLELIMITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LINETHICKNESS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNICODE_RANGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_THINMATHSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERT_ORIGIN_X = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERT_ORIGIN_Y = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_V_IDEOGRAPHIC = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PRESERVEALPHA = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCRIPTMINSIZE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPECIFICATION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_ACTUATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XLINK_ARCROLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ACCEPT_CHARSET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALIGNMENTSCOPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_MULTILINE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_BASELINE_SHIFT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HORIZ_ORIGIN_X = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_HORIZ_ORIGIN_Y = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREUPDATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONFILTERCHANGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONROWSINSERTED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREUNLOAD = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHBACKGROUND = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LETTER_SPACING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LIGHTING_COLOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_THICKMATHSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXT_RENDERING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_V_MATHEMATICAL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_POINTER_EVENTS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PRIMITIVEUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SYSTEMLANGUAGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_LINECAP = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SUBSCRIPTSHIFT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_OPACITY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_DROPEFFECT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_LABELLEDBY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_TEMPLATEID = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_RENDERING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTENTEDITABLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DIFFUSECONSTANT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDATAAVAILABLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONCONTROLSELECT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_IMAGE_RENDERING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MEDIUMMATHSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_TEXT_DECORATION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SHAPE_RENDERING = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_LINEJOIN = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REPEAT_TEMPLATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_DESCRIBEDBY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTENTSTYLETYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_FONT_SIZE_ADJUST = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_KERNELUNITLENGTH = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREACTIVATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONPROPERTYCHANGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDATASETCHANGED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MASKCONTENTUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATTERNTRANSFORM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REQUIREDFEATURES = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_RENDERING_INTENT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPECULAREXPONENT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SPECULARCONSTANT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SUPERSCRIPTSHIFT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_DASHARRAY = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_XCHANNELSELECTOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_YCHANNELSELECTOR = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_AUTOCOMPLETE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_CONTENTSCRIPTTYPE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ENABLE_BACKGROUND = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_DOMINANT_BASELINE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GRADIENTTRANSFORM = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFORDEACTIVATE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONDATASETCOMPLETE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OVERLINE_POSITION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONBEFOREEDITFOCUS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_LIMITINGCONEANGLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERYTHINMATHSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_DASHOFFSET = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STROKE_MITERLIMIT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ALIGNMENT_BASELINE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONREADYSTATECHANGE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_OVERLINE_THICKNESS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNDERLINE_POSITION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERYTHICKMATHSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_REQUIREDEXTENSIONS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_INTERPOLATION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_UNDERLINE_THICKNESS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PRESERVEASPECTRATIO = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_PATTERNCONTENTUNITS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_MULTISELECTABLE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_SCRIPTSIZEMULTIPLIER = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ARIA_ACTIVEDESCENDANT = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERYVERYTHINMATHSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_VERYVERYTHICKMATHSPACE = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STRIKETHROUGH_POSITION = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_STRIKETHROUGH_THICKNESS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_EXTERNALRESOURCESREQUIRED = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPH_ORIENTATION_VERTICAL = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_INTERPOLATION_FILTERS = nsnull;
-nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPH_ORIENTATION_HORIZONTAL = nsnull;
-nsHtml5AttributeName** nsHtml5AttributeName::ATTRIBUTE_NAMES = nsnull;
-jArray<PRInt32,PRInt32> nsHtml5AttributeName::ATTRIBUTE_HASHES = 0;
-#endif
-
 #define NS_HTML5ATTRIBUTE_NAME_HTML 0
 #define NS_HTML5ATTRIBUTE_NAME_MATHML 1
 #define NS_HTML5ATTRIBUTE_NAME_SVG 2
 
 
 #endif
 
--- a/parser/html/nsHtml5ElementName.cpp
+++ b/parser/html/nsHtml5ElementName.cpp
@@ -54,35 +54,36 @@
 #include "nsHtml5StackNode.h"
 #include "nsHtml5UTF16Buffer.h"
 #include "nsHtml5StateSnapshot.h"
 #include "nsHtml5Portability.h"
 
 #include "nsHtml5ElementName.h"
 #include "nsHtml5ReleasableElementName.h"
 
+nsHtml5ElementName* nsHtml5ElementName::ELT_NULL_ELEMENT_NAME = nsnull;
 nsHtml5ElementName* 
-nsHtml5ElementName::elementNameByBuffer(jArray<PRUnichar,PRInt32> buf, PRInt32 offset, PRInt32 length, nsHtml5AtomTable* interner)
+nsHtml5ElementName::elementNameByBuffer(PRUnichar* buf, PRInt32 offset, PRInt32 length, nsHtml5AtomTable* interner)
 {
   PRInt32 hash = nsHtml5ElementName::bufToHash(buf, length);
   PRInt32 index = nsHtml5ElementName::ELEMENT_HASHES.binarySearch(hash);
   if (index < 0) {
     return new nsHtml5ReleasableElementName(nsHtml5Portability::newLocalNameFromBuffer(buf, offset, length, interner));
   } else {
     nsHtml5ElementName* elementName = nsHtml5ElementName::ELEMENT_NAMES[index];
     nsIAtom* name = elementName->name;
     if (!nsHtml5Portability::localEqualsBuffer(name, buf, offset, length)) {
       return new nsHtml5ReleasableElementName(nsHtml5Portability::newLocalNameFromBuffer(buf, offset, length, interner));
     }
     return elementName;
   }
 }
 
 PRInt32 
-nsHtml5ElementName::bufToHash(jArray<PRUnichar,PRInt32> buf, PRInt32 len)
+nsHtml5ElementName::bufToHash(PRUnichar* buf, PRInt32 len)
 {
   PRInt32 hash = len;
   hash <<= 5;
   hash += buf[0] - 0x60;
   PRInt32 j = len;
   for (PRInt32 i = 0; i < 4 && j > 0; i++) {
     j--;
     hash <<= 5;
@@ -128,17 +129,408 @@ nsHtml5ElementName::~nsHtml5ElementName(
 }
 
 nsHtml5ElementName* 
 nsHtml5ElementName::cloneElementName(nsHtml5AtomTable* interner)
 {
   return this;
 }
 
+nsHtml5ElementName* nsHtml5ElementName::ELT_A = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_B = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_G = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_I = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_P = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_Q = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_S = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_U = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CI = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EQ = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_H1 = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_H2 = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_H3 = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_H4 = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_H5 = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_H6 = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_GT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_HR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_IN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LI = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MI = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MO = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_OL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_OR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PI = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_RP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_RT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_UL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_AND = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARG = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ABS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BIG = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BDO = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CSC = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DEL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DFN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DIR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DIV = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EXP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_GCD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_GEQ = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_IMG = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_INS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_INT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_KBD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LOG = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LCM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LEQ = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MTD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MIN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MAP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MTR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MAX = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NEQ = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NAV = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PRE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_REM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SUB = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SEC = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SVG = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SUM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SIN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SEP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SUP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TAN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_USE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_VAR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_WBR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_XMP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_XOR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_AREA = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ABBR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BASE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BVAR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BODY = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CARD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CODE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CITE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CSCH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COSH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COTH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CURL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DESC = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DIFF = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DEFS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FORM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FONT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_GRAD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_HEAD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_HTML = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LINE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LINK = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LIST = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_META = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MSUB = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MODE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MATH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MARK = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MASK = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MEAN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MSUP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MENU = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MROW = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NONE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOBR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NEST = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PATH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PLUS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_RULE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_REAL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_RELN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_RECT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ROOT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_RUBY = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SECH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SINH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SPAN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SAMP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_STOP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SDEV = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TIME = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TRUE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TREF = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TANH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TEXT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_VIEW = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ASIDE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_AUDIO = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_APPLY = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EMBED = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FRAME = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FALSE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FLOOR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_GLYPH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_HKERN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_IMAGE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_IDENT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_INPUT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LABEL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LIMIT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MFRAC = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MPATH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_METER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MOVER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MINUS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MROOT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MSQRT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MTEXT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOTIN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PIECE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PARAM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_POWER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_REALS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_STYLE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SMALL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_THEAD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TABLE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TITLE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TSPAN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TIMES = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TFOOT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TBODY = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_UNION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_VKERN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_VIDEO = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCSEC = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCSC = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCTAN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCSIN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCOS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_APPLET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCOT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_APPROX = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BUTTON = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CIRCLE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CENTER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CURSOR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CANVAS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DIVIDE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DEGREE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DOMAIN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EXISTS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FETILE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FIGURE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FORALL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FILTER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FOOTER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_HGROUP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_HEADER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_IFRAME = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_KEYGEN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LAMBDA = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LEGEND = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MSPACE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MTABLE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MSTYLE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MGLYPH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MEDIAN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MUNDER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MARKER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MERROR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MOMENT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MATRIX = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_OPTION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_OBJECT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_OUTPUT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PRIMES = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SOURCE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_STRIKE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_STRONG = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SWITCH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SYMBOL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SELECT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SUBSET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SCRIPT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TBREAK = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_VECTOR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARTICLE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCSECH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCSCH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCTANH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCSINH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCOSH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCOTH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ACRONYM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ADDRESS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BGSOUND = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COMMAND = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COMPOSE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CEILING = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CSYMBOL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CAPTION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DISCARD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DECLARE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DETAILS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ELLIPSE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEFUNCA = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEFUNCB = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEBLEND = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEFLOOD = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEIMAGE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEMERGE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEFUNCG = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEFUNCR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_HANDLER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_INVERSE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_IMPLIES = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ISINDEX = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LOGBASE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LISTING = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MFENCED = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MPADDED = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MARQUEE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MACTION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MSUBSUP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOEMBED = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_POLYGON = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PATTERN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PRODUCT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SETDIFF = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SECTION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TENDSTO = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_UPLIMIT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ALTGLYPH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BASEFONT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CLIPPATH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CODOMAIN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COLGROUP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DATAGRID = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EMPTYSET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FACTOROF = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FIELDSET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FRAMESET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEOFFSET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_GLYPHREF = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_INTERVAL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_INTEGERS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_INFINITY = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LISTENER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LOWLIMIT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_METADATA = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MENCLOSE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MPHANTOM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOFRAMES = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOSCRIPT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_OPTGROUP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_POLYLINE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PREFETCH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PROGRESS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PRSUBSET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_QUOTIENT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SELECTOR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TEXTAREA = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TEXTPATH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_VARIANCE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CONJUGATE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CONDITION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COMPLEXES = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FACTORIAL = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_INTERSECT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_IMAGINARY = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LAPLACIAN = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MATRIXROW = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOTSUBSET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_OTHERWISE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PIECEWISE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PLAINTEXT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_RATIONALS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SEMANTICS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_TRANSPOSE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ANNOTATION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_BLOCKQUOTE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DIVERGENCE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EULERGAMMA = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EQUIVALENT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_IMAGINARYI = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MALIGNMARK = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MUNDEROVER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MLABELEDTR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOTANUMBER = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SOLIDCOLOR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ALTGLYPHDEF = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DETERMINANT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEMERGENODE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FECOMPOSITE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FESPOTLIGHT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MALIGNGROUP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MPRESCRIPTS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MOMENTABOUT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NOTPRSUBSET = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_PARTIALDIFF = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ALTGLYPHITEM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATECOLOR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DATATEMPLATE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_EXPONENTIALE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FETURBULENCE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEPOINTLIGHT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEMORPHOLOGY = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_OUTERPRODUCT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATEMOTION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_COLOR_PROFILE = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE_SRC = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE_URI = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FOREIGNOBJECT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FECOLORMATRIX = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MISSING_GLYPH = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_MMULTISCRIPTS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_SCALARPRODUCT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_VECTORPRODUCT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ANNOTATION_XML = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DEFINITION_SRC = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE_NAME = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEGAUSSIANBLUR = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEDISTANTLIGHT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_LINEARGRADIENT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_NATURALNUMBERS = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_RADIALGRADIENT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATETRANSFORM = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_CARTESIANPRODUCT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE_FORMAT = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FECONVOLVEMATRIX = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEDIFFUSELIGHTING = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FEDISPLACEMENTMAP = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FESPECULARLIGHTING = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_DOMAINOFAPPLICATION = nsnull;
+nsHtml5ElementName* nsHtml5ElementName::ELT_FECOMPONENTTRANSFER = nsnull;
+nsHtml5ElementName** nsHtml5ElementName::ELEMENT_NAMES = 0;
 static PRInt32 const ELEMENT_HASHES_DATA[] = { 1057, 1090, 1255, 1321, 1552, 1585, 1651, 1717, 68162, 68899, 69059, 69764, 70020, 70276, 71077, 71205, 72134, 72232, 72264, 72296, 72328, 72360, 72392, 73351, 74312, 75209, 78124, 78284, 78476, 79149, 79309, 79341, 79469, 81295, 81487, 82224, 84498, 84626, 86164, 86292, 86612, 86676, 87445, 3183041, 3186241, 3198017, 3218722, 3226754, 3247715, 3256803, 3263971, 3264995, 3289252, 3291332, 3295524, 3299620, 3326725, 3379303, 3392679, 3448233, 3460553, 3461577, 3510347, 3546604, 3552364, 3556524, 3576461, 3586349, 3588141, 3590797, 3596333, 3622062, 3625454, 3627054, 3675728, 3749042, 3771059, 3771571, 3776211, 3782323, 3782963, 3784883, 3785395, 3788979, 3815476, 3839605, 3885110, 3917911, 3948984, 3951096, 135304769, 135858241, 136498210, 136906434, 137138658, 137512995, 137531875, 137548067, 137629283, 137645539, 137646563, 137775779, 138529956, 138615076, 139040932, 140954086, 141179366, 141690439, 142738600, 143013512, 146979116, 147175724, 147475756, 147902637, 147936877, 148017645, 148131885, 148228141, 148229165, 148309165, 148395629, 148551853, 148618829, 149076462, 149490158, 149572782, 151277616, 151639440, 153268914, 153486514, 153563314, 153750706, 153763314, 153914034, 154406067, 154417459, 154600979, 154678323, 154680979, 154866835, 155366708, 155375188, 155391572, 155465780, 155869364, 158045494, 168988979, 169321621, 169652752, 173151309, 174240818, 174247297, 174669292, 175391532, 176638123, 177380397, 177879204, 177886734, 180753473, 181020073, 181503558, 181686320, 181999237, 181999311, 182048201, 182074866, 182078003, 182083764, 182920847, 184716457, 184976961, 185145071, 187281445, 187872052, 188100653, 188875944, 188919873, 188920457, 189203987, 189371817, 189414886, 189567458, 190266670, 191318187, 191337609, 202479203, 202493027, 202835587, 202843747, 203013219, 203036048, 203045987, 203177552, 203898516, 204648562, 205067918, 205078130, 205096654, 205689142, 205690439, 205988909, 207213161, 207794484, 207800999, 208023602, 208213644, 208213647, 210261490, 210310273, 210940978, 213325049, 213946445, 214055079, 215125040, 215134273, 215135028, 215237420, 215418148, 215553166, 215553394, 215563858, 215627949, 215754324, 217529652, 217713834, 217732628, 218731945, 221417045, 221424946, 221493746, 221515401, 221658189, 221908140, 221910626, 221921586, 222659762, 225001091, 236105833, 236113965, 236194995, 236195427, 236206132, 236206387, 236211683, 236212707, 236381647, 236571826, 237124271, 238172205, 238210544, 238270764, 238435405, 238501172, 239224867, 239257644, 239710497, 240307721, 241208789, 241241557, 241318060, 241319404, 241343533, 241344069, 241405397, 241765845, 243864964, 244502085, 244946220, 245109902, 247647266, 247707956, 248648814, 248648836, 248682161, 248986932, 249058914, 249697357, 252132601, 252135604, 252317348, 255007012, 255278388, 256365156, 257566121, 269763372, 271202790, 271863856, 272049197, 272127474, 272770631, 274339449, 274939471, 275388004, 275388005, 275388006, 275977800, 278267602, 278513831, 278712622, 281613765, 281683369, 282120228, 282250732, 282508942, 283743649, 283787570, 284710386, 285391148, 285478533, 285854898, 285873762, 286931113, 288964227, 289445441, 289689648, 291671489, 303512884, 305319975, 305610036, 305764101, 308448294, 308675890, 312085683, 312264750, 315032867, 316391000, 317331042, 317902135, 318950711, 319447220, 321499182, 322538804, 323145200, 337067316, 337826293, 339905989, 340833697, 341457068, 345302593, 349554733, 349771471, 349786245, 350819405, 356072847, 370349192, 373962798, 375558638, 375574835, 376053993, 383276530, 383373833, 383407586, 384439906, 386079012, 404133513, 404307343, 407031852, 408072233, 409112005, 409608425, 409771500, 419040932, 437730612, 439529766, 442616365, 442813037, 443157674, 443295316, 450118444, 450482697, 456789668, 459935396, 471217869, 474073645, 476230702, 476665218, 476717289, 483014825, 485083298, 489306281, 538364390, 540675748, 543819186, 543958612, 576960820, 577242548, 610515252, 642202932, 644420819 };
+staticJArray<PRInt32,PRInt32> nsHtml5ElementName::ELEMENT_HASHES = { ELEMENT_HASHES_DATA, NS_ARRAY_LENGTH(ELEMENT_HASHES_DATA) };
 void
 nsHtml5ElementName::initializeStatics()
 {
   ELT_NULL_ELEMENT_NAME = new nsHtml5ElementName(nsnull);
   ELT_A = new nsHtml5ElementName(nsHtml5Atoms::a, nsHtml5Atoms::a, NS_HTML5TREE_BUILDER_A, PR_FALSE, PR_FALSE, PR_FALSE);
   ELT_B = new nsHtml5ElementName(nsHtml5Atoms::b, nsHtml5Atoms::b, NS_HTML5TREE_BUILDER_B_OR_BIG_OR_CODE_OR_EM_OR_I_OR_S_OR_SMALL_OR_STRIKE_OR_STRONG_OR_TT_OR_U, PR_FALSE, PR_FALSE, PR_FALSE);
   ELT_G = new nsHtml5ElementName(nsHtml5Atoms::g, nsHtml5Atoms::g, NS_HTML5TREE_BUILDER_OTHER, PR_FALSE, PR_FALSE, PR_FALSE);
   ELT_I = new nsHtml5ElementName(nsHtml5Atoms::i, nsHtml5Atoms::i, NS_HTML5TREE_BUILDER_B_OR_BIG_OR_CODE_OR_EM_OR_I_OR_S_OR_SMALL_OR_STRIKE_OR_STRONG_OR_TT_OR_U, PR_FALSE, PR_FALSE, PR_FALSE);
@@ -912,17 +1304,16 @@ nsHtml5ElementName::initializeStatics()
   ELEMENT_NAMES[381] = ELT_CARTESIANPRODUCT;
   ELEMENT_NAMES[382] = ELT_FONT_FACE_FORMAT;
   ELEMENT_NAMES[383] = ELT_FECONVOLVEMATRIX;
   ELEMENT_NAMES[384] = ELT_FEDIFFUSELIGHTING;
   ELEMENT_NAMES[385] = ELT_FEDISPLACEMENTMAP;
   ELEMENT_NAMES[386] = ELT_FESPECULARLIGHTING;
   ELEMENT_NAMES[387] = ELT_DOMAINOFAPPLICATION;
   ELEMENT_NAMES[388] = ELT_FECOMPONENTTRANSFER;
-  ELEMENT_HASHES = jArray<PRInt32,PRInt32>((PRInt32*)ELEMENT_HASHES_DATA, 389);
 }
 
 void
 nsHtml5ElementName::releaseStatics()
 {
   delete ELT_NULL_ELEMENT_NAME;
   delete ELT_A;
   delete ELT_B;
--- a/parser/html/nsHtml5ElementName.h
+++ b/parser/html/nsHtml5ElementName.h
@@ -64,19 +64,19 @@ class nsHtml5ElementName
   public:
     static nsHtml5ElementName* ELT_NULL_ELEMENT_NAME;
     nsIAtom* name;
     nsIAtom* camelCaseName;
     PRInt32 group;
     PRBool special;
     PRBool scoping;
     PRBool fosterParenting;
-    static nsHtml5ElementName* elementNameByBuffer(jArray<PRUnichar,PRInt32> buf, PRInt32 offset, PRInt32 length, nsHtml5AtomTable* interner);
+    static nsHtml5ElementName* elementNameByBuffer(PRUnichar* buf, PRInt32 offset, PRInt32 length, nsHtml5AtomTable* interner);
   private:
-    static PRInt32 bufToHash(jArray<PRUnichar,PRInt32> buf, PRInt32 len);
+    static PRInt32 bufToHash(PRUnichar* buf, PRInt32 len);
     nsHtml5ElementName(nsIAtom* name, nsIAtom* camelCaseName, PRInt32 group, PRBool special, PRBool scoping, PRBool fosterParenting);
   protected:
     nsHtml5ElementName(nsIAtom* name);
   public:
     virtual void release();
     ~nsHtml5ElementName();
     virtual nsHtml5ElementName* cloneElementName(nsHtml5AtomTable* interner);
     static nsHtml5ElementName* ELT_A;
@@ -465,413 +465,18 @@ class nsHtml5ElementName
     static nsHtml5ElementName* ELT_FECONVOLVEMATRIX;
     static nsHtml5ElementName* ELT_FEDIFFUSELIGHTING;
     static nsHtml5ElementName* ELT_FEDISPLACEMENTMAP;
     static nsHtml5ElementName* ELT_FESPECULARLIGHTING;
     static nsHtml5ElementName* ELT_DOMAINOFAPPLICATION;
     static nsHtml5ElementName* ELT_FECOMPONENTTRANSFER;
   private:
     static nsHtml5ElementName** ELEMENT_NAMES;
-    static jArray<PRInt32,PRInt32> ELEMENT_HASHES;
+    static staticJArray<PRInt32,PRInt32> ELEMENT_HASHES;
   public:
     static void initializeStatics();
     static void releaseStatics();
 };
 
-#ifdef nsHtml5ElementName_cpp__
-nsHtml5ElementName* nsHtml5ElementName::ELT_NULL_ELEMENT_NAME = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_A = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_B = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_G = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_I = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_P = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_Q = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_S = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_U = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CI = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EQ = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_H1 = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_H2 = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_H3 = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_H4 = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_H5 = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_H6 = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_GT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_HR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_IN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LI = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MI = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MO = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_OL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_OR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PI = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_RP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_RT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_UL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_AND = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARG = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ABS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BIG = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BDO = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CSC = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DEL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DFN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DIR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DIV = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EXP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_GCD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_GEQ = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_IMG = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_INS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_INT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_KBD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LOG = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LCM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LEQ = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MTD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MIN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MAP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MTR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MAX = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NEQ = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NAV = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PRE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_REM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SUB = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SEC = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SVG = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SUM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SIN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SEP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SUP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TAN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_USE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_VAR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_WBR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_XMP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_XOR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_AREA = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ABBR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BASE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BVAR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BODY = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CARD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CODE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CITE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CSCH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COSH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COTH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CURL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DESC = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DIFF = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DEFS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FORM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FONT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_GRAD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_HEAD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_HTML = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LINE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LINK = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LIST = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_META = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MSUB = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MODE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MATH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MARK = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MASK = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MEAN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MSUP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MENU = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MROW = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NONE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOBR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NEST = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PATH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PLUS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_RULE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_REAL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_RELN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_RECT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ROOT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_RUBY = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SECH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SINH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SPAN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SAMP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_STOP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SDEV = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TIME = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TRUE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TREF = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TANH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TEXT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_VIEW = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ASIDE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_AUDIO = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_APPLY = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EMBED = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FRAME = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FALSE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FLOOR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_GLYPH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_HKERN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_IMAGE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_IDENT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_INPUT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LABEL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LIMIT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MFRAC = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MPATH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_METER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MOVER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MINUS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MROOT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MSQRT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MTEXT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOTIN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PIECE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PARAM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_POWER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_REALS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_STYLE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SMALL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_THEAD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TABLE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TITLE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TSPAN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TIMES = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TFOOT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TBODY = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_UNION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_VKERN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_VIDEO = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCSEC = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCSC = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCTAN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCSIN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCOS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_APPLET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCOT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_APPROX = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BUTTON = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CIRCLE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CENTER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CURSOR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CANVAS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DIVIDE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DEGREE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DOMAIN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EXISTS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FETILE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FIGURE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FORALL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FILTER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FOOTER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_HGROUP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_HEADER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_IFRAME = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_KEYGEN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LAMBDA = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LEGEND = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MSPACE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MTABLE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MSTYLE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MGLYPH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MEDIAN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MUNDER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MARKER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MERROR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MOMENT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MATRIX = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_OPTION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_OBJECT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_OUTPUT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PRIMES = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SOURCE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_STRIKE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_STRONG = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SWITCH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SYMBOL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SELECT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SUBSET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SCRIPT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TBREAK = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_VECTOR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARTICLE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCSECH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCSCH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCTANH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCSINH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCOSH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ARCCOTH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ACRONYM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ADDRESS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BGSOUND = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COMMAND = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COMPOSE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CEILING = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CSYMBOL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CAPTION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DISCARD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DECLARE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DETAILS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ELLIPSE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEFUNCA = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEFUNCB = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEBLEND = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEFLOOD = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEIMAGE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEMERGE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEFUNCG = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEFUNCR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_HANDLER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_INVERSE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_IMPLIES = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ISINDEX = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LOGBASE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LISTING = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MFENCED = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MPADDED = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MARQUEE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MACTION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MSUBSUP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOEMBED = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_POLYGON = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PATTERN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PRODUCT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SETDIFF = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SECTION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TENDSTO = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_UPLIMIT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ALTGLYPH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BASEFONT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CLIPPATH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CODOMAIN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COLGROUP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DATAGRID = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EMPTYSET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FACTOROF = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FIELDSET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FRAMESET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEOFFSET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_GLYPHREF = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_INTERVAL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_INTEGERS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_INFINITY = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LISTENER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LOWLIMIT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_METADATA = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MENCLOSE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MPHANTOM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOFRAMES = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOSCRIPT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_OPTGROUP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_POLYLINE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PREFETCH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PROGRESS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PRSUBSET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_QUOTIENT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SELECTOR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TEXTAREA = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TEXTPATH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_VARIANCE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CONJUGATE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CONDITION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COMPLEXES = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FACTORIAL = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_INTERSECT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_IMAGINARY = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LAPLACIAN = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MATRIXROW = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOTSUBSET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_OTHERWISE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PIECEWISE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PLAINTEXT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_RATIONALS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SEMANTICS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_TRANSPOSE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ANNOTATION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_BLOCKQUOTE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DIVERGENCE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EULERGAMMA = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EQUIVALENT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_IMAGINARYI = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MALIGNMARK = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MUNDEROVER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MLABELEDTR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOTANUMBER = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SOLIDCOLOR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ALTGLYPHDEF = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DETERMINANT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEMERGENODE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FECOMPOSITE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FESPOTLIGHT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MALIGNGROUP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MPRESCRIPTS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MOMENTABOUT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NOTPRSUBSET = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_PARTIALDIFF = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ALTGLYPHITEM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATECOLOR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DATATEMPLATE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_EXPONENTIALE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FETURBULENCE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEPOINTLIGHT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEMORPHOLOGY = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_OUTERPRODUCT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATEMOTION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_COLOR_PROFILE = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE_SRC = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE_URI = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FOREIGNOBJECT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FECOLORMATRIX = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MISSING_GLYPH = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MMULTISCRIPTS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_SCALARPRODUCT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_VECTORPRODUCT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ANNOTATION_XML = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DEFINITION_SRC = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE_NAME = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEGAUSSIANBLUR = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEDISTANTLIGHT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_LINEARGRADIENT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_NATURALNUMBERS = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_RADIALGRADIENT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_ANIMATETRANSFORM = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_CARTESIANPRODUCT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FONT_FACE_FORMAT = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FECONVOLVEMATRIX = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEDIFFUSELIGHTING = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FEDISPLACEMENTMAP = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FESPECULARLIGHTING = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_DOMAINOFAPPLICATION = nsnull;
-nsHtml5ElementName* nsHtml5ElementName::ELT_FECOMPONENTTRANSFER = nsnull;
-nsHtml5ElementName** nsHtml5ElementName::ELEMENT_NAMES = nsnull;
-jArray<PRInt32,PRInt32> nsHtml5ElementName::ELEMENT_HASHES = 0;
-#endif
-
 
 
 #endif
 
--- a/parser/html/nsHtml5HtmlAttributes.cpp
+++ b/parser/html/nsHtml5HtmlAttributes.cpp
@@ -54,33 +54,32 @@
 #include "nsHtml5ElementName.h"
 #include "nsHtml5StackNode.h"
 #include "nsHtml5UTF16Buffer.h"
 #include "nsHtml5StateSnapshot.h"
 #include "nsHtml5Portability.h"
 
 #include "nsHtml5HtmlAttributes.h"
 
+nsHtml5HtmlAttributes* nsHtml5HtmlAttributes::EMPTY_ATTRIBUTES = nsnull;
 
 nsHtml5HtmlAttributes::nsHtml5HtmlAttributes(PRInt32 mode)
   : mode(mode),
     length(0),
-    names(jArray<nsHtml5AttributeName*,PRInt32>(5)),
-    values(jArray<nsString*,PRInt32>(5))
+    names(jArray<nsHtml5AttributeName*,PRInt32>::newJArray(5)),
+    values(jArray<nsString*,PRInt32>::newJArray(5))
 {
   MOZ_COUNT_CTOR(nsHtml5HtmlAttributes);
 }
 
 
 nsHtml5HtmlAttributes::~nsHtml5HtmlAttributes()
 {
   MOZ_COUNT_DTOR(nsHtml5HtmlAttributes);
   clear(0);
-  names.release();
-  values.release();
 }
 
 PRInt32 
 nsHtml5HtmlAttributes::getIndex(nsHtml5AttributeName* name)
 {
   for (PRInt32 i = 0; i < length; i++) {
     if (names[i] == name) {
       return i;
@@ -156,23 +155,21 @@ nsHtml5HtmlAttributes::getValue(nsHtml5A
   }
 }
 
 void 
 nsHtml5HtmlAttributes::addAttribute(nsHtml5AttributeName* name, nsString* value)
 {
   if (names.length == length) {
     PRInt32 newLen = length << 1;
-    jArray<nsHtml5AttributeName*,PRInt32> newNames = jArray<nsHtml5AttributeName*,PRInt32>(newLen);
+    jArray<nsHtml5AttributeName*,PRInt32> newNames = jArray<nsHtml5AttributeName*,PRInt32>::newJArray(newLen);
     nsHtml5ArrayCopy::arraycopy(names, newNames, names.length);
-    names.release();
     names = newNames;
-    jArray<nsString*,PRInt32> newValues = jArray<nsString*,PRInt32>(newLen);
+    jArray<nsString*,PRInt32> newValues = jArray<nsString*,PRInt32>::newJArray(newLen);
     nsHtml5ArrayCopy::arraycopy(values, newValues, values.length);
-    values.release();
     values = newValues;
   }
   names[length] = name;
   values[length] = value;
   length++;
 }
 
 void 
--- a/parser/html/nsHtml5HtmlAttributes.h
+++ b/parser/html/nsHtml5HtmlAttributes.h
@@ -62,18 +62,18 @@ class nsHtml5Portability;
 
 class nsHtml5HtmlAttributes
 {
   public:
     static nsHtml5HtmlAttributes* EMPTY_ATTRIBUTES;
   private:
     PRInt32 mode;
     PRInt32 length;
-    jArray<nsHtml5AttributeName*,PRInt32> names;
-    jArray<nsString*,PRInt32> values;
+    autoJArray<nsHtml5AttributeName*,PRInt32> names;
+    autoJArray<nsString*,PRInt32> values;
   public:
     nsHtml5HtmlAttributes(PRInt32 mode);
     ~nsHtml5HtmlAttributes();
     PRInt32 getIndex(nsHtml5AttributeName* name);
     PRInt32 getLength();
     nsIAtom* getLocalName(PRInt32 index);
     nsHtml5AttributeName* getAttributeName(PRInt32 index);
     PRInt32 getURI(PRInt32 index);
@@ -87,16 +87,12 @@ class nsHtml5HtmlAttributes
     PRBool contains(nsHtml5AttributeName* name);
     void adjustForMath();
     void adjustForSvg();
     nsHtml5HtmlAttributes* cloneAttributes(nsHtml5AtomTable* interner);
     static void initializeStatics();
     static void releaseStatics();
 };
 
-#ifdef nsHtml5HtmlAttributes_cpp__
-nsHtml5HtmlAttributes* nsHtml5HtmlAttributes::EMPTY_ATTRIBUTES = nsnull;
-#endif
-
 
 
 #endif
 
--- a/parser/html/nsHtml5MetaScanner.cpp
+++ b/parser/html/nsHtml5MetaScanner.cpp
@@ -54,16 +54,18 @@
 #include "nsHtml5HtmlAttributes.h"
 #include "nsHtml5StackNode.h"
 #include "nsHtml5UTF16Buffer.h"
 #include "nsHtml5StateSnapshot.h"
 #include "nsHtml5Portability.h"
 
 #include "nsHtml5MetaScanner.h"
 
+PRUnichar nsHtml5MetaScanner::CHARSET[] = { 'c', 'h', 'a', 'r', 's', 'e', 't' };
+PRUnichar nsHtml5MetaScanner::CONTENT[] = { 'c', 'o', 'n', 't', 'e', 'n', 't' };
 void 
 nsHtml5MetaScanner::stateLoop(PRInt32 state)
 {
   PRInt32 c = -1;
   PRBool reconsume = PR_FALSE;
   stateloop: for (; ; ) {
     switch(state) {
       case NS_HTML5META_SCANNER_DATA: {
@@ -666,19 +668,18 @@ nsHtml5MetaScanner::stateLoop(PRInt32 st
   stateloop_end: ;
   stateSave = state;
 }
 
 void 
 nsHtml5MetaScanner::addToBuffer(PRInt32 c)
 {
   if (strBufLen == strBuf.length) {
-    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>(strBuf.length + (strBuf.length << 1));
+    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>::newJArray(strBuf.length + (strBuf.length << 1));
     nsHtml5ArrayCopy::arraycopy(strBuf, newBuf, strBuf.length);
-    strBuf.release();
     strBuf = newBuf;
   }
   strBuf[strBufLen++] = (PRUnichar) c;
 }
 
 PRBool 
 nsHtml5MetaScanner::tryCharset()
 {
--- a/parser/html/nsHtml5MetaScanner.h
+++ b/parser/html/nsHtml5MetaScanner.h
@@ -70,36 +70,31 @@ class nsHtml5MetaScanner
   private:
     PRInt32 metaState;
     PRInt32 contentIndex;
     PRInt32 charsetIndex;
   protected:
     PRInt32 stateSave;
   private:
     PRInt32 strBufLen;
-    jArray<PRUnichar,PRInt32> strBuf;
+    autoJArray<PRUnichar,PRInt32> strBuf;
   protected:
     void stateLoop(PRInt32 state);
   private:
     void addToBuffer(PRInt32 c);
     PRBool tryCharset();
   protected:
     PRBool tryCharset(nsString* encoding);
   public:
     static void initializeStatics();
     static void releaseStatics();
 
 #include "nsHtml5MetaScannerHSupplement.h"
 };
 
-#ifdef nsHtml5MetaScanner_cpp__
-PRUnichar nsHtml5MetaScanner::CHARSET[] = { 'c', 'h', 'a', 'r', 's', 'e', 't' };
-PRUnichar nsHtml5MetaScanner::CONTENT[] = { 'c', 'o', 'n', 't', 'e', 'n', 't' };
-#endif
-
 #define NS_HTML5META_SCANNER_NO 0
 #define NS_HTML5META_SCANNER_M 1
 #define NS_HTML5META_SCANNER_E 2
 #define NS_HTML5META_SCANNER_T 3
 #define NS_HTML5META_SCANNER_A 4
 #define NS_HTML5META_SCANNER_DATA 0
 #define NS_HTML5META_SCANNER_TAG_OPEN 1
 #define NS_HTML5META_SCANNER_SCAN_UNTIL_GT 2
--- a/parser/html/nsHtml5MetaScannerCppSupplement.h
+++ b/parser/html/nsHtml5MetaScannerCppSupplement.h
@@ -45,25 +45,24 @@ static NS_DEFINE_CID(kCharsetAliasCID, N
 
 nsHtml5MetaScanner::nsHtml5MetaScanner()
  : readable(nsnull),
    metaState(NS_HTML5META_SCANNER_NO),
    contentIndex(-1),
    charsetIndex(-1),
    stateSave(NS_HTML5META_SCANNER_DATA),
    strBufLen(0),
-   strBuf(jArray<PRUnichar,PRInt32>(36))
+   strBuf(jArray<PRUnichar,PRInt32>::newJArray(36))
 {
   MOZ_COUNT_CTOR(nsHtml5MetaScanner);
 }
 
 nsHtml5MetaScanner::~nsHtml5MetaScanner()
 {
   MOZ_COUNT_DTOR(nsHtml5MetaScanner);
-  strBuf.release();
 }
 
 void
 nsHtml5MetaScanner::sniff(nsHtml5ByteReadable* bytes, nsIUnicodeDecoder** decoder, nsACString& charset)
 {
   readable = bytes;
   stateLoop(stateSave);
   readable = nsnull;
--- a/parser/html/nsHtml5Portability.cpp
+++ b/parser/html/nsHtml5Portability.cpp
@@ -77,26 +77,26 @@ nsHtml5Portability::newStringFromString(
 }
 
 jArray<PRUnichar,PRInt32>
 nsHtml5Portability::newCharArrayFromLocal(nsIAtom* local)
 {
   nsAutoString temp;
   local->ToString(temp);
   PRInt32 len = temp.Length();
-  jArray<PRUnichar,PRInt32> arr = jArray<PRUnichar,PRInt32>(len);
+  jArray<PRUnichar,PRInt32> arr = jArray<PRUnichar,PRInt32>::newJArray(len);
   memcpy(arr, temp.BeginReading(), len * sizeof(PRUnichar));
   return arr;
 }
 
 jArray<PRUnichar,PRInt32>
 nsHtml5Portability::newCharArrayFromString(nsString* string)
 {
   PRInt32 len = string->Length();
-  jArray<PRUnichar,PRInt32> arr = jArray<PRUnichar,PRInt32>(len);
+  jArray<PRUnichar,PRInt32> arr = jArray<PRUnichar,PRInt32>::newJArray(len);
   memcpy(arr, string->BeginReading(), len * sizeof(PRUnichar));
   return arr;
 }
 
 nsIAtom*
 nsHtml5Portability::newLocalFromLocal(nsIAtom* local, nsHtml5AtomTable* interner)
 {
   NS_PRECONDITION(local, "Atom was null.");
--- a/parser/html/nsHtml5Portability.h
+++ b/parser/html/nsHtml5Portability.h
@@ -76,15 +76,12 @@ class nsHtml5Portability
     static PRBool localEqualsBuffer(nsIAtom* local, PRUnichar* buf, PRInt32 offset, PRInt32 length);
     static PRBool lowerCaseLiteralIsPrefixOfIgnoreAsciiCaseString(const char* lowerCaseLiteral, nsString* string);
     static PRBool lowerCaseLiteralEqualsIgnoreAsciiCaseString(const char* lowerCaseLiteral, nsString* string);
     static PRBool literalEqualsString(const char* literal, nsString* string);
     static void initializeStatics();
     static void releaseStatics();
 };
 
-#ifdef nsHtml5Portability_cpp__
-#endif
-
 
 
 #endif
 
--- a/parser/html/nsHtml5StackNode.h
+++ b/parser/html/nsHtml5StackNode.h
@@ -84,15 +84,12 @@ class nsHtml5StackNode
     ~nsHtml5StackNode();
     void dropAttributes();
     void retain();
     void release();
     static void initializeStatics();
     static void releaseStatics();
 };
 
-#ifdef nsHtml5StackNode_cpp__
-#endif
-
 
 
 #endif
 
--- a/parser/html/nsHtml5StateSnapshot.cpp
+++ b/parser/html/nsHtml5StateSnapshot.cpp
@@ -1,10 +1,10 @@
 /*
- * Copyright (c) 2009 Mozilla Foundation
+ * Copyright (c) 2009-2010 Mozilla Foundation
  *
  * Permission is hereby granted, free of charge, to any person obtaining a 
  * copy of this software and associated documentation files (the "Software"), 
  * to deal in the Software without restriction, including without limitation 
  * the rights to use, copy, modify, merge, publish, distribute, sublicense, 
  * and/or sell copies of the Software, and to permit persons to whom the 
  * Software is furnished to do so, subject to the following conditions:
  *
@@ -155,23 +155,21 @@ nsHtml5StateSnapshot::getStackLength()
 
 
 nsHtml5StateSnapshot::~nsHtml5StateSnapshot()
 {
   MOZ_COUNT_DTOR(nsHtml5StateSnapshot);
   for (PRInt32 i = 0; i < stack.length; i++) {
     stack[i]->release();
   }
-  stack.release();
   for (PRInt32 i = 0; i < listOfActiveFormattingElements.length; i++) {
     if (listOfActiveFormattingElements[i]) {
       listOfActiveFormattingElements[i]->release();
     }
   }
-  listOfActiveFormattingElements.release();
   ;
 }
 
 void
 nsHtml5StateSnapshot::initializeStatics()
 {
 }
 
--- a/parser/html/nsHtml5StateSnapshot.h
+++ b/parser/html/nsHtml5StateSnapshot.h
@@ -1,10 +1,10 @@
 /*
- * Copyright (c) 2009 Mozilla Foundation
+ * Copyright (c) 2009-2010 Mozilla Foundation
  *
  * Permission is hereby granted, free of charge, to any person obtaining a 
  * copy of this software and associated documentation files (the "Software"), 
  * to deal in the Software without restriction, including without limitation 
  * the rights to use, copy, modify, merge, publish, distribute, sublicense, 
  * and/or sell copies of the Software, and to permit persons to whom the 
  * Software is furnished to do so, subject to the following conditions:
  *
@@ -57,18 +57,18 @@ class nsHtml5ElementName;
 class nsHtml5HtmlAttributes;
 class nsHtml5UTF16Buffer;
 class nsHtml5Portability;
 
 
 class nsHtml5StateSnapshot : public nsAHtml5TreeBuilderState
 {
   private:
-    jArray<nsHtml5StackNode*,PRInt32> stack;
-    jArray<nsHtml5StackNode*,PRInt32> listOfActiveFormattingElements;
+    autoJArray<nsHtml5StackNode*,PRInt32> stack;
+    autoJArray<nsHtml5StackNode*,PRInt32> listOfActiveFormattingElements;
     nsIContent** formPointer;
     nsIContent** headPointer;
     nsIContent** deepTreeSurrogateParent;
     PRInt32 mode;
     PRInt32 originalMode;
     PRBool framesetOk;
     PRBool inForeign;
     PRBool needToDropLF;
@@ -88,15 +88,12 @@ class nsHtml5StateSnapshot : public nsAH
     PRBool isQuirks();
     PRInt32 getListOfActiveFormattingElementsLength();
     PRInt32 getStackLength();
     ~nsHtml5StateSnapshot();
     static void initializeStatics();
     static void releaseStatics();
 };
 
-#ifdef nsHtml5StateSnapshot_cpp__
-#endif
-
 
 
 #endif
 
--- a/parser/html/nsHtml5Tokenizer.cpp
+++ b/parser/html/nsHtml5Tokenizer.cpp
@@ -56,32 +56,51 @@
 #include "nsHtml5HtmlAttributes.h"
 #include "nsHtml5StackNode.h"
 #include "nsHtml5UTF16Buffer.h"
 #include "nsHtml5StateSnapshot.h"
 #include "nsHtml5Portability.h"
 
 #include "nsHtml5Tokenizer.h"
 
+PRUnichar nsHtml5Tokenizer::LT_GT[] = { '<', '>' };
+PRUnichar nsHtml5Tokenizer::LT_SOLIDUS[] = { '<', '/' };
+PRUnichar nsHtml5Tokenizer::RSQB_RSQB[] = { ']', ']' };
+PRUnichar nsHtml5Tokenizer::REPLACEMENT_CHARACTER[] = { 0xfffd };
+PRUnichar nsHtml5Tokenizer::LF[] = { '\n' };
+PRUnichar nsHtml5Tokenizer::CDATA_LSQB[] = { 'C', 'D', 'A', 'T', 'A', '[' };
+PRUnichar nsHtml5Tokenizer::OCTYPE[] = { 'o', 'c', 't', 'y', 'p', 'e' };
+PRUnichar nsHtml5Tokenizer::UBLIC[] = { 'u', 'b', 'l', 'i', 'c' };
+PRUnichar nsHtml5Tokenizer::YSTEM[] = { 'y', 's', 't', 'e', 'm' };
 static PRUnichar const TITLE_ARR_DATA[] = { 't', 'i', 't', 'l', 'e' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::TITLE_ARR = { TITLE_ARR_DATA, NS_ARRAY_LENGTH(TITLE_ARR_DATA) };
 static PRUnichar const SCRIPT_ARR_DATA[] = { 's', 'c', 'r', 'i', 'p', 't' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::SCRIPT_ARR = { SCRIPT_ARR_DATA, NS_ARRAY_LENGTH(SCRIPT_ARR_DATA) };
 static PRUnichar const STYLE_ARR_DATA[] = { 's', 't', 'y', 'l', 'e' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::STYLE_ARR = { STYLE_ARR_DATA, NS_ARRAY_LENGTH(STYLE_ARR_DATA) };
 static PRUnichar const PLAINTEXT_ARR_DATA[] = { 'p', 'l', 'a', 'i', 'n', 't', 'e', 'x', 't' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::PLAINTEXT_ARR = { PLAINTEXT_ARR_DATA, NS_ARRAY_LENGTH(PLAINTEXT_ARR_DATA) };
 static PRUnichar const XMP_ARR_DATA[] = { 'x', 'm', 'p' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::XMP_ARR = { XMP_ARR_DATA, NS_ARRAY_LENGTH(XMP_ARR_DATA) };
 static PRUnichar const TEXTAREA_ARR_DATA[] = { 't', 'e', 'x', 't', 'a', 'r', 'e', 'a' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::TEXTAREA_ARR = { TEXTAREA_ARR_DATA, NS_ARRAY_LENGTH(TEXTAREA_ARR_DATA) };
 static PRUnichar const IFRAME_ARR_DATA[] = { 'i', 'f', 'r', 'a', 'm', 'e' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::IFRAME_ARR = { IFRAME_ARR_DATA, NS_ARRAY_LENGTH(IFRAME_ARR_DATA) };
 static PRUnichar const NOEMBED_ARR_DATA[] = { 'n', 'o', 'e', 'm', 'b', 'e', 'd' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::NOEMBED_ARR = { NOEMBED_ARR_DATA, NS_ARRAY_LENGTH(NOEMBED_ARR_DATA) };
 static PRUnichar const NOSCRIPT_ARR_DATA[] = { 'n', 'o', 's', 'c', 'r', 'i', 'p', 't' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::NOSCRIPT_ARR = { NOSCRIPT_ARR_DATA, NS_ARRAY_LENGTH(NOSCRIPT_ARR_DATA) };
 static PRUnichar const NOFRAMES_ARR_DATA[] = { 'n', 'o', 'f', 'r', 'a', 'm', 'e', 's' };
+staticJArray<PRUnichar,PRInt32> nsHtml5Tokenizer::NOFRAMES_ARR = { NOFRAMES_ARR_DATA, NS_ARRAY_LENGTH(NOFRAMES_ARR_DATA) };
 
 nsHtml5Tokenizer::nsHtml5Tokenizer(nsHtml5TreeBuilder* tokenHandler)
   : tokenHandler(tokenHandler),
     encodingDeclarationHandler(nsnull),
-    bmpChar(jArray<PRUnichar,PRInt32>(1)),
-    astralChar(jArray<PRUnichar,PRInt32>(2)),
+    bmpChar(jArray<PRUnichar,PRInt32>::newJArray(1)),
+    astralChar(jArray<PRUnichar,PRInt32>::newJArray(2)),
     tagName(nsnull),
     attributeName(nsnull),
     doctypeName(nsnull),
     publicIdentifier(nsnull),
     systemIdentifier(nsnull),
     attributes(nsnull)
 {
   MOZ_COUNT_CTOR(nsHtml5Tokenizer);
@@ -95,34 +114,25 @@ nsHtml5Tokenizer::setInterner(nsHtml5Ato
 
 void 
 nsHtml5Tokenizer::initLocation(nsString* newPublicId, nsString* newSystemId)
 {
   this->systemId = newSystemId;
   this->publicId = newPublicId;
 }
 
-
-nsHtml5Tokenizer::~nsHtml5Tokenizer()
-{
-  MOZ_COUNT_DTOR(nsHtml5Tokenizer);
-  bmpChar.release();
-  astralChar.release();
-}
-
 void 
 nsHtml5Tokenizer::setStateAndEndTagExpectation(PRInt32 specialTokenizerState, nsIAtom* endTagExpectation)
 {
   this->stateSave = specialTokenizerState;
   if (specialTokenizerState == NS_HTML5TOKENIZER_DATA) {
     return;
   }
-  jArray<PRUnichar,PRInt32> asArray = nsHtml5Portability::newCharArrayFromLocal(endTagExpectation);
+  autoJArray<PRUnichar,PRInt32> asArray = nsHtml5Portability::newCharArrayFromLocal(endTagExpectation);
   this->endTagExpectation = nsHtml5ElementName::elementNameByBuffer(asArray, 0, asArray.length, interner);
-  asArray.release();
   endTagExpectationToArray();
 }
 
 void 
 nsHtml5Tokenizer::setStateAndEndTagExpectation(PRInt32 specialTokenizerState, nsHtml5ElementName* endTagExpectation)
 {
   this->stateSave = specialTokenizerState;
   this->endTagExpectation = endTagExpectation;
@@ -191,19 +201,18 @@ nsHtml5Tokenizer::emptyAttributes()
 {
   return nsHtml5HtmlAttributes::EMPTY_ATTRIBUTES;
 }
 
 void 
 nsHtml5Tokenizer::appendStrBuf(PRUnichar c)
 {
   if (strBufLen == strBuf.length) {
-    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>(strBuf.length + NS_HTML5TOKENIZER_BUFFER_GROW_BY);
+    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>::newJArray(strBuf.length + NS_HTML5TOKENIZER_BUFFER_GROW_BY);
     nsHtml5ArrayCopy::arraycopy(strBuf, newBuf, strBuf.length);
-    strBuf.release();
     strBuf = newBuf;
   }
   strBuf[strBufLen++] = c;
 }
 
 nsString* 
 nsHtml5Tokenizer::strBufToString()
 {
@@ -223,32 +232,30 @@ nsHtml5Tokenizer::emitStrBuf()
     tokenHandler->characters(strBuf, 0, strBufLen);
   }
 }
 
 void 
 nsHtml5Tokenizer::appendLongStrBuf(PRUnichar c)
 {
   if (longStrBufLen == longStrBuf.length) {
-    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>(longStrBufLen + (longStrBufLen >> 1));
+    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>::newJArray(longStrBufLen + (longStrBufLen >> 1));
     nsHtml5ArrayCopy::arraycopy(longStrBuf, newBuf, longStrBuf.length);
-    longStrBuf.release();
     longStrBuf = newBuf;
   }
   longStrBuf[longStrBufLen++] = c;
 }
 
 void 
-nsHtml5Tokenizer::appendLongStrBuf(jArray<PRUnichar,PRInt32> buffer, PRInt32 offset, PRInt32 length)
+nsHtml5Tokenizer::appendLongStrBuf(PRUnichar* buffer, PRInt32 offset, PRInt32 length)
 {
   PRInt32 reqLen = longStrBufLen + length;
   if (longStrBuf.length < reqLen) {
-    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>(reqLen + (reqLen >> 1));
+    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>::newJArray(reqLen + (reqLen >> 1));
     nsHtml5ArrayCopy::arraycopy(longStrBuf, newBuf, longStrBuf.length);
-    longStrBuf.release();
     longStrBuf = newBuf;
   }
   nsHtml5ArrayCopy::arraycopy(buffer, offset, longStrBuf, longStrBufLen, length);
   longStrBufLen = reqLen;
 }
 
 nsString* 
 nsHtml5Tokenizer::longStrBufToString()
@@ -3700,19 +3707,17 @@ nsHtml5Tokenizer::emitOrAppendOne(const 
   } else {
     tokenHandler->characters(val, 0, 1);
   }
 }
 
 void 
 nsHtml5Tokenizer::end()
 {
-  strBuf.release();
   strBuf = nsnull;
-  longStrBuf.release();
   longStrBuf = nsnull;
   nsHtml5Portability::releaseLocal(doctypeName);
   doctypeName = nsnull;
   if (systemIdentifier) {
     nsHtml5Portability::releaseString(systemIdentifier);
     systemIdentifier = nsnull;
   }
   if (publicIdentifier) {
@@ -3755,17 +3760,17 @@ nsHtml5Tokenizer::resetToDataState()
   stateSave = NS_HTML5TOKENIZER_DATA;
   lastCR = PR_FALSE;
   index = 0;
   forceQuirks = PR_FALSE;
   additional = '\0';
   entCol = -1;
   firstCharKey = -1;
   lo = 0;
-  hi = (nsHtml5NamedCharacters::NAMES.length - 1);
+  hi = 0;
   candidate = -1;
   strBufMark = 0;
   prevValue = -1;
   value = 0;
   seenDigits = PR_FALSE;
   endTag = PR_FALSE;
   shouldSuspend = PR_FALSE;
   initDoctypeFields();
@@ -3783,24 +3788,22 @@ nsHtml5Tokenizer::resetToDataState()
   }
 }
 
 void 
 nsHtml5Tokenizer::loadState(nsHtml5Tokenizer* other)
 {
   strBufLen = other->strBufLen;
   if (strBufLen > strBuf.length) {
-    strBuf.release();
-    strBuf = jArray<PRUnichar,PRInt32>(strBufLen);
+    strBuf = jArray<PRUnichar,PRInt32>::newJArray(strBufLen);
   }
   nsHtml5ArrayCopy::arraycopy(other->strBuf, strBuf, strBufLen);
   longStrBufLen = other->longStrBufLen;
   if (longStrBufLen > longStrBuf.length) {
-    longStrBuf.release();
-    longStrBuf = jArray<PRUnichar,PRInt32>(longStrBufLen);
+    longStrBuf = jArray<PRUnichar,PRInt32>::newJArray(longStrBufLen);
   }
   nsHtml5ArrayCopy::arraycopy(other->longStrBuf, longStrBuf, longStrBufLen);
   stateSave = other->stateSave;
   returnStateSave = other->returnStateSave;
   endTagExpectation = other->endTagExpectation;
   endTagExpectationAsArray = other->endTagExpectationAsArray;
   lastCR = other->lastCR;
   index = other->index;
@@ -3860,41 +3863,31 @@ nsHtml5Tokenizer::loadState(nsHtml5Token
     attributes = other->attributes->cloneAttributes(interner);
   }
 }
 
 void 
 nsHtml5Tokenizer::initializeWithoutStarting()
 {
   confident = PR_FALSE;
-  strBuf = jArray<PRUnichar,PRInt32>(64);
-  longStrBuf = jArray<PRUnichar,PRInt32>(1024);
+  strBuf = jArray<PRUnichar,PRInt32>::newJArray(64);
+  longStrBuf = jArray<PRUnichar,PRInt32>::newJArray(1024);
   line = 1;
   resetToDataState();
 }
 
 void 
 nsHtml5Tokenizer::setEncodingDeclarationHandler(nsHtml5StreamParser* encodingDeclarationHandler)
 {
   this->encodingDeclarationHandler = encodingDeclarationHandler;
 }
 
 void
 nsHtml5Tokenizer::initializeStatics()
 {
-  TITLE_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)TITLE_ARR_DATA, 5);
-  SCRIPT_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)SCRIPT_ARR_DATA, 6);
-  STYLE_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)STYLE_ARR_DATA, 5);
-  PLAINTEXT_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)PLAINTEXT_ARR_DATA, 9);
-  XMP_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)XMP_ARR_DATA, 3);
-  TEXTAREA_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)TEXTAREA_ARR_DATA, 8);
-  IFRAME_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)IFRAME_ARR_DATA, 6);
-  NOEMBED_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)NOEMBED_ARR_DATA, 7);
-  NOSCRIPT_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)NOSCRIPT_ARR_DATA, 8);
-  NOFRAMES_ARR = jArray<PRUnichar,PRInt32>((PRUnichar*)NOFRAMES_ARR_DATA, 8);
 }
 
 void
 nsHtml5Tokenizer::releaseStatics()
 {
 }
 
 
--- a/parser/html/nsHtml5Tokenizer.h
+++ b/parser/html/nsHtml5Tokenizer.h
@@ -69,26 +69,26 @@ class nsHtml5Tokenizer
     static PRUnichar LT_SOLIDUS[];
     static PRUnichar RSQB_RSQB[];
     static PRUnichar REPLACEMENT_CHARACTER[];
     static PRUnichar LF[];
     static PRUnichar CDATA_LSQB[];
     static PRUnichar OCTYPE[];
     static PRUnichar UBLIC[];
     static PRUnichar YSTEM[];
-    static jArray<PRUnichar,PRInt32> TITLE_ARR;
-    static jArray<PRUnichar,PRInt32> SCRIPT_ARR;
-    static jArray<PRUnichar,PRInt32> STYLE_ARR;
-    static jArray<PRUnichar,PRInt32> PLAINTEXT_ARR;
-    static jArray<PRUnichar,PRInt32> XMP_ARR;
-    static jArray<PRUnichar,PRInt32> TEXTAREA_ARR;
-    static jArray<PRUnichar,PRInt32> IFRAME_ARR;
-    static jArray<PRUnichar,PRInt32> NOEMBED_ARR;
-    static jArray<PRUnichar,PRInt32> NOSCRIPT_ARR;
-    static jArray<PRUnichar,PRInt32> NOFRAMES_ARR;
+    static staticJArray<PRUnichar,PRInt32> TITLE_ARR;
+    static staticJArray<PRUnichar,PRInt32> SCRIPT_ARR;
+    static staticJArray<PRUnichar,PRInt32> STYLE_ARR;
+    static staticJArray<PRUnichar,PRInt32> PLAINTEXT_ARR;
+    static staticJArray<PRUnichar,PRInt32> XMP_ARR;
+    static staticJArray<PRUnichar,PRInt32> TEXTAREA_ARR;
+    static staticJArray<PRUnichar,PRInt32> IFRAME_ARR;
+    static staticJArray<PRUnichar,PRInt32> NOEMBED_ARR;
+    static staticJArray<PRUnichar,PRInt32> NOSCRIPT_ARR;
+    static staticJArray<PRUnichar,PRInt32> NOFRAMES_ARR;
   protected:
     nsHtml5TreeBuilder* tokenHandler;
     nsHtml5StreamParser* encodingDeclarationHandler;
     PRBool lastCR;
     PRInt32 stateSave;
   private:
     PRInt32 returnStateSave;
   protected:
@@ -107,22 +107,22 @@ class nsHtml5Tokenizer
     PRInt32 value;
   private:
     PRBool seenDigits;
   protected:
     PRInt32 cstart;
   private:
     nsString* publicId;
     nsString* systemId;
-    jArray<PRUnichar,PRInt32> strBuf;
+    autoJArray<PRUnichar,PRInt32> strBuf;
     PRInt32 strBufLen;
-    jArray<PRUnichar,PRInt32> longStrBuf;
+    autoJArray<PRUnichar,PRInt32> longStrBuf;
     PRInt32 longStrBufLen;
-    jArray<PRUnichar,PRInt32> bmpChar;
-    jArray<PRUnichar,PRInt32> astralChar;
+    autoJArray<PRUnichar,PRInt32> bmpChar;
+    autoJArray<PRUnichar,PRInt32> astralChar;
   protected:
     nsHtml5ElementName* endTagExpectation;
   private:
     jArray<PRUnichar,PRInt32> endTagExpectationAsArray;
   protected:
     PRBool endTag;
   private:
     nsHtml5ElementName* tagName;
@@ -139,17 +139,16 @@ class nsHtml5Tokenizer
     PRBool confident;
   private:
     PRInt32 line;
     nsHtml5AtomTable* interner;
   public:
     nsHtml5Tokenizer(nsHtml5TreeBuilder* tokenHandler);
     void setInterner(nsHtml5AtomTable* interner);
     void initLocation(nsString* newPublicId, nsString* newSystemId);
-    ~nsHtml5Tokenizer();
     void setStateAndEndTagExpectation(PRInt32 specialTokenizerState, nsIAtom* endTagExpectation);
     void setStateAndEndTagExpectation(PRInt32 specialTokenizerState, nsHtml5ElementName* endTagExpectation);
   private:
     void endTagExpectationToArray();
   public:
     void setLineNumber(PRInt32 line);
     inline PRInt32 getLineNumber()
     {
@@ -193,17 +192,17 @@ class nsHtml5Tokenizer
     }
 
     inline void adjustDoubleHyphenAndAppendToLongStrBufAndErr(PRUnichar c)
     {
 
       appendLongStrBuf(c);
     }
 
-    void appendLongStrBuf(jArray<PRUnichar,PRInt32> buffer, PRInt32 offset, PRInt32 length);
+    void appendLongStrBuf(PRUnichar* buffer, PRInt32 offset, PRInt32 length);
     inline void appendStrBufToLongStrBuf()
     {
       appendLongStrBuf(strBuf, 0, strBufLen);
     }
 
     nsString* longStrBufToString();
     void emitComment(PRInt32 provisionalHyphens, PRInt32 pos);
   protected:
@@ -287,38 +286,16 @@ class nsHtml5Tokenizer
     void resetToDataState();
     void loadState(nsHtml5Tokenizer* other);
     void initializeWithoutStarting();
     void setEncodingDeclarationHandler(nsHtml5StreamParser* encodingDeclarationHandler);
     static void initializeStatics();
     static void releaseStatics();
 };
 
-#ifdef nsHtml5Tokenizer_cpp__
-PRUnichar nsHtml5Tokenizer::LT_GT[] = { '<', '>' };
-PRUnichar nsHtml5Tokenizer::LT_SOLIDUS[] = { '<', '/' };
-PRUnichar nsHtml5Tokenizer::RSQB_RSQB[] = { ']', ']' };
-PRUnichar nsHtml5Tokenizer::REPLACEMENT_CHARACTER[] = { 0xfffd };
-PRUnichar nsHtml5Tokenizer::LF[] = { '\n' };
-PRUnichar nsHtml5Tokenizer::CDATA_LSQB[] = { 'C', 'D', 'A', 'T', 'A', '[' };
-PRUnichar nsHtml5Tokenizer::OCTYPE[] = { 'o', 'c', 't', 'y', 'p', 'e' };
-PRUnichar nsHtml5Tokenizer::UBLIC[] = { 'u', 'b', 'l', 'i', 'c' };
-PRUnichar nsHtml5Tokenizer::YSTEM[] = { 'y', 's', 't', 'e', 'm' };
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::TITLE_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::SCRIPT_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::STYLE_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::PLAINTEXT_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::XMP_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::TEXTAREA_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::IFRAME_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::NOEMBED_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::NOSCRIPT_ARR = 0;
-jArray<PRUnichar,PRInt32> nsHtml5Tokenizer::NOFRAMES_ARR = 0;
-#endif
-
 #define NS_HTML5TOKENIZER_DATA_AND_RCDATA_MASK ~1
 #define NS_HTML5TOKENIZER_DATA 0
 #define NS_HTML5TOKENIZER_RCDATA 1
 #define NS_HTML5TOKENIZER_SCRIPT_DATA 2
 #define NS_HTML5TOKENIZER_RAWTEXT 3
 #define NS_HTML5TOKENIZER_SCRIPT_DATA_ESCAPED 4
 #define NS_HTML5TOKENIZER_ATTRIBUTE_VALUE_DOUBLE_QUOTED 5
 #define NS_HTML5TOKENIZER_ATTRIBUTE_VALUE_SINGLE_QUOTED 6
--- a/parser/html/nsHtml5TreeBuilder.cpp
+++ b/parser/html/nsHtml5TreeBuilder.cpp
@@ -60,35 +60,38 @@
 #include "nsHtml5HtmlAttributes.h"
 #include "nsHtml5StackNode.h"
 #include "nsHtml5UTF16Buffer.h"
 #include "nsHtml5StateSnapshot.h"
 #include "nsHtml5Portability.h"
 
 #include "nsHtml5TreeBuilder.h"
 
+PRUnichar nsHtml5TreeBuilder::REPLACEMENT_CHARACTER[] = { 0xfffd };
+static const char* const QUIRKY_PUBLIC_IDS_DATA[] = { "+//silmaril//dtd html pro v0r11 19970101//", "-//advasoft ltd//dtd html 3.0 aswedit + extensions//", "-//as//dtd html 3.0 aswedit + extensions//", "-//ietf//dtd html 2.0 level 1//", "-//ietf//dtd html 2.0 level 2//", "-//ietf//dtd html 2.0 strict level 1//", "-//ietf//dtd html 2.0 strict level 2//", "-//ietf//dtd html 2.0 strict//", "-//ietf//dtd html 2.0//", "-//ietf//dtd html 2.1e//", "-//ietf//dtd html 3.0//", "-//ietf//dtd html 3.2 final//", "-//ietf//dtd html 3.2//", "-//ietf//dtd html 3//", "-//ietf//dtd html level 0//", "-//ietf//dtd html level 1//", "-//ietf//dtd html level 2//", "-//ietf//dtd html level 3//", "-//ietf//dtd html strict level 0//", "-//ietf//dtd html strict level 1//", "-//ietf//dtd html strict level 2//", "-//ietf//dtd html strict level 3//", "-//ietf//dtd html strict//", "-//ietf//dtd html//", "-//metrius//dtd metrius presentational//", "-//microsoft//dtd internet explorer 2.0 html strict//", "-//microsoft//dtd internet explorer 2.0 html//", "-//microsoft//dtd internet explorer 2.0 tables//", "-//microsoft//dtd internet explorer 3.0 html strict//", "-//microsoft//dtd internet explorer 3.0 html//", "-//microsoft//dtd internet explorer 3.0 tables//", "-//netscape comm. corp.//dtd html//", "-//netscape comm. corp.//dtd strict html//", "-//o'reilly and associates//dtd html 2.0//", "-//o'reilly and associates//dtd html extended 1.0//", "-//o'reilly and associates//dtd html extended relaxed 1.0//", "-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//", "-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//", "-//spyglass//dtd html 2.0 extended//", "-//sq//dtd html 2.0 hotmetal + extensions//", "-//sun microsystems corp.//dtd hotjava html//", "-//sun microsystems corp.//dtd hotjava strict html//", "-//w3c//dtd html 3 1995-03-24//", "-//w3c//dtd html 3.2 draft//", "-//w3c//dtd html 3.2 final//", "-//w3c//dtd html 3.2//", "-//w3c//dtd html 3.2s draft//", "-//w3c//dtd html 4.0 frameset//", "-//w3c//dtd html 4.0 transitional//", "-//w3c//dtd html experimental 19960712//", "-//w3c//dtd html experimental 970421//", "-//w3c//dtd w3 html//", "-//w3o//dtd w3 html 3.0//", "-//webtechs//dtd mozilla html 2.0//", "-//webtechs//dtd mozilla html//" };
+staticJArray<const char*,PRInt32> nsHtml5TreeBuilder::QUIRKY_PUBLIC_IDS = { QUIRKY_PUBLIC_IDS_DATA, NS_ARRAY_LENGTH(QUIRKY_PUBLIC_IDS_DATA) };
 void 
 nsHtml5TreeBuilder::startTokenization(nsHtml5Tokenizer* self)
 {
   tokenizer = self;
-  stack = jArray<nsHtml5StackNode*,PRInt32>(64);
-  listOfActiveFormattingElements = jArray<nsHtml5StackNode*,PRInt32>(64);
+  stack = jArray<nsHtml5StackNode*,PRInt32>::newJArray(64);
+  listOfActiveFormattingElements = jArray<nsHtml5StackNode*,PRInt32>::newJArray(64);
   needToDropLF = PR_FALSE;
   originalMode = NS_HTML5TREE_BUILDER_INITIAL;
   currentPtr = -1;
   listPtr = -1;
   ;
   formPointer = nsnull;
   ;
   headPointer = nsnull;
   ;
   deepTreeSurrogateParent = nsnull;
   start(fragment);
   charBufferLen = 0;
-  charBuffer = jArray<PRUnichar,PRInt32>(1024);
+  charBuffer = jArray<PRUnichar,PRInt32>::newJArray(1024);
   framesetOk = PR_TRUE;
   if (fragment) {
     nsIContent** elt;
     if (contextNode) {
       elt = contextNode;
       ;
     } else {
       elt = createHtmlElementSetAsRoot(tokenizer->emptyAttributes());
@@ -540,33 +543,28 @@ nsHtml5TreeBuilder::endTokenization()
   headPointer = nsnull;
   ;
   deepTreeSurrogateParent = nsnull;
   if (stack) {
     while (currentPtr > -1) {
       stack[currentPtr]->release();
       currentPtr--;
     }
-    stack.release();
     stack = nsnull;
   }
   if (listOfActiveFormattingElements) {
     while (listPtr > -1) {
       if (listOfActiveFormattingElements[listPtr]) {
         listOfActiveFormattingElements[listPtr]->release();
       }
       listPtr--;
     }
-    listOfActiveFormattingElements.release();
     listOfActiveFormattingElements = nsnull;
   }
-  if (charBuffer) {
-    charBuffer.release();
-    charBuffer = nsnull;
-  }
+  charBuffer = nsnull;
   end();
 }
 
 void 
 nsHtml5TreeBuilder::startTag(nsHtml5ElementName* elementName, nsHtml5HtmlAttributes* attributes, PRBool selfClosing)
 {
   flushCharacters();
   PRInt32 eltPos;
@@ -1124,19 +1122,18 @@ nsHtml5TreeBuilder::startTag(nsHtml5Elem
               if (actionIndex > -1) {
                 formAttrs->addAttribute(nsHtml5AttributeName::ATTR_ACTION, attributes->getValue(actionIndex));
               }
               appendToCurrentNodeAndPushFormElementMayFoster(formAttrs);
               appendVoidElementToCurrentMayFoster(kNameSpaceID_XHTML, nsHtml5ElementName::ELT_HR, nsHtml5HtmlAttributes::EMPTY_ATTRIBUTES);
               appendToCurrentNodeAndPushElementMayFoster(kNameSpaceID_XHTML, nsHtml5ElementName::ELT_LABEL, nsHtml5HtmlAttributes::EMPTY_ATTRIBUTES);
               PRInt32 promptIndex = attributes->getIndex(nsHtml5AttributeName::ATTR_PROMPT);
               if (promptIndex > -1) {
-                jArray<PRUnichar,PRInt32> prompt = nsHtml5Portability::newCharArrayFromString(attributes->getValue(promptIndex));
+                autoJArray<PRUnichar,PRInt32> prompt = nsHtml5Portability::newCharArrayFromString(attributes->getValue(promptIndex));
                 appendCharacters(stack[currentPtr]->node, prompt, 0, prompt.length);
-                prompt.release();
               } else {
                 appendIsindexPrompt(stack[currentPtr]->node);
               }
               nsHtml5HtmlAttributes* inputAttributes = new nsHtml5HtmlAttributes(0);
               inputAttributes->addAttribute(nsHtml5AttributeName::ATTR_NAME, nsHtml5Portability::newStringFromLiteral("isindex"));
               for (PRInt32 i = 0; i < attributes->getLength(); i++) {
                 nsHtml5AttributeName* attributeQName = attributes->getAttributeName(i);
                 if (nsHtml5AttributeName::ATTR_NAME == attributeQName || nsHtml5AttributeName::ATTR_PROMPT == attributeQName) {
@@ -1829,17 +1826,17 @@ nsHtml5TreeBuilder::isSpecialParentInFor
 }
 
 nsString* 
 nsHtml5TreeBuilder::extractCharsetFromContent(nsString* attributeValue)
 {
   PRInt32 charsetState = NS_HTML5TREE_BUILDER_CHARSET_INITIAL;
   PRInt32 start = -1;
   PRInt32 end = -1;
-  jArray<PRUnichar,PRInt32> buffer = nsHtml5Portability::newCharArrayFromString(attributeValue);
+  autoJArray<PRUnichar,PRInt32> buffer = nsHtml5Portability::newCharArrayFromString(attributeValue);
   for (PRInt32 i = 0; i < buffer.length; i++) {
     PRUnichar c = buffer[i];
     switch(charsetState) {
       case NS_HTML5TREE_BUILDER_CHARSET_INITIAL: {
         switch(c) {
           case 'c':
           case 'C': {
             charsetState = NS_HTML5TREE_BUILDER_CHARSET_C;
@@ -2015,17 +2012,16 @@ nsHtml5TreeBuilder::extractCharsetFromCo
   charsetloop_end: ;
   nsString* charset = nsnull;
   if (start != -1) {
     if (end == -1) {
       end = buffer.length;
     }
     charset = nsHtml5Portability::newStringFromBuffer(buffer, start, end - start);
   }
-  buffer.release();
   return charset;
 }
 
 void 
 nsHtml5TreeBuilder::checkMetaCharset(nsHtml5HtmlAttributes* attributes)
 {
   nsString* content = attributes->getValue(nsHtml5AttributeName::ATTR_CONTENT);
   nsString* internalCharsetLegacy = nsnull;
@@ -3076,46 +3072,43 @@ nsHtml5TreeBuilder::clearLastListSlot()
   return PR_TRUE;
 }
 
 void 
 nsHtml5TreeBuilder::push(nsHtml5StackNode* node)
 {
   currentPtr++;
   if (currentPtr == stack.length) {
-    jArray<nsHtml5StackNode*,PRInt32> newStack = jArray<nsHtml5StackNode*,PRInt32>(stack.length + 64);
+    jArray<nsHtml5StackNode*,PRInt32> newStack = jArray<nsHtml5StackNode*,PRInt32>::newJArray(stack.length + 64);
     nsHtml5ArrayCopy::arraycopy(stack, newStack, stack.length);
-    stack.release();
     stack = newStack;
   }
   stack[currentPtr] = node;
   elementPushed(node->ns, node->popName, node->node);
 }
 
 void 
 nsHtml5TreeBuilder::silentPush(nsHtml5StackNode* node)
 {
   currentPtr++;
   if (currentPtr == stack.length) {
-    jArray<nsHtml5StackNode*,PRInt32> newStack = jArray<nsHtml5StackNode*,PRInt32>(stack.length + 64);
+    jArray<nsHtml5StackNode*,PRInt32> newStack = jArray<nsHtml5StackNode*,PRInt32>::newJArray(stack.length + 64);
     nsHtml5ArrayCopy::arraycopy(stack, newStack, stack.length);
-    stack.release();
     stack = newStack;
   }
   stack[currentPtr] = node;
 }
 
 void 
 nsHtml5TreeBuilder::append(nsHtml5StackNode* node)
 {
   listPtr++;
   if (listPtr == listOfActiveFormattingElements.length) {
-    jArray<nsHtml5StackNode*,PRInt32> newList = jArray<nsHtml5StackNode*,PRInt32>(listOfActiveFormattingElements.length + 64);
+    jArray<nsHtml5StackNode*,PRInt32> newList = jArray<nsHtml5StackNode*,PRInt32>::newJArray(listOfActiveFormattingElements.length + 64);
     nsHtml5ArrayCopy::arraycopy(listOfActiveFormattingElements, newList, listOfActiveFormattingElements.length);
-    listOfActiveFormattingElements.release();
     listOfActiveFormattingElements = newList;
   }
   listOfActiveFormattingElements[listPtr] = node;
 }
 
 void 
 nsHtml5TreeBuilder::clearTheListOfActiveFormattingElementsUpToTheLastMarker()
 {
@@ -3807,27 +3800,27 @@ nsHtml5TreeBuilder::charBufferContainsNo
     }
   }
   return PR_FALSE;
 }
 
 nsAHtml5TreeBuilderState* 
 nsHtml5TreeBuilder::newSnapshot()
 {
-  jArray<nsHtml5StackNode*,PRInt32> listCopy = jArray<nsHtml5StackNode*,PRInt32>(listPtr + 1);
+  jArray<nsHtml5StackNode*,PRInt32> listCopy = jArray<nsHtml5StackNode*,PRInt32>::newJArray(listPtr + 1);
   for (PRInt32 i = 0; i < listCopy.length; i++) {
     nsHtml5StackNode* node = listOfActiveFormattingElements[i];
     if (node) {
       nsHtml5StackNode* newNode = new nsHtml5StackNode(node->group, node->ns, node->name, node->node, node->scoping, node->special, node->fosterParenting, node->popName, node->attributes->cloneAttributes(nsnull));
       listCopy[i] = newNode;
     } else {
       listCopy[i] = nsnull;
     }
   }
-  jArray<nsHtml5StackNode*,PRInt32> stackCopy = jArray<nsHtml5StackNode*,PRInt32>(currentPtr + 1);
+  jArray<nsHtml5StackNode*,PRInt32> stackCopy = jArray<nsHtml5StackNode*,PRInt32>::newJArray(currentPtr + 1);
   for (PRInt32 i = 0; i < stackCopy.length; i++) {
     nsHtml5StackNode* node = stack[i];
     PRInt32 listIndex = findInListOfActiveFormattingElements(node);
     if (listIndex == -1) {
       nsHtml5StackNode* newNode = new nsHtml5StackNode(node->group, node->ns, node->name, node->node, node->scoping, node->special, node->fosterParenting, node->popName, nsnull);
       stackCopy[i] = newNode;
     } else {
       stackCopy[i] = listCopy[listIndex];
@@ -3874,26 +3867,24 @@ nsHtml5TreeBuilder::loadState(nsAHtml5Tr
   jArray<nsHtml5StackNode*,PRInt32> listCopy = snapshot->getListOfActiveFormattingElements();
   PRInt32 listLen = snapshot->getListOfActiveFormattingElementsLength();
   for (PRInt32 i = 0; i <= listPtr; i++) {
     if (listOfActiveFormattingElements[i]) {
       listOfActiveFormattingElements[i]->release();
     }
   }
   if (listOfActiveFormattingElements.length < listLen) {
-    listOfActiveFormattingElements.release();
-    listOfActiveFormattingElements = jArray<nsHtml5StackNode*,PRInt32>(listLen);
+    listOfActiveFormattingElements = jArray<nsHtml5StackNode*,PRInt32>::newJArray(listLen);
   }
   listPtr = listLen - 1;
   for (PRInt32 i = 0; i <= currentPtr; i++) {
     stack[i]->release();
   }
   if (stack.length < stackLen) {
-    stack.release();
-    stack = jArray<nsHtml5StackNode*,PRInt32>(stackLen);
+    stack = jArray<nsHtml5StackNode*,PRInt32>::newJArray(stackLen);
   }
   currentPtr = stackLen - 1;
   for (PRInt32 i = 0; i < listLen; i++) {
     nsHtml5StackNode* node = listCopy[i];
     if (node) {
       nsHtml5StackNode* newNode = new nsHtml5StackNode(node->group, node->ns, nsHtml5Portability::newLocalFromLocal(node->name, interner), node->node, node->scoping, node->special, node->fosterParenting, nsHtml5Portability::newLocalFromLocal(node->popName, interner), node->attributes->cloneAttributes(nsnull));
       listOfActiveFormattingElements[i] = newNode;
     } else {
@@ -4015,75 +4006,18 @@ PRInt32
 nsHtml5TreeBuilder::getStackLength()
 {
   return currentPtr + 1;
 }
 
 void
 nsHtml5TreeBuilder::initializeStatics()
 {
-  QUIRKY_PUBLIC_IDS = jArray<const char*,PRInt32>(55);
-  QUIRKY_PUBLIC_IDS[0] = "+//silmaril//dtd html pro v0r11 19970101//";
-  QUIRKY_PUBLIC_IDS[1] = "-//advasoft ltd//dtd html 3.0 aswedit + extensions//";
-  QUIRKY_PUBLIC_IDS[2] = "-//as//dtd html 3.0 aswedit + extensions//";
-  QUIRKY_PUBLIC_IDS[3] = "-//ietf//dtd html 2.0 level 1//";
-  QUIRKY_PUBLIC_IDS[4] = "-//ietf//dtd html 2.0 level 2//";
-  QUIRKY_PUBLIC_IDS[5] = "-//ietf//dtd html 2.0 strict level 1//";
-  QUIRKY_PUBLIC_IDS[6] = "-//ietf//dtd html 2.0 strict level 2//";
-  QUIRKY_PUBLIC_IDS[7] = "-//ietf//dtd html 2.0 strict//";
-  QUIRKY_PUBLIC_IDS[8] = "-//ietf//dtd html 2.0//";
-  QUIRKY_PUBLIC_IDS[9] = "-//ietf//dtd html 2.1e//";
-  QUIRKY_PUBLIC_IDS[10] = "-//ietf//dtd html 3.0//";
-  QUIRKY_PUBLIC_IDS[11] = "-//ietf//dtd html 3.2 final//";
-  QUIRKY_PUBLIC_IDS[12] = "-//ietf//dtd html 3.2//";
-  QUIRKY_PUBLIC_IDS[13] = "-//ietf//dtd html 3//";
-  QUIRKY_PUBLIC_IDS[14] = "-//ietf//dtd html level 0//";
-  QUIRKY_PUBLIC_IDS[15] = "-//ietf//dtd html level 1//";
-  QUIRKY_PUBLIC_IDS[16] = "-//ietf//dtd html level 2//";
-  QUIRKY_PUBLIC_IDS[17] = "-//ietf//dtd html level 3//";
-  QUIRKY_PUBLIC_IDS[18] = "-//ietf//dtd html strict level 0//";
-  QUIRKY_PUBLIC_IDS[19] = "-//ietf//dtd html strict level 1//";
-  QUIRKY_PUBLIC_IDS[20] = "-//ietf//dtd html strict level 2//";
-  QUIRKY_PUBLIC_IDS[21] = "-//ietf//dtd html strict level 3//";
-  QUIRKY_PUBLIC_IDS[22] = "-//ietf//dtd html strict//";
-  QUIRKY_PUBLIC_IDS[23] = "-//ietf//dtd html//";
-  QUIRKY_PUBLIC_IDS[24] = "-//metrius//dtd metrius presentational//";
-  QUIRKY_PUBLIC_IDS[25] = "-//microsoft//dtd internet explorer 2.0 html strict//";
-  QUIRKY_PUBLIC_IDS[26] = "-//microsoft//dtd internet explorer 2.0 html//";
-  QUIRKY_PUBLIC_IDS[27] = "-//microsoft//dtd internet explorer 2.0 tables//";
-  QUIRKY_PUBLIC_IDS[28] = "-//microsoft//dtd internet explorer 3.0 html strict//";
-  QUIRKY_PUBLIC_IDS[29] = "-//microsoft//dtd internet explorer 3.0 html//";
-  QUIRKY_PUBLIC_IDS[30] = "-//microsoft//dtd internet explorer 3.0 tables//";
-  QUIRKY_PUBLIC_IDS[31] = "-//netscape comm. corp.//dtd html//";
-  QUIRKY_PUBLIC_IDS[32] = "-//netscape comm. corp.//dtd strict html//";
-  QUIRKY_PUBLIC_IDS[33] = "-//o'reilly and associates//dtd html 2.0//";
-  QUIRKY_PUBLIC_IDS[34] = "-//o'reilly and associates//dtd html extended 1.0//";
-  QUIRKY_PUBLIC_IDS[35] = "-//o'reilly and associates//dtd html extended relaxed 1.0//";
-  QUIRKY_PUBLIC_IDS[36] = "-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//";
-  QUIRKY_PUBLIC_IDS[37] = "-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//";
-  QUIRKY_PUBLIC_IDS[38] = "-//spyglass//dtd html 2.0 extended//";
-  QUIRKY_PUBLIC_IDS[39] = "-//sq//dtd html 2.0 hotmetal + extensions//";
-  QUIRKY_PUBLIC_IDS[40] = "-//sun microsystems corp.//dtd hotjava html//";
-  QUIRKY_PUBLIC_IDS[41] = "-//sun microsystems corp.//dtd hotjava strict html//";
-  QUIRKY_PUBLIC_IDS[42] = "-//w3c//dtd html 3 1995-03-24//";
-  QUIRKY_PUBLIC_IDS[43] = "-//w3c//dtd html 3.2 draft//";
-  QUIRKY_PUBLIC_IDS[44] = "-//w3c//dtd html 3.2 final//";
-  QUIRKY_PUBLIC_IDS[45] = "-//w3c//dtd html 3.2//";
-  QUIRKY_PUBLIC_IDS[46] = "-//w3c//dtd html 3.2s draft//";
-  QUIRKY_PUBLIC_IDS[47] = "-//w3c//dtd html 4.0 frameset//";
-  QUIRKY_PUBLIC_IDS[48] = "-//w3c//dtd html 4.0 transitional//";
-  QUIRKY_PUBLIC_IDS[49] = "-//w3c//dtd html experimental 19960712//";
-  QUIRKY_PUBLIC_IDS[50] = "-//w3c//dtd html experimental 970421//";
-  QUIRKY_PUBLIC_IDS[51] = "-//w3c//dtd w3 html//";
-  QUIRKY_PUBLIC_IDS[52] = "-//w3o//dtd w3 html 3.0//";
-  QUIRKY_PUBLIC_IDS[53] = "-//webtechs//dtd mozilla html 2.0//";
-  QUIRKY_PUBLIC_IDS[54] = "-//webtechs//dtd mozilla html//";
 }
 
 void
 nsHtml5TreeBuilder::releaseStatics()
 {
-  QUIRKY_PUBLIC_IDS.release();
 }
 
 
 #include "nsHtml5TreeBuilderCppSupplement.h"
 
--- a/parser/html/nsHtml5TreeBuilder.h
+++ b/parser/html/nsHtml5TreeBuilder.h
@@ -65,39 +65,39 @@ class nsHtml5UTF16Buffer;
 class nsHtml5StateSnapshot;
 class nsHtml5Portability;
 
 
 class nsHtml5TreeBuilder : public nsAHtml5TreeBuilderState
 {
   private:
     static PRUnichar REPLACEMENT_CHARACTER[];
-    static jArray<const char*,PRInt32> QUIRKY_PUBLIC_IDS;
+    static staticJArray<const char*,PRInt32> QUIRKY_PUBLIC_IDS;
     PRInt32 mode;
     PRInt32 originalMode;
     PRBool framesetOk;
     PRBool inForeign;
   protected:
     nsHtml5Tokenizer* tokenizer;
   private:
     PRBool scriptingEnabled;
     PRBool needToDropLF;
     PRBool fragment;
     nsIAtom* contextName;
     PRInt32 contextNamespace;
     nsIContent** contextNode;
-    jArray<nsHtml5StackNode*,PRInt32> stack;
+    autoJArray<nsHtml5StackNode*,PRInt32> stack;
     PRInt32 currentPtr;
-    jArray<nsHtml5StackNode*,PRInt32> listOfActiveFormattingElements;
+    autoJArray<nsHtml5StackNode*,PRInt32> listOfActiveFormattingElements;
     PRInt32 listPtr;
     nsIContent** formPointer;
     nsIContent** headPointer;
     nsIContent** deepTreeSurrogateParent;
   protected:
-    jArray<PRUnichar,PRInt32> charBuffer;
+    autoJArray<PRUnichar,PRInt32> charBuffer;
     PRInt32 charBufferLen;
   private:
     PRBool quirks;
   public:
     void startTokenization(nsHtml5Tokenizer* self);
     void doctype(nsIAtom* name, nsString* publicIdentifier, nsString* systemIdentifier, PRBool forceQuirks);
     void comment(PRUnichar* buf, PRInt32 start, PRInt32 length);
     void characters(const PRUnichar* buf, PRInt32 start, PRInt32 length);
@@ -240,21 +240,16 @@ class nsHtml5TreeBuilder : public nsAHtm
     PRInt32 getListOfActiveFormattingElementsLength();
     PRInt32 getStackLength();
     static void initializeStatics();
     static void releaseStatics();
 
 #include "nsHtml5TreeBuilderHSupplement.h"
 };
 
-#ifdef nsHtml5TreeBuilder_cpp__
-PRUnichar nsHtml5TreeBuilder::REPLACEMENT_CHARACTER[] = { 0xfffd };
-jArray<const char*,PRInt32> nsHtml5TreeBuilder::QUIRKY_PUBLIC_IDS = nsnull;
-#endif
-
 #define NS_HTML5TREE_BUILDER_OTHER 0
 #define NS_HTML5TREE_BUILDER_A 1
 #define NS_HTML5TREE_BUILDER_BASE 2
 #define NS_HTML5TREE_BUILDER_BODY 3
 #define NS_HTML5TREE_BUILDER_BR 4
 #define NS_HTML5TREE_BUILDER_BUTTON 5
 #define NS_HTML5TREE_BUILDER_CAPTION 6
 #define NS_HTML5TREE_BUILDER_COL 7
--- a/parser/html/nsHtml5TreeBuilderCppSupplement.h
+++ b/parser/html/nsHtml5TreeBuilderCppSupplement.h
@@ -562,19 +562,18 @@ nsHtml5TreeBuilder::elementPopped(PRInt3
 }
 
 void
 nsHtml5TreeBuilder::accumulateCharacters(const PRUnichar* aBuf, PRInt32 aStart, PRInt32 aLength)
 {
   PRInt32 newFillLen = charBufferLen + aLength;
   if (newFillLen > charBuffer.length) {
     PRInt32 newAllocLength = newFillLen + (newFillLen >> 1);
-    jArray<PRUnichar,PRInt32> newBuf(newAllocLength);
+    jArray<PRUnichar,PRInt32> newBuf = jArray<PRUnichar,PRInt32>::newJArray(newAllocLength);
     memcpy(newBuf, charBuffer, sizeof(PRUnichar) * charBufferLen);
-    charBuffer.release();
     charBuffer = newBuf;
   }
   memcpy(charBuffer + charBufferLen, aBuf + aStart, sizeof(PRUnichar) * aLength);
   charBufferLen = newFillLen;
 }
 
 nsIContent**
 nsHtml5TreeBuilder::AllocateContentHandle()
--- a/parser/html/nsHtml5UTF16Buffer.h
+++ b/parser/html/nsHtml5UTF16Buffer.h
@@ -75,15 +75,12 @@ class nsHtml5UTF16Buffer
     void adjust(PRBool lastWasCR);
     void setEnd(PRInt32 end);
     static void initializeStatics();
     static void releaseStatics();
 
 #include "nsHtml5UTF16BufferHSupplement.h"
 };
 
-#ifdef nsHtml5UTF16Buffer_cpp__
-#endif
-
 
 
 #endif