Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C Programming > turbo c

Reply
Thread Tools

turbo c

 
 
khan
Guest
Posts: n/a
 
      05-08-2010
hi this is yousaf shah.. student no: 091304
my quistion is...........
what is pointer in turbo c...?
 
Reply With Quote
 
 
 
 
Sjouke Burry
Guest
Posts: n/a
 
      05-08-2010
khan wrote:
> hi this is yousaf shah.. student no: 091304
> my quistion is...........
> what is pointer in turbo c...?

You are a pointer to an instance of the genus "lazy student".
In TurboC such a pointer can cause irreparable damage to education.
 
Reply With Quote
 
 
 
 
spinoza1111
Guest
Posts: n/a
 
      05-08-2010
On May 8, 8:02*am, khan <(E-Mail Removed)> wrote:
> hi this is yousaf shah.. * student no: 091304
> my quistion is...........
> * what is pointer in turbo c...?


Ak-salaam aleykum. A pointer in turbo C, or any C, is the actual
address of the value in a "Von Neumann" stored program addressible
machine such that every variable has a sequential address. This makes
C rather different from other "high level languages" which conceal
this value. However, the machine could theoretically be not Von
Neumann because C does NOT allow one to take the address of a C
"instruction", although entire functions may be passed as parameters.
 
Reply With Quote
 
spinoza1111
Guest
Posts: n/a
 
      05-08-2010
On May 8, 8:51*am, Sjouke Burry <(E-Mail Removed)>
wrote:
> khan wrote:
> > hi this is yousaf shah.. * student no: 091304
> > my quistion is...........
> > * what is pointer in turbo c...?

>
> You are a pointer to an instance of the genus "lazy student".
> In TurboC such a pointer can cause irreparable damage to education.


No, he's a human being. He and his mates may be having a chortle at
the expense of the regs here who cannot (owing to their lack of
computer science literacy) in fact answer these questions.
 
Reply With Quote
 
spinoza1111
Guest
Posts: n/a
 
      05-09-2010
On May 9, 5:24*am, Richard Heathfield <(E-Mail Removed)> wrote:
> spinoza1111 wrote:
> > On May 8, 8:02 am, khan <(E-Mail Removed)> wrote:
> >> hi this is yousaf shah.. * student no: 091304
> >> my quistion is...........
> >> * what is pointer in turbo c...?

>
> > Ak-salaam aleykum. A pointer in turbo C, or any C, is the actual
> > address of the value in a "Von Neumann" stored program addressible
> > machine such that every variable has a sequential address.

>
> int (*p)(void) = main;
>
> p is a counter-example to your claim, since it is a pointer to a
> function, not a value.


Thanks, Otto. Please do not be too disruptive today.

Function pointers are less a counter-example and more an inelegant add-
on, but correct, Otto, they constitute an extra type of pointer which
does not constitute a pointer to a value (a series of instructions) to
which C has access. Actually, it should have access to the actual
compiled function's machine instructions.
>
> > This makes
> > C rather different from other "high level languages" which conceal
> > this value. However, the machine could theoretically be not Von
> > Neumann because C does NOT allow one to take the address of a C
> > "instruction", although entire functions may be passed as parameters.

>
> If you mean that C allows entire functions to be passed as parameters,
> you are mistaken. Pointers to functions may be passed, but functions
> themselves cannot.


OK, I don't, Otto. I wouldn't want to be mistaken. I'm not a reg who
gets to make mistakes on the order of Seebach's boners.

The point is that you are so afraid of "being wrong" (there existing
some interpretation of your words such that it's "wrong") you can't
answer simple questions.
>
> --
> Richard Heathfield <http://www.cpax.org.uk>
> Email: -http://www. +rjh@
> "Usenet is a strange place" - dmr 29 July 1999
> Sig line vacant - apply within


 
Reply With Quote
 
spinoza1111
Guest
Posts: n/a
 
      05-09-2010
On May 9, 7:51*pm, pete <(E-Mail Removed)> wrote:
> spinoza1111 wrote:
>
> > On May 8, 8:02 am, khan <(E-Mail Removed)> wrote:
> > > hi this is yousaf shah.. * student no: 091304
> > > my quistion is...........
> > > * what is pointer in turbo c...?

>
> > Ak-salaam aleykum. A pointer in turbo C, or any C, is the actual
> > address of the value in a "Von Neumann" stored program addressible
> > machine such that every variable has a sequential address.

>
> There's nothing in C which implies sequential addresses
> for different variables.
>
> On my machine, if I declare only two one byte size variables,
> char a = 0;
> char b = 0;
> they wind up with 3 unused bytes in between them.
>
> /* BEGIN new.c output */
>
> &a is 0012FF7C
> &b is 0012FF78
>
> /* END new.c output */
>
> /* BEGIN new.c */
>
> #include <stdio.h>
>
> int main(void)
> { *
> * * char a = 0;
> * * char b = 0;
>
> * * puts("/* BEGIN new.c output */\n");
> * * printf("&a is %p\n", &a);
> * * printf("&b is %p\n", &b);
> * * puts("\n/* END new.c output */");
> * * return 0;
>
> }
>
> /* END new.c */
>
> --
> pete


OK, replace "sequential" by "ordinal".
 
Reply With Quote
 
blmblm@myrealbox.com
Guest
Posts: n/a
 
      05-29-2010
In article <(E-Mail Removed)>,
spinoza1111 <(E-Mail Removed)> wrote:
> On May 9, 7:51 pm, pete <(E-Mail Removed)> wrote:
> > spinoza1111 wrote:
> >
> > > On May 8, 8:02 am, khan <(E-Mail Removed)> wrote:
> > > > hi this is yousaf shah.. student no: 091304
> > > > my quistion is...........
> > > > what is pointer in turbo c...?

> >
> > > Ak-salaam aleykum. A pointer in turbo C, or any C, is the actual
> > > address of the value in a "Von Neumann" stored program addressible
> > > machine such that every variable has a sequential address.

> >
> > There's nothing in C which implies sequential addresses
> > for different variables.
> >
> > On my machine, if I declare only two one byte size variables,
> > char a = 0;
> > char b = 0;
> > they wind up with 3 unused bytes in between them.


[ snip ]

>
> OK, replace "sequential" by "ordinal".
>


Not that it matters, but I'm not sure that really helps -- I mean,
in a system where an address consists of a segment identifier and
an offset into the segment (and as best I can tell that would be
AOK with the C standard), is there really any meaningful way to
order pointers from different segments?

Just sayin', maybe.

--
B. L. Massingill
ObDisclaimer: I don't speak for my employers; they return the favor.
 
Reply With Quote
 
Seebs
Guest
Posts: n/a
 
      05-29-2010
On 2010-05-29, blmblm myrealbox.com <(E-Mail Removed)> wrote:
> Not that it matters, but I'm not sure that really helps -- I mean,
> in a system where an address consists of a segment identifier and
> an offset into the segment (and as best I can tell that would be
> AOK with the C standard), is there really any meaningful way to
> order pointers from different segments?


Not really, especially because on many systems, there is substantial
overlap, such that you can have two different {segment, offset} pairs
which actually refer to the same byte of memory.

-s
--
Copyright 2010, all wrongs reversed. Peter Seebach / http://www.velocityreviews.com/forums/(E-Mail Removed)
http://www.seebs.net/log/ <-- lawsuits, religion, and funny pictures
http://en.wikipedia.org/wiki/Fair_Game_(Scientology) <-- get educated!
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
HIS X800GTO IceQ II Turbo 256MB Silverstrand Front Page News 0 10-11-2005 02:45 AM
HIS X800 GTO IceQ II Turbo 256MB PCIe Video Card Review Silverstrand Front Page News 3 10-10-2005 01:42 PM
HIS Radeon X800GT IceQ II Turbo @ Viperlair Silverstrand Front Page News 4 10-05-2005 06:47 AM
HIS X800 GT IceQ II Turbo Review Silverstrand Front Page News 0 08-29-2005 04:48 PM
HIS Radeon X700 Pro IceQ Turbo drawing Silverstrand Front Page News 6 07-10-2005 08:55 AM



Advertisments