merged version. compilation passed.