public static boolean shouldIncludeFunction(Function fn) {
		if (Directives.has(fn, "keep") || Directives.has(fn, "export") || Directives.has(fn, "main")) {
			return true;
		}
		if (Directives.has(fn, "inline") || Directives.has(fn, "native") || Directives.has(fn, "!keep")) {
			return false;
		}
		if (fn.isCompiled() && !fn.isLibrary()) {
			if (fn.references!=0) {
				return true;
			}
		}
		return false;
	}