Simple script with template class fails the compiler

 
MT5 build 2124 the compiler enters some sort of loosing it behavior with this simple script.
Any ideas?
class CItem
  {
   string            m_name;
                     CItem(string name) {m_name=name;}
   string            Name() {return(m_name);}
  };
template<typename T>
class CCollection<T>
  {
public:
   T                 m_data[];
   bool              Add(T item);
   CCollection<T>    Get();
  };
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
template<typename T>
bool CCollection::Add(T item)
  {
   ArrayResize(m_data,ArraySize(m_data)+1);
   m_data[ArraySize(m_data)-1)=item;
   return(true);
  }
template<typename T>
CCollection<T> CCollection::Get()
  {
   return(m_data);
  }
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//---
   CCollection<CItem *> c;

  }
 

Even changing to a bit more sensible script, same result. Compiler goes mad.

//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
class CItem
  {
public:
   string            m_name;
                     CItem(string name) {m_name=name;}
   string            Name() {return(m_name);}
  };
template<typename T>
class CCollection<T>
  {
public:
   T                 m_data[];
   bool              Add(T item);
   CCollection<T>    *Get();
  };
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
template<typename T>
bool CCollection::Add(T item)
  {
   ArrayResize(m_data,ArraySize(m_data)+1);
   m_data[ArraySize(m_data)-1)=item;
   return(true);
  }
template<typename T>
CCollection<T> CCollection::Get()
  {
   return(GetPointer(this));
  }
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//---
   CCollection<CItem *> c;

  }
 
Amir Yacoby:

Even changing to a bit more sensible script, same result. Compiler goes mad.

You have 3 errors/typos.

//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
class CItem
  {
public:
   string            m_name;
                     CItem(string name) {m_name=name;}
   string            Name() {return(m_name);}
  };
template<typename T>
class CCollection   
  {
public:
   T                 m_data[];
   bool              Add(T item);
   CCollection<T>    *Get();
  };
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
template<typename T>
bool CCollection::Add(T item)
  {
   ArrayResize(m_data,ArraySize(m_data)+1);
   m_data[ArraySize(m_data)-1]=item;
   return(true);
  }
template<typename T>
CCollection<T> *CCollection::Get()
  {
   return(GetPointer(this));
  }
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//---
   CCollection<CItem *> c;

  }