Lines Matching refs:dnp

307 	dt_node_t *dnp;  in dt_decl_protoform()  local
309 for (dnp = flist; dnp != fnp && dnp != NULL; dnp = dnp->dn_list) { in dt_decl_protoform()
310 if (dnp->dn_string != NULL && in dt_decl_protoform()
311 strcmp(dnp->dn_string, fnp->dn_string) == 0) in dt_decl_protoform()
333 dt_node_t *dnp; in dt_decl_prototype() local
335 for (dnp = plist; dnp != NULL; dnp = dnp->dn_list, i++) { in dt_decl_prototype()
337 if (dnp->dn_type == CTF_ERR && !(flags & DT_DP_VARARGS)) { in dt_decl_prototype()
338 dnerror(dnp, D_DECL_PROTO_VARARGS, "%s prototype may " in dt_decl_prototype()
342 if (dt_node_is_dynamic(dnp) && !(flags & DT_DP_DYNAMIC)) { in dt_decl_prototype()
343 dnerror(dnp, D_DECL_PROTO_TYPE, "%s prototype may not " in dt_decl_prototype()
345 kind, dt_node_type_name(dnp, n, sizeof (n)), in dt_decl_prototype()
346 dnp->dn_string ? dnp->dn_string : "(anonymous)", i); in dt_decl_prototype()
349 is_void = dt_node_is_void(dnp); in dt_decl_prototype()
353 dnerror(dnp, D_DECL_PROTO_TYPE, "%s prototype may not " in dt_decl_prototype()
355 kind, dt_node_type_name(dnp, n, sizeof (n)), in dt_decl_prototype()
356 dnp->dn_string ? dnp->dn_string : "(anonymous)", i); in dt_decl_prototype()
359 if (is_void && dnp->dn_string != NULL) { in dt_decl_prototype()
360 dnerror(dnp, D_DECL_PROTO_NAME, "void parameter may " in dt_decl_prototype()
361 "not have a name: %s\n", dnp->dn_string); in dt_decl_prototype()
364 if (dnp->dn_string != NULL && in dt_decl_prototype()
365 dt_decl_protoform(dnp, flist) != form) { in dt_decl_prototype()
366 dnerror(dnp, D_DECL_PROTO_FORM, "parameter is " in dt_decl_prototype()
368 form ? "not" : "already", kind, dnp->dn_string, i); in dt_decl_prototype()
371 if (dnp->dn_string == NULL && in dt_decl_prototype()
373 dnerror(dnp, D_DECL_PROTO_NAME, "parameter declaration " in dt_decl_prototype()
385 dt_decl_array(dt_node_t *dnp) in dt_decl_array() argument
401 if (dnp != NULL && dnp->dn_kind == DT_NODE_TYPE) { in dt_decl_array()
414 if (dnp != NULL && dnp->dn_kind != DT_NODE_TYPE) { in dt_decl_array()
415 dnp = ddp->dd_node = dt_node_cook(dnp, DT_IDFLG_REF); in dt_decl_array()
417 if (dt_node_is_posconst(dnp) == 0) { in dt_decl_array()
423 if (dnp->dn_value > UINT_MAX) in dt_decl_array()
426 } else if (dnp != NULL) { in dt_decl_array()
427 ddp->dd_node = dnp; in dt_decl_array()
428 (void) dt_decl_prototype(dnp, dnp, "array", DT_DP_ANON); in dt_decl_array()
446 dt_decl_func(dt_decl_t *pdp, dt_node_t *dnp) in dt_decl_func() argument
450 ddp->dd_node = dnp; in dt_decl_func()
452 (void) dt_decl_prototype(dnp, dnp, "function", in dt_decl_func()
521 dt_decl_member(dt_node_t *dnp) in dt_decl_member() argument
542 if (dnp == NULL && ident == NULL) in dt_decl_member()
607 if (dnp != NULL) { in dt_decl_member()
608 dnp = dt_node_cook(dnp, DT_IDFLG_REF); in dt_decl_member()
616 if (ident == NULL && dnp->dn_kind == DT_NODE_INT && in dt_decl_member()
617 dnp->dn_value == 0) { in dt_decl_member()
618 dt_node_free(dnp); in dt_decl_member()
622 if (dt_node_is_posconst(dnp) == 0) { in dt_decl_member()
634 if (dnp->dn_value > cte.cte_bits) { in dt_decl_member()
640 cte.cte_bits = (uint_t)dnp->dn_value; in dt_decl_member()
654 dt_node_free(dnp); in dt_decl_member()
733 dt_decl_enumerator(char *s, dt_node_t *dnp) in dt_decl_enumerator() argument
762 if (dnp != NULL) { in dt_decl_enumerator()
763 if (dnp->dn_kind != DT_NODE_IDENT || ctf_enum_value( in dt_decl_enumerator()
764 dsp->ds_ctfp, dsp->ds_type, dnp->dn_string, &value) != 0) { in dt_decl_enumerator()
765 dnp = dt_node_cook(dnp, DT_IDFLG_REF); in dt_decl_enumerator()
767 if (dnp->dn_kind != DT_NODE_INT) { in dt_decl_enumerator()
773 if ((intmax_t)dnp->dn_value > INT_MAX || in dt_decl_enumerator()
774 (intmax_t)dnp->dn_value < INT_MIN) { in dt_decl_enumerator()
779 value = (int)dnp->dn_value; in dt_decl_enumerator()
781 dt_node_free(dnp); in dt_decl_enumerator()
821 dnp = dt_node_int(value); in dt_decl_enumerator()
822 dt_node_type_assign(dnp, dsp->ds_ctfp, dsp->ds_type, B_FALSE); in dt_decl_enumerator()
831 assert(yypcb->pcb_list == dnp); in dt_decl_enumerator()
832 yypcb->pcb_list = dnp->dn_link; in dt_decl_enumerator()
833 dnp->dn_link = NULL; in dt_decl_enumerator()
836 inp->din_list = dnp; in dt_decl_enumerator()
837 inp->din_root = dnp; in dt_decl_enumerator()