fork download
  1. #include <stdio.h>
  2.  
  3. struct test{
  4. char field[16];
  5. };
  6.  
  7. int main(void) {
  8. const char *string = {'s', 'o', 'm', 'e', ' ', 's', 't', 'r', 'i', 'n', 'g', '\0'};
  9. struct test t = {.field = *string};
  10.  
  11. printf("t::field = %s\n", t.field);
  12. }
  13.  
Runtime error #stdin #stdout 0s 9288KB
stdin
Standard input is empty
stdout
Standard output is empty