#NEWLINE# def do_get_language_info( parser , token ) : #NEWLINE# #INDENT# '\n    This will store the language information dictionary for the given language\n    code in a context variable.\n\n    Usage::\n\n        {% get_language_info for LANGUAGE_CODE as l %}\n        {{ l.code }}\n        {{ l.name }}\n        {{ l.name_local }}\n        {{ l.bidi|yesno:"bi-directional,uni-directional" }}\n    ' #NEWLINE# args = token . contents . split ( ) #NEWLINE# if ( ( len ( args ) != 5 ) or ( args [ 1 ] != 'for' ) or ( args [ 3 ] != 'as' ) ) : #NEWLINE# #INDENT# raise TemplateSyntaxError ( ( "'%s' requires 'for string as variable' (got %r)" % ( args [ 0 ] , args [ 1 : ] ) ) ) #NEWLINE# #UNINDENT# return GetLanguageInfoNode ( args [ 2 ] , token [ 4 ] )