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

Basic struct definition support #72

Closed
6 tasks done
Tracked by #61 ...
ForNeVeR opened this issue Jan 16, 2022 · 0 comments · Fixed by #333
Closed
6 tasks done
Tracked by #61 ...

Basic struct definition support #72

ForNeVeR opened this issue Jan 16, 2022 · 0 comments · Fixed by #333
Assignees
Labels
area:compiler Related to code compilation or type checking kind:feature New feature or request

Comments

@ForNeVeR
Copy link
Owner

ForNeVeR commented Jan 16, 2022

Cesium should support basic struct definitions required for #61. For example, this:

/* The SHA-1 context. */
typedef struct {
	uint64_t total;
	uint32_t ihv[5];
	unsigned char buffer[64];
	int found_collision;
	int safe_hash;
	int detect_coll;
	int ubc_check;
	int reduced_round_coll;
	collision_block_callback callback;

	uint32_t ihv1[5];
	uint32_t ihv2[5];
	uint32_t m1[80];
	uint32_t m2[80];
	uint32_t states[80][5];
} SHA1_CTX;

Subtasks:

  • struct with primitive fields
  • unsigned char
  • (suddenly) functional type:
    typedef void(*collision_block_callback)(uint64_t, const uint32_t*, const uint32_t*, const uint32_t*, const uint32_t*);
  • primitive fixed arrays
  • primitive multi-dimensional arrays

Depends on:

@ForNeVeR ForNeVeR changed the title Struct definitions(not a lot of them, thankfully) Basic struct definition support Jan 16, 2022
@ForNeVeR ForNeVeR added area:compiler Related to code compilation or type checking kind:feature New feature or request status:help-wanted Open for contributors labels Jan 16, 2022
@ForNeVeR ForNeVeR removed the status:help-wanted Open for contributors label Feb 10, 2022
@ForNeVeR ForNeVeR self-assigned this Feb 10, 2022
ForNeVeR added a commit that referenced this issue Feb 12, 2022
ForNeVeR added a commit that referenced this issue Feb 16, 2022
@ForNeVeR ForNeVeR mentioned this issue Feb 16, 2022
1 task
@ForNeVeR ForNeVeR mentioned this issue Feb 22, 2022
3 tasks
ForNeVeR added a commit that referenced this issue Mar 27, 2022
ForNeVeR added a commit that referenced this issue Mar 27, 2022
ForNeVeR added a commit that referenced this issue Jul 23, 2022
ForNeVeR added a commit that referenced this issue Jul 23, 2022
ForNeVeR added a commit that referenced this issue Jul 23, 2022
ForNeVeR added a commit that referenced this issue Jul 23, 2022
ForNeVeR added a commit that referenced this issue Jul 23, 2022
ForNeVeR added a commit that referenced this issue Jul 31, 2022
ForNeVeR added a commit that referenced this issue Jul 31, 2022
…nly be in stack)

Also, it shouldn't inherit from PointerType, since it doesn't behave as
pointer in all contexts.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:compiler Related to code compilation or type checking kind:feature New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant