X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f From: =?UTF-8?Q?Hans-Bernhard_Br=c3=b6ker?= Newsgroups: comp.os.msdos.djgpp Subject: Re: memory.h Date: Sat, 14 Jan 2017 23:57:28 +0100 Lines: 27 Message-ID: References: <83h951c41o DOT fsf AT gnu DOT org> <83d1fpc24q DOT fsf AT gnu DOT org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: news.dfncis.de poNr1cS/6R3ebnTLwW+3Gw/OLt7tsjdNQBrjLtaf2RlSn4NDtLAuC7NpKC Cancel-Lock: sha1:W5RZUDn4BjRPrv3tP3mmsbdYdIQ= User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 In-Reply-To: Bytes: 2204 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk Am 14.01.2017 um 13:11 schrieb Ozkan Sezer (sezeroz AT gmail DOT com) [via djgpp AT delorie DOT com]: > Problems are not from including stdlib.h but from not including string.h > E.g. cpu.c from flac library includes memory.h possibly to get the proto > for memset(). Their decision might be debatable, That decision is well beyond debatable. It's totally and flat-out wrong. has been the header to get memset() from for over 25 years now. It's one thing to #include too, if the system has it. But there's no sane excuse left for _not_ including if it exists. >> Would it be okay to >> simply add string.h, without removing stdlib.h? It would be okay for the user code to do that. But strictly speaking, system headers are effectively forbidden from doing that by the language standard. Code that doesn't include a standard library header is granted license to assume that some things from that header are _not_ defined, i.e. that they're free for other use. Yes, that means the existing #include of by also not really allowed.