parameters: (line, shell=False)
docstring: Parses a string expression such as '${CC} ${SRC} -o ${TGT}' and returns a pair containing:
  
  	* The function created (compiled) for use as :py:meth:`waflib.Task.Task.run`
  	* The list of variables that must cause rebuilds when *env* data is modified
  
  	for example::
  
  		from waflib.Task import compile_fun
  		compile_fun('cxx', '${CXX} -o ${TGT[0]} ${SRC} -I ${SRC[0].parent.bldpath()}')
  
  		def build(bld):
  			bld(source='wscript', rule='echo "foo\\${SRC[0].name}\\bar"')
  
  	The env variables (CXX, ..) on the task must not hold dicts so as to preserve a consistent order.
  	The reserved keywords ``TGT`` and ``SRC`` represent the task input and output nodes
docstring_summary: Parses a string expression such as '${CC} ${SRC} -o ${TGT}' and returns a pair containing:
docstring_tokens: Parses a string expression such as $ { CC } $ { SRC } - o $ { TGT } and returns a pair containing :
function: def compile_fun(line, shell=False):
  	"""
  	Parses a string expression such as '${CC} ${SRC} -o ${TGT}' and returns a pair containing:
  
  	* The function created (compiled) for use as :py:meth:`waflib.Task.Task.run`
  	* The list of variables that must cause rebuilds when *env* data is modified
  
  	for example::
  
  		from waflib.Task import compile_fun
  		compile_fun('cxx', '${CXX} -o ${TGT[0]} ${SRC} -I ${SRC[0].parent.bldpath()}')
  
  		def build(bld):
  			bld(source='wscript', rule='echo "foo\\${SRC[0].name}\\bar"')
  
  	The env variables (CXX, ..) on the task must not hold dicts so as to preserve a consistent order.
  	The reserved keywords ``TGT`` and ``SRC`` represent the task input and output nodes
  
  	"""
  	if isinstance(line, str):
  		if line.find('<') > 0 or line.find('>') > 0 or line.find('&&') > 0:
  			shell = True
  	else:
  		dvars_lst = []
  		funs_lst = []
  		for x in line:
  			if isinstance(x, str):
  				fun, dvars = compile_fun(x, shell)
  				dvars_lst += dvars
  				funs_lst.append(fun)
  			else:
  				# assume a function to let through
  				funs_lst.append(x)
  		def composed_fun(task):
  			for x in funs_lst:
  				ret = x(task)
  				if ret:
  					return ret
  			return None
  		return composed_fun, dvars_lst
  	if shell:
  		return compile_fun_shell(line)
  	else:
  		return compile_fun_noshell(line)
function_tokens: def compile_fun ( line , shell = False ) : if isinstance ( line , str ) : if line . find ( '<' ) > 0 or line . find ( '>' ) > 0 or line . find ( '&&' ) > 0 : shell = True else : dvars_lst = [ ] funs_lst = [ ] for x in line : if isinstance ( x , str ) : fun , dvars = compile_fun ( x , shell ) dvars_lst += dvars funs_lst . append ( fun ) else : # assume a function to let through funs_lst . append ( x ) def composed_fun ( task ) : for x in funs_lst : ret = x ( task ) if ret : return ret return None return composed_fun , dvars_lst if shell : return compile_fun_shell ( line ) else : return compile_fun_noshell ( line )