title: Rails: Unexpected tSYMBEG error
body: <p>I found several questions on the same topic but they all have some problem with punctuation(missed or added a comma). In my case, I get the following error when migrating</p>
  
  <blockquote>
    <p>SyntaxError: /home/<strong><em>/workspace/</em></strong>/app/models/user.rb:27:
    syntax error, unexpected tSYMBEG, expecting keyword_do or '{' or '('<br>
    has_many :roles, through :positions</p>
  </blockquote>
  
  <p>The user model:</p>
  
  <pre><code>class User &lt; ActiveRecord::Base
    has_many :positions
    has_many :roles, through :positions
  end
  </code></pre>
  
  <p>The role model:</p>
  
  <pre><code>class Role &lt; ActiveRecord::Base
    has_many :positions
    has_many :users, through :positions
  end
  </code></pre>
  
  <p>The position model:</p>
  
  <pre><code>class Position &lt; ActiveRecord::Base
    belongs_to :role
    belongs_to :user
  end
  </code></pre>
  
  <p>Any idea what might be the problem? Thank you!</p>