Refactoring some types based on the feedback given, fixed operator precedence and made a small bugfix in the type checker