module Sprockets::Utils

def string_end_with_semicolon?(str)

Returns true or false.

str - String

Internal: Check if string has a trailing semicolon.
def string_end_with_semicolon?(str)
  i = str.size - 1
  while i >= 0
    c = str[i]
    i -= 1
    if c == "\n" || c == " " || c == "\t"
      next
    elsif c != ";"
      return false
    else
      return true
    end
  end
  true
end