chicken-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Chicken-hackers] Re: .exports not renamed w/ CMake Windows build


From: Brandon J. Van Every
Subject: [Chicken-hackers] Re: .exports not renamed w/ CMake Windows build
Date: Mon, 08 Jan 2007 09:43:28 -0800
User-agent: Thunderbird 1.5.0.9 (Windows/20061207)

Kon Lovett wrote:

The exports of posixunix & posixwin have an intersection but also a difference. The exports of pcre are a superset of regexunix & pregexp (which I think are the same).

I don't think the differences in the exports are really an issue. The units are called 'posix' & 'regex' in the manual.

Sorry, Brandon, but I think they must be renamed.

I'm asking whether lumping all these under one name is a basic error of Chicken's design. What do Chicken programs do when ported from Unix to Windows? Just gratuitously fail, looking for exports that aren't there? I'll wager that historically, programs haven't been ported from Unix to Windows very often, so the issue hasn't come up.

I see at least 2 correct philosophies for dealing with this:

1) keep the .exports different. Make the programmer deal with whether they're using posixunix, posixwin, pcre, pregexp, or regexunix.

2) make the .exports identical in content, and create stub functions for whatever's missing, perhaps giving a diagnostic error. That way when the program dies, at least the user knows why.

In reaction to this, you might say, "Well I just want it to be (use posix) and (use regex). I don't want to type anything new / different than what's in the manual, I just want it to work." But it isn't going to work. At least not generally speaking; it only works if you happen to use a supported subset. I am saying, the programmer has to deal with the available functions somewhere, somehow, if the program is to be well-behaved.


Cheers,
Brandon Van Every





reply via email to

[Prev in Thread] Current Thread [Next in Thread]