title: Exception raised during rendering: com.android.layoutlib.bridge.MockView cannot be cast to android.view.ViewGroup
body: <p>I'm working on this android project on eclipse. I created two gridLayouts and a text field on main activity. It keeps on showing this warning in a window "The following classes could not be instantiated:
  - android.support.v7.widget.GridLayout (Open Class, Show Error Log)" but as i try to add a button to the GridLayout, the activity freezes and now it shows following message "NOTE: This project contains Java compilation errors, which can cause rendering failures for custom views. Fix compilation problems first.</p>
  
  <p>Exception raised during rendering: com.android.layoutlib.bridge.MockView cannot be cast to android.view.ViewGroup
  Exception details are logged in Window > Show View > Error Log
  The following classes could not be instantiated:
  - android.support.v7.widget.GridLayout (Open Class, Show Error Log)" My xml file is:</p>
  
  <pre><code>&lt;FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:tools="http://schemas.android.com/tools"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:background="#0099cc"
      tools:context=".MainActivity"
      xmlns:app="http://schemas.android.com/apk/res/com.example.simple_calculator"&gt;
  
      &lt;TextView
          android:id="@+id/textView1"
          android:layout_width="match_parent"
          android:layout_height="94dp"
          android:text=""
          android:textAppearance="?android:attr/textAppearanceLarge" /&gt;
  
      &lt;android.support.v7.widget.GridLayout
          android:layout_width="wrap_content"
          android:layout_height="match_parent"
          android:layout_marginLeft="232dp"
          android:layout_marginTop="100dp" &gt;
      &lt;/android.support.v7.widget.GridLayout&gt;
  
      &lt;android.support.v7.widget.GridLayout
          android:layout_width="232dp"
          android:layout_height="match_parent"
          android:layout_marginTop="100dp"
          app:columnCount="1" &gt;
  
          &lt;Button
              android:id="@+id/button1"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              app:layout_column="0"
              app:layout_gravity="left|top"
              app:layout_row="0"
              android:text="Button" /&gt;
  
      &lt;/android.support.v7.widget.GridLayout&gt;
  &lt;/FrameLayout&gt;
  </code></pre>
  
  <p>I already tried importing android-sdk-[platform]/extras/android/support/v7/gridlayout, but still same error.</p>