function swap7 (a,b)
if nargin ~=2
    error('swap7 requires two arguments')
end
actual_a=inputname(1);
actual_b=inputname(2);
if ~isempty(actual_a) & ~isempty(actual_b)
    assignin('caller',actual_b,a)
    assignin('caller',actual_a,b) % no need for temp!
else
    error('arguments to swap must be variables, not expressions')
end