@Vrighty If you are typing in the expression in x from scratch then you can do this to obtain a procedure:
f := x -> 5 + x;
If the expression comes as the result of another calculation (say, the result of calling procedure blah, or solve, etc) then you can use unapply to obtain a procedure. You cannot use the arrow notation directly in this case and have it all work properly.
f := unapply(blah(x),x);
You cannot use the syntax f(x):=... and get it all to work properly, regardless of whether you start entering all the expressions by hand or if they arise as the results of computations.
Or you could use an expression and 2-argument eval (as I alluded to earlier):
f := 5+x;
You just wrote, "In the past, I have... Everything works just fine. I expected, if I do the same, I will get the same result...". The problem is that the worksheet makes syntax mistake after another. It is almost all done completely wrong. There are even parts which work because two later mistakes just happen to accomodate a prior one. But eventually it all tumbles down and becomes unworkable. It is riddled with statements like this, which are having effects,
F(x) := F(x);
F(k) := F[k];
F(x) := subs(x=y+c,F(x));
Procedures are created but then only ever used by calling them with their named parameter, which makes many more steps or much more complicated syntax than needed.
The best solution is to rip it all out and start again using only expressions. A smaller amount of corrections that will allow you to proceed along your path without it all becoming unworkable is as I suggested in my posted edits. (You could get rid of the initial unapply calls where expressions are first defined, yes. But you have to either use unapply or expressions and eval throughout, for the many instances of the other cases, and you cannot work it practically with the mis-used remember table assignments and indexed references.)
The posted document is one of the most muddled I've ever seen. That's OK, we all had to learn somewhere. But I find your resistance to suggestion alarming, given the severity of the muddle.
I cannot for the life of me understand why at least two people up-voted the question.