  def do_if(parser, token):
      """
      The ``{% if %}`` tag evaluates a variable, and if that variable is "true"
      (i.e. exists, is not empty, and is not a false boolean value) the contents
      of the block are output:
  
      ::
  
          {% if athlete_list %}
              Number of athletes: {{ athlete_list|count }}
          {% else %}
              No athletes.
 
</s> remove     As you can see, the ``if`` tag can take an option ``{% else %}`` clause that
    will be displayed if the test fails.
 </s> add     As you can see, the ``if`` tag can take an option ``{% else %}`` clause
    that will be displayed if the test fails. </s> remove     2. If given a variable, check whether that variable has changed. For example, the
       following shows the date every time it changes, but only shows the hour if both
       the hour and the date have changed::
 </s> add     2. If given a variable, check whether that variable has changed.
       For example, the following shows the date every time it changes, but
       only shows the hour if both the hour and the date have changed:: </s> remove     """Output the contents of the block if the two arguments are not equal. See ifequal."""
 </s> add     """
    Outputs the contents of the block if the two arguments are not equal.
    See ifequal.
    """ </s> remove     ``if`` tags do not allow ``and`` and ``or`` clauses with the same
    tag, because the order of logic would be ambigous. For example,
    this is invalid::
 </s> add     ``if`` tags do not allow ``and`` and ``or`` clauses with the same tag,
    because the order of logic would be ambigous. For example, this is
    invalid:: </s> remove     people was not sorted by gender, you'd need to make sure it is sorted before
    using it, i.e.::
 </s> add     people was not sorted by gender, you'd need to make sure it is sorted
    before using it, i.e.::
    of the block are output::
  def do_if(parser, token):
      """
      The ``{% if %}`` tag evaluates a variable, and if that variable is "true"
      (i.e. exists, is not empty, and is not a false boolean value) the contents
    of the block are output::
    of the block are output::
    of the block are output::
  
          {% if athlete_list %}
              Number of athletes: {{ athlete_list|count }}
          {% else %}
              No athletes.
keep keep keep keep replace replace replace keep keep keep keep keep
 Style and import fixes.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6641 bcc190cf-cafb-0310-a4f2-bffc1f526a37 
django/template/defaulttags.py