- "The Curious Case of the Longevity of C" - 1 Update
- "The Curious Case of the Longevity of C" - 1 Update
- sizeof in a template, applied in a template type - 1 Update
ram@zedat.fu-berlin.de (Stefan Ram): Oct 08 03:16PM >When I bought K&R C in 1979, it cost $24.95, a lot less than one week's >rent. In the seventies and eighties we had still many simple flats with low monthly rents in Berlin. Those monthly rents in fact might have been as low as whats was equivalent to $40 (a month!) in 1979. I once ordered a paper copy of ANSI C and it surely cost much more than the monthly rent of such a flat. A simple Berlin flat of those days might not have had a rest room. Rather there was a single rest room somewhere in or near the house that was shared by several rental parties. And the heating was done by a coal oven. Given that German universities usually have no tuition fees, it was possible, in those days, to study with a rather low income when living in such a flat. |
James Kuyper <jameskuyper@verizon.net>: Oct 08 06:43AM -0400 On 10/05/2017 08:24 PM, Lynn McGuire wrote: > to learn in these pre-Google 1 pre-StackOverflow/GitHub 2 days." > Yup, that is when I started looking at C. I bought TurboC in 1987 ??? > and I was in love. When I bought K&R C in 1979, it cost $24.95, a lot less than one week's rent. |
Richard Damon <Richard@Damon-Family.org>: Oct 07 08:12PM -0400 > The important I reserve enough memory for the object and that memory is good aligned > Or I think it wrong? > I already have a new/delete operator that use my malloc/ free implementation but I use always malloc/free, the same. There is technically nothing wrong with using malloc instead of new, as long as you also construct the object in the memory afterwords. It is very non-idiomatic though. One way to see this is that, by definition, new Type is defined as calling operator new and then the constructor, and operator new is typically implemented as a call to malloc, followed by a test for null and a throw (this isn't required, but typical, malloc can NOT call operator new though, so a user provide operator new is allowed to call malloc) |
You received this digest because you're subscribed to updates for this group. You can change your settings on the group membership page. To unsubscribe from this group and stop receiving emails from it send an email to comp.lang.c+++unsubscribe@googlegroups.com. |
No comments:
Post a Comment