From: regehr Date: Tue, 12 Feb 2008 21:16:00 +0000 (+0000) Subject: annotation work X-Git-Tag: release_tinyos_2_1_0_0~554 X-Git-Url: https://oss.titaniummirror.com/gitweb?a=commitdiff_plain;h=0beb31d5cd50733c3c6314568368bbb8eed908d9;p=tinyos-2.x.git annotation work --- diff --git a/tos/lib/safe/include/deputy_no_annots.h b/tos/lib/safe/include/deputy_no_annots.h index 0a6fb975..c3adeade 100644 --- a/tos/lib/safe/include/deputy_no_annots.h +++ b/tos/lib/safe/include/deputy_no_annots.h @@ -1,9 +1,9 @@ #define __DEPUTY_BOUND(__lo,__hi) #define __DEPUTY_COUNT(__n) #define __DEPUTY_SINGLE(__n) -#define __DEPUTY_TRUSTED_CAST(__type,__expr) +#define __DEPUTY_TRUSTED_CAST(__type,__expr) ((__type)(__expr)) -#define TC(__type,__expr) +#define TC(__type,__expr) __DEPUTY_TRUSTED_CAST(__type,__expr) #define __DEPUTY_NONNULL #define __DEPUTY_TRUSTED diff --git a/tos/lib/safe/include/nesc_annots.h b/tos/lib/safe/include/nesc_annots.h index f0cc00cf..5b4220de 100644 --- a/tos/lib/safe/include/nesc_annots.h +++ b/tos/lib/safe/include/nesc_annots.h @@ -1,3 +1,4 @@ struct @bound @deputy_scope() @macro("__DEPUTY_BOUND") { void *lo, *hi; }; struct @count @deputy_scope() @macro("__DEPUTY_COUNT") { int n; }; struct @single @deputy_scope() @macro("__DEPUTY_SINGLE") { }; +struct @nonnull @deputy_scope() @macro("__DEPUTY_NONNULL") { };