semantic checking added

semantic checking added to frontend,
error messages must be improved