Если я понимаю ваше намерение:
debug::ShowIt = "`1`";
SetAttributes[System`ShowIt, HoldAll];
System`ShowIt[code__] := System`ShowIt[{code}];
System`ShowIt[code_] :=
With[{y = code},
Message[debug::ShowIt, HoldForm[code = y]];
y
];
In[5]:= ShowIt[2 + 2]
During evaluation of In[5]:= debug::ShowIt: 2 + 2 = 4
Out[5]= 4
In[6]:= Off[debug::ShowIt]
ShowIt[2 + 2]
Out[7]= 4