tweaking errors and warnings in compile