Your current description could use clarification - calling functions and assigning them to local variables generally doesn't do anything useful except for the side effects of the calls.
Also if the two methods were exactly the same code as your question suggests then you'd really only need one method, and call that from the places where you now call the two differently named but the same methods..
My best guess is that your actual situation could benefit from applying the extract method refactoring.
You would turn this:
MethodA() {
var a = CallA();
var b = CallB();
// .. Code specific to MethodA ...
}
MethodB() {
var a = CallA();
var b = CallB();
// .. Code specific to MethodB ...
}
into this:
ExtractedMethod() {
var a = CallA();
var b = CallB();
}
MethodA() {
ExtractedMethod();
// .. Code specific to MethodA ...
}
MethodB() {
ExtractedMethod();
// .. Code specific to MethodB ...
}