From: ratheesh k <ratheesh.ksz@gmail.com>
To: linux-c-programming@vger.kernel.org
Subject: g++ without typecast
Date: Fri, 11 Mar 2011 17:12:42 +0530 [thread overview]
Message-ID: <AANLkTikM+tApusZWzpcVRXThYGsJdzek1BSA7DBG8yx=@mail.gmail.com> (raw)
In-Reply-To: <AANLkTi=GUjHMhXcWdaMbop+4f5Q9t549dOHECFvUAQtj@mail.gmail.com>
This program will compile using gcc. But fails using g++ compiler ( we
need explicit type casting here).
Is there any flag or anyother way thru which we could compile this
using g++ ( without explicit type cast )
#include <stdio.h>
int main()
{
unsigned int addr=0xffff;
int *ptr;
ptr=addr;
return 0;
}
--
To unsubscribe from this list: send the line "unsubscribe linux-c-programming" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next parent reply other threads:[~2011-03-11 11:42 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <AANLkTi=GUjHMhXcWdaMbop+4f5Q9t549dOHECFvUAQtj@mail.gmail.com>
2011-03-11 11:42 ` ratheesh k [this message]
2011-03-11 12:23 ` g++ without typecast ern0
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='AANLkTikM+tApusZWzpcVRXThYGsJdzek1BSA7DBG8yx=@mail.gmail.com' \
--to=ratheesh.ksz@gmail.com \
--cc=linux-c-programming@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).