Like this…
function doSomething(url, elem) {
$.ajax({
type: "GET",
url: url,
dataType: "xml",
success: function(xml) {
rssToTarget(xml, elem);
}
});
}
Answer to your comment: Does use of anonymous functions affect performance?