Subject: Re: [SWIPL] Extensions to ActiveX DLL

From: "David Bennett" <[email-masked]>
Date: Thu, 27 Sep 2001 08:32:12 -0600

I have a VB app that interfaces to SWI via the ActiveX DLL.   It works great
except on Windows ME.
1) It would be nice to have atoms passed in.  Until I figured out that atoms
were not passed in, I wasted a lot of time attempting to debug the problem.
2) A setting to change the default behavior would be a better way to handle
backwards compatibility.
3) When passing in atoms, there would be less conversion from strings to
atoms inside the Prolog Program (presumably more efficiency).
4) An update to the ActiveX would be nice (very much appreciated) since the
current one uses an older version of SWI.
5) On WinME and some Win2K's, the ActiveX fails to properly register, which
I think a recompile might help me with (maybe not, perhaps its O/S that is
the problem).
Thanks Philip!

----- Original Message -----
From: "Philip Warner" <[email-masked]>
To: "Jan Wielemaker" <[email-masked]>; "SWI Mailing List"
<[email-masked]>
Sent: Thursday, September 27, 2001 8:09 AM
Subject: Re: [SWIPL] Extensions to ActiveX DLL

> At 15:47 27/09/01 +0200, Jan Wielemaker wrote:
> >>
> >>FWIW, there are two ways I am considering handling the atom/string input
> >>problem: (1) crudely - allow an atom to be passed on single quotes. ie.
> >>myAtom = "'name'" (the C-code will look for names containing
single-quotes)
> >>and (2) the hard way - implementing collection classes for the args,
with
> >>appropriate properties.
> >>
> >>At this stage, I am favoring the crude solution, since it is simple and
> >>does all that I need.
> >
> >Not that I use activeX, but this type of programming is dangerous.
> >Things I'm just passing along in variables suddenly gets transformed
> >into a string loosing the quotes, etc.
>
> It would be easy enough to add an attribute to the query object to say
> 'translate quoted strings to atoms', or perhaps, 'treat strings as atoms'
> would be better (see below).
>
> >
> >Also, why use strings at all?  SWI-Prolog atoms are unlimited
>
> I agree; the problem is that the ActiveX library uses strings by default.
> What I'm after is a way to treat the passed parameters as atoms, as you
> suggest. Are you suggesting that I should just modify the default
> behaviour? This, too, would satisfy my requirements, but will probably
> break existing apps - perhaps this can be a user setting.
>
> Does that sound better?
>
> At least with the user setting, nothing breaks, and the only problem
occurs
> if we want to pass in strings AND atoms, which seems pointless to me
>
>
> ----------------------------------------------------------------
> Philip Warner                    |     __---_____
> Albatross Consulting Pty. Ltd.   |----/       -  \
> (A.B.N. 75 008 659 498)          |          /(@)   ______---_
> Tel: (+61) 0500 83 82 81         |                 _________  \
> Fax: (+61) 0500 83 82 82         |                 ___________ |
> Http://www.rhyme.com.au          |                /           \|
>                                  |    --________--
> PGP key available upon request,  |  /
> and from pgp5.ai.mit.edu:11371   |/
>
>
> ----------------
> * To UNSUBSCRIBE, please use the HTML form at
>
>     http://www.swi.psy.uva.nl/projects/SWI-Prolog/index.html#mailinglist
>
> or send mail to [email-masked] using the Subject:
"unsubscribe"
> (without the quotes) and *no* message body.
>
> ** An ARCHIVE of this list is maintained at
>
>     http://www.swi.psy.uva.nl/projects/SWI-Prolog/mailinglist/archive/
>
>