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

some minor fixes #176

Merged
merged 6 commits into from
Feb 27, 2024
Merged

some minor fixes #176

merged 6 commits into from
Feb 27, 2024

Conversation

felipensp
Copy link
Member

@felipensp felipensp commented Feb 17, 2024

This PR fixes some minor issues spotted translating TCC source.

  • case label without space
  • missing braces on case
  • missing escape char \r, \v, \t, \f handling
  • sizeof*var to sizeof(*var)
  • add fn to keyword
  • add __FUNCTION__ predefined
  • [export] to @[export]
  • s....field to s.field

@felipensp felipensp changed the title minor fixes -x case stmt some minor fixes Feb 17, 2024
@@ -1099,6 +1105,7 @@ fn (mut c C2V) case_st(mut child Node, is_enum bool) bool {
}
vprintln('A TYP=${a.ast_type}')
if a.kindof(.compound_stmt) {
c.genln(' {')
Copy link
Member

Choose a reason for hiding this comment

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

hm, why is that not not balanced with a } here?

Copy link
Member

@spytheman spytheman left a comment

Choose a reason for hiding this comment

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

Excellent work.

@spytheman spytheman merged commit b0dc0fa into master Feb 27, 2024
6 checks passed
@spytheman spytheman deleted the fix_case_stmt branch February 27, 2024 09:30
@felipensp felipensp restored the fix_case_stmt branch March 1, 2024 14:04
@felipensp felipensp deleted the fix_case_stmt branch March 1, 2024 14:07
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.

2 participants