INNER CODE UNIT · Python

remove_function

tanersener/mobile-ffmpeg · src/libsndfile/make_lite.py:88

def remove_function (source, func_name):
	func_text = find_function_definition (source, func_name)
	if not func_text:
		print "remove_function : function '%s' not found. Exiting." % func_name
		sys.exit (1)

	source = string.replace (source, func_text, "/* Function %s() removed here. */\n" % func_name)
	return source

def remove_all_assignments (source, var):
	count = 0
	while 1:
		assign_text = find_assign_statement (source, var)
		if not assign_text:
			if count != 0:
				break
			print "remove_all_assignments : variable '%s' not found. Exiting." % var
			sys.exit (1)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…