(parser, token)
return NoBlankNode(nodelist, recurse=recurse, noeol=True)
Suppress all empty lines unless explicitly added.
Suppress all empty lines unless explicitly added.
Suppress all empty lines unless explicitly added .
def DoNoEol(parser, token):
  """Suppress all empty lines unless explicitly added."""
  args = token.split_contents()
  if len(args) > 2:
    raise django_template.TemplateSyntaxError(
        'noeol expects at most one argument')
  if len(args) == 2:
    recursearg = args[1]
    if recursearg not in ('recurse', 'norecurse'):
      raise django_template.TemplateSyntaxError(
          'argument to noeol must be either "norecurse" '
          '(the default) or "recurse"')
    recurse = recursearg == 'recurse'
  else:
    recurse = False

  nodelist = parser.parse(('endnoeol',))
  parser.delete_first_token()
  return NoBlankNode(nodelist, recurse=recurse, noeol=True)
def DoNoEol ( parser , token ) : args = token . split_contents ( ) if len ( args ) > 2 : raise django_template . TemplateSyntaxError ( 'noeol expects at most one argument' ) if len ( args ) == 2 : recursearg = args [ 1 ] if recursearg not in ( 'recurse' , 'norecurse' ) : raise django_template . TemplateSyntaxError ( 'argument to noeol must be either "norecurse" ' '(the default) or "recurse"' ) recurse = recursearg == 'recurse' else : recurse = False nodelist = parser . parse ( ( 'endnoeol' , ) ) parser . delete_first_token ( ) return NoBlankNode ( nodelist , recurse = recurse , noeol = True )