Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c > #55310

Re: A data type for a wider integer than the compiler supports

From Ben Bacarisse <ben.usenet@bsb.me.uk>
Newsgroups comp.lang.c
Subject Re: A data type for a wider integer than the compiler supports
Date 2014-12-22 20:02 +0000
Organization A noiseless patient Spider
Message-ID <m7a12i$pgd$1@dont-email.me> (permalink)
References (1 earlier) <pan.2014.12.18.10.27.22.683000@nowhere.invalid> <iib59al1i0jtqb8behdmqq8aamr1a4k46o@4ax.com> <m6urcl$2d6$1@dont-email.me> <87zjakwve1.fsf@bsb.me.uk> <m79gl4$4p3$1@dont-email.me>

Show all headers | View raw


"James Harris" <james.harris.1@gmail.com> writes:

> "Ben Bacarisse" <ben.usenet@bsb.me.uk> wrote in message 
> news:87zjakwve1.fsf@bsb.me.uk...
>> "James Harris" <james.harris.1@gmail.com> writes:
>> <snip>
>>> No, in this case bcc is the pre-ANSI
>>>
>>>   http://linux.die.net/man/1/bcc
>>>
>>> Even though it does not copy structs (unfortunately) it seems to be the 
>>> best
>>> compiler available for producing 16-bit x86 code under Unix.
>>
>> What does not copy structs mean?
>
> I meant struct pass-by-value and assignment. I thought I read that bcc will 
> not support that - but I cannot find the comment just now.
>
>> I just gave bcc a spin and it accepts
>> a function with a struct parameter.  The generated code looks sane too
>> (though I don't really know the instruction set).
>
> If it helps, bcc is a pre-ANSI compiler. AIUI it passes ansi C through 
> unprotoize.

Yes, I know, thanks.

>   http://linux.die.net/man/1/unprotoize
>
> Is pre-ANSI C the same as K&R C?

No.  Pre standardisation there were lots of versions of C, mostly with
small variations in the language and more significant variations in the
library they came with.

> And did it support pass-by-value for 
> structures?

The language in K&R does not but it says that it may come along soon and
indeed it did.  Every C compiler I ever used, after about 1979,
supported struct assignment, passing and return (though I am sure some
came late to the party -- I was probably just fortunate).

>>  I can't actually run
>> the code because the emulator is unavailable on my system, so maybe it's
>> not really doing what I think.
>
> That's odd. On my system elksemu seems to have come in the bcc
> package.

It doesn't on my system despite the package description saying that it
does.  I suspect it's down to elksemu not working with newer 64-bit
kernels, but I did not investigate very much.

But you can check.  Does bcc support struct passing etc?  As I said, the
assembler code looks sane and there should really be a warning if the
compiler does not support it.

<snip>
-- 
Ben.

Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-17 10:04 +0000
  Re: A data type for a wider integer than the compiler supports Robert Wessel <robertwessel2@yahoo.com> - 2014-12-18 02:48 -0600
    Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-18 14:30 +0000
      Re: A data type for a wider integer than the compiler supports bert <bert.hutchings@btinternet.com> - 2014-12-18 11:49 -0800
      Re: A data type for a wider integer than the compiler supports Robert Wessel <robertwessel2@yahoo.com> - 2014-12-18 14:27 -0600
        Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2015-01-27 16:30 +0000
          Re: A data type for a wider integer than the compiler supports Thomas Richter <thor@math.tu-berlin.de> - 2015-01-29 15:53 +0100
            Re: A data type for a wider integer than the compiler supports Bartc <bc@freeuk.com> - 2015-01-29 17:33 +0000
              Re: A data type for a wider integer than the compiler supports Richard Heathfield <invalid@see.sig.invalid> - 2015-01-29 17:52 +0000
                Re: A data type for a wider integer than the compiler supports Bartc <bc@freeuk.com> - 2015-01-29 18:24 +0000
                Re: A data type for a wider integer than the compiler supports Richard Heathfield <invalid@see.sig.invalid> - 2015-01-29 18:42 +0000
            Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2015-01-30 09:56 +0000
              Re: A data type for a wider integer than the compiler supports Richard Heathfield <invalid@see.sig.invalid> - 2015-01-30 10:13 +0000
                Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2015-01-30 13:21 +0000
                Re: A data type for a wider integer than the compiler supports Greg Martin <greg.at.softsprocket@dot.com> - 2015-01-30 14:16 +0000
                Re: A data type for a wider integer than the compiler supports Thomas Richter <thor@math.tu-berlin.de> - 2015-02-01 08:54 +0100
            Re: A data type for a wider integer than the compiler supports Richard Heathfield <invalid@see.sig.invalid> - 2015-01-30 10:17 +0000
  Re: A data type for a wider integer than the compiler supports BartC <bc@freeuk.com> - 2014-12-18 10:13 +0000
    Re: A data type for a wider integer than the compiler supports BartC <bc@freeuk.com> - 2014-12-18 12:34 +0000
    Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-18 15:06 +0000
  Re: A data type for a wider integer than the compiler supports Nobody <nobody@nowhere.invalid> - 2014-12-18 10:27 +0000
    Re: A data type for a wider integer than the compiler supports Robert Wessel <robertwessel2@yahoo.com> - 2014-12-18 04:44 -0600
      Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-18 15:21 +0000
        Re: A data type for a wider integer than the compiler supports Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-12-18 20:33 +0000
          Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-22 16:25 +0000
            Re: A data type for a wider integer than the compiler supports Robert Wessel <robertwessel2@yahoo.com> - 2014-12-22 14:38 -0600
              Re: A data type for a wider integer than the compiler supports Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-12-22 21:14 +0000
              Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-23 02:42 +0000
                Re: A data type for a wider integer than the compiler supports Robert Wessel <robertwessel2@yahoo.com> - 2014-12-22 22:52 -0600
                Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-23 11:00 +0000
                Re: A data type for a wider integer than the compiler supports Les Cargill <lcargill99@comcast.com> - 2014-12-23 14:46 -0600
                Re: A data type for a wider integer than the compiler supports Robert Wessel <robertwessel2@yahoo.com> - 2014-12-24 05:21 -0600
                Re: A data type for a wider integer than the compiler supports David Brown <david.brown@hesbynett.no> - 2014-12-23 08:13 +0100
            Re: A data type for a wider integer than the compiler supports Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-12-22 20:02 +0000
              Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-23 02:33 +0000
                Re: A data type for a wider integer than the compiler supports Robert Wessel <robertwessel2@yahoo.com> - 2014-12-22 23:05 -0600
                Re: A data type for a wider integer than the compiler supports Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-12-23 09:57 +0000
                Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-23 10:49 +0000
            Re: A data type for a wider integer than the compiler supports Kaz Kylheku <kaz@kylheku.com> - 2014-12-22 21:18 +0000
    Re: A data type for a wider integer than the compiler supports Keith Thompson <kst-u@mib.org> - 2014-12-18 10:12 -0800
  Re: A data type for a wider integer than the compiler supports Vincenzo Mercuri <nomail@yahoo.it> - 2014-12-18 18:52 +0100
    Re: A data type for a wider integer than the compiler supports "James Harris" <james.harris.1@gmail.com> - 2014-12-18 18:17 +0000

csiph-web