Properly handle common symbol and weak function