-
Notifications
You must be signed in to change notification settings - Fork 53
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
C99/C11 keyword support #43
Comments
cool. i don't understand how this stuff works in nesc and am buried in getting a release of the msp432/arm cortex-4mf based mammark code out. is this simple to do following the proposed commits that david has done? |
Thank you for being interested in. In order to support
|
Adding _Bool is definitely not going to be completely straightforward, e.g., from an extremely brief perusal of the C standard: nesC does constant folding, so will need to implement this rule. |
thanks to both of you.
If we find ourselves in the same place physically, beers all around (or
replacement beverage of choice).
…On Thu, May 3, 2018 at 9:59 PM, dgay42 ***@***.***> wrote:
Adding _Bool is definitely not going to be completely straightforward,
e.g., from an extremely brief perusal of the C standard:
6.3.1.2 Boolean type: When any scalar value is converted to _Bool, the
result is 0 if the value compares equal to 0; otherwise, the result is 1.
nesC does constant folding, so will need to implement this rule.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#43 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAY46b2XN-GLZDjwI-B5qdlqpkkNUH_Bks5tu-A-gaJpZM4TwjLT>
.
--
Eric B. Decker
Senior (over 50 :-) Researcher
|
Thank you for your precious insight, David. |
And I pull-requested the change to support |
For constant folding of Anyway I created a pull request for |
It is great if
nesc
can support some of C99 and C11 reserved keywords, for instancerestrict
,_Noreturn
, and_Bool
.While I tried the latest nesc and tinyos with the beta release of TI MSP430-GCC which is based on
gcc 7.3
, I noticed thatrestrict
and_Noreturn
weren't processed correctly bynesc
and caused errors. I worked around errors by making those keywords as empty string. But supporting those keywords innesc
is apparently preferable.TinyOS defines
bool
asuint8_t
in tos.h, but defining it as_Bool
may utilize further compiler optimization.nx_bool
has similar definition too. So it is highly preferable fornesc
to support_Bool
type.The text was updated successfully, but these errors were encountered: