0

Suppose if code in a module A calls a function from another module B, do we have to rebuild A when we make a small change to the said function considering that the function blueprint remains the same.

My doubt comes from the fact that subroutines in assembly call the functions using line numbers, so if we modify the code, the assembly code is modified and the line number changes. So would the code in module A still be able to call the function if it's not recompiled?

Sharan J
  • 23
  • 1
  • 6
  • 1
    If the signature didn't change you can just use it. – M. Deinum Feb 01 '22 at 10:26
  • 2
    Java bytecode is not assembly, but anyway, neither bytecode nor assembly uses line numbers. There’s a reason for compiling source code to something easier to process for machines. We want to avoid expensive interpretation of text at runtime and searching for line break characters and counting them is comparatively expensive. – Holger Feb 01 '22 at 11:36

0 Answers0