Skip to content
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

Fixed memory leaks in parser #23

Merged
merged 1 commit into from
Mar 11, 2024
Merged

Fixed memory leaks in parser #23

merged 1 commit into from
Mar 11, 2024

Conversation

simon-staal
Copy link
Collaborator

@simon-staal simon-staal commented Mar 10, 2024

As discussed in #22, created a separate PR to fix the memory issues outlined in #21.

@simon-staal simon-staal requested review from Jpnock and Fiwo735 March 10, 2024 17:37
@@ -11,6 +11,7 @@
extern FILE *yyin;
int yylex(void);
void yyerror(const char *);
int yylex_destroy(void);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
int yylex_destroy(void);
int yylex_destroy(void);

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine in ide, github indentation just looks weird

Copy link
Collaborator

@Jpnock Jpnock Mar 10, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are using a tab. The rest of this block is using 4 spaces.

@@ -7,6 +7,7 @@
extern FILE *yyin;
int yylex(void);
void yyerror(const char *);
int yylex_destroy(void);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
int yylex_destroy(void);
int yylex_destroy(void);

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above

@Fiwo735
Copy link
Collaborator

Fiwo735 commented Mar 11, 2024

On a very side note, should the changes above also benefit lab 2?

@simon-staal simon-staal merged commit 0b74087 into main Mar 11, 2024
2 checks passed
@simon-staal simon-staal deleted the fix-mem-leak branch March 11, 2024 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants