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

add c type sizes for OpenBSD #1016

Closed
wants to merge 2 commits into from
Closed

add c type sizes for OpenBSD #1016

wants to merge 2 commits into from

Conversation

jan-schreib
Copy link

Used

#include <stdio.h>

int
main(void)
{
        printf("short      : %lu\n", sizeof(short));
        printf("ushort     : %lu\n", sizeof(unsigned short));
        printf("int        : %lu\n", sizeof(int));
        printf("uint       : %lu\n", sizeof(unsigned int));
        printf("long       : %lu\n", sizeof(long));
        printf("ulong      : %lu\n", sizeof(unsigned long));
        printf("long long  : %lu\n", sizeof(long long));
        printf("ulong long : %lu\n", sizeof(unsigned long long));
        printf("size_t     : %lu\n", sizeof(size_t));

        return 0;
}

to figure out the sizes.

@@ -743,6 +743,22 @@ uint32_t target_c_type_size_in_bits(const ZigTarget *target, CIntType id) {
case OsLv2:
case OsNetBSD:
Copy link
Member

Choose a reason for hiding this comment

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

looks like you need to shift these down so they get the panic():

         case OsAnanas:
         case OsCloudABI:
         case OsDragonFly:
         case OsFreeBSD:
         case OsIOS:
         case OsKFreeBSD:
         case OsLv2:
         case OsNetBSD: 

Copy link
Author

Choose a reason for hiding this comment

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

Moved the targets.

@andrewrk andrewrk closed this in 967bad4 May 17, 2018
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.

None yet

2 participants