www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/02/22/14:31:03

From: "Michael Stewart" <mike AT reggin DOT freeserve DOT co DOT uk>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: int to char
Date: Mon, 22 Feb 1999 19:21:01 -0000
Organization: Customer of Planet Online
Lines: 21
Message-ID: <7asb2m$rkk$1@news5.svr.pol.co.uk>
References: <36C43BED DOT 533082C7 AT ort DOT org DOT il>
NNTP-Posting-Host: modem-5.beer.dialup.pol.co.uk
X-Trace: news5.svr.pol.co.uk 919711638 28308 62.136.130.5 (22 Feb 1999 19:27:18 GMT)
NNTP-Posting-Date: 22 Feb 1999 19:27:18 GMT
X-Complaints-To: abuse AT theplanet DOT net
X-Newsreader: Microsoft Outlook Express 4.72.3110.5
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

To convert an int to a char;
int y = 1;
Rami Yohay wrote in message <36C43BED DOT 533082C7 AT ort DOT org DOT il>...

>Can I convert int to char in DJGPP?
>

char x = y; // explicit cast

or

x = int (y); // cast

--
Michael Stewart
mike AT reggin DOT freeserve DOT co DOT uk
"Just because you're paraniod doesn't mean they aren't after you..."




- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019