Skip to content

[-Wint-conversion] warning always occurs. #72

@mkparkqq

Description

@mkparkqq

I am new beginner for this framework.
I found some annoying warning message during my tutorial.

How to reproduce

// test.c
#include <exotic/cester.h>
 
CESTER_TEST(test_one, inst,
    cester_assert_nothing();    
)
$ gcc -I./ test.c -o test.out
In file included from test.c:1:
./exotic/cester.h:481:5: warning: initialization of ‘int’ from ‘void *’ makes integer from pointer without a cast [-Wint-conversion]
  481 |     CESTER_NULL,                                     /* output_stream_address */
      |     ^~~~~~~~~~~
./exotic/cester.h:481:5: note: (near initialization for ‘superTestInstance.output_stream_address._flags’)

my environment

$ uname -a
Linux foo 6.5.0-27-generic #28~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Mar 15 10:51:06 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

temporary solution

I managed to prevent the warning message from appearing by using -Wno-int-conversion option.

Please help newbie. Thanks :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions