-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix/tested haskell judge #543
base: master
Are you sure you want to change the base?
Conversation
@@ -28,6 +29,10 @@ | |||
|
|||
|
|||
class Haskell(Language): | |||
def __init__(self, config: Optional["GlobalConfig"]): | |||
super().__init__(config) | |||
self.clean_types_regex = re.compile(r"\(([^:\s]*)\s*::\s*([A-Z][a-zA-Z0-9]*)\)") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should be a constant instead of a variable,
So CLEAN_TYPES_REGEX =
Also is this regex completly save? Eg is it possible that it also matches a type expression within a string?
If typing is optional, it would probably be better not to add the type declarations in 'generators.py', instead of adding them there, running the tests with typing and then obfuscating those types to the end user.
@@ -48,37 +48,37 @@ def convert_value(value: Value) -> str: | |||
return f"({convert_arguments(value.data)})" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is where I would remove the typing information.
But i am not an expert on TESTed nor haskell so I am not sure it will work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see previous comments
This pull requests: