Re: generating self-contained dlls: sf or swiftx?

From: Appert, Kevin <kevin.appert_at_lmco.com>
Date: Fri, 29 Jan 2010 10:22:43 -0700

I'm not sure you're offering an example in the class of the problem that Joel wants to solve. I think his scenario would go something like this:

1) an end-user would write a snippet in EasyLanguage
2) produce an executable(*) with the EasyLanguage
        (*)or whatever EasyLanguage spits out
3) use a tool produced with Forth to generate a DLL that would embody the functionality of the snippet written in (1) above.
        Either by a) wrapping the output of EasyLanguage and loading it as the DLL
        .OR. by b) writing a DLL which would run the stand-alone executable produced by (1) and passing it the parameters it needs and doing something reasonable with the output

Any road, it seems to be a can of worms that I'll be pleased to offer free advise* about but I wouldn't want to have to eat.

*free advise is potentially worth what you've paid for it.

-----Original Message-----
From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com] On Behalf Of Leon Wagner
Sent: Friday, January 29, 2010 9:10 AM
To: sftalk_at_forth.com
Subject: [sftalk] Re: generating self-contained dlls: sf or swiftx?

The instructions for making a DLL in SwiftForth are in Section 8.2.2 of the SwiftForth-Win32 reference manual. Here's
an example of a DLL that exports a function called AskQuestion:

: AskQuestion ( hwnd -- n )
   Z" Could this be any easier?" Z" Question" MB_YESNO MessageBox ;

1 EXPORT: AskQuestion

PROGRAM DEMO.DLL

Any program in any language can call this Forth word via its DLL interface. The function prototype would look something
like this (I'm not a C programmer, so correct as necessary):

 int AskQuestion(HWND hWnd);

Perhaps someone who knows how will show me how much simpler the above example is to code in C.

--Leon

> -----Original Message-----
> From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com] On Behalf Of Appert, Kevin
> Sent: Friday, January 29, 2010 7:57 AM
> To: 'sftalk_at_forth.com'
> Subject: [sftalk] Re: generating self-contained dlls: sf or swiftx?
>
> If you're writing for Windows boxes, SwiftForth is the environment you want. I suspect it might be easier to
> write a auto-DLL-maker in C, except for Leon or Rick, who might very well finished writing one while I wrote
> this.
>
> I believe if you're doing an embedded implementation, you'll probably have to write your own DLL-maker for
> SwiftX.
>
>
> -----Original Message-----
> From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com] On Behalf Of Joel Reymont
> Sent: Friday, January 29, 2010 5:37 AM
> To: sftalk_at_forth.com
> Subject: [sftalk] generating self-contained dlls: sf or swiftx?
>
> I want to have a GUI app where I can paste some code and get a DLL as a result.
>
> Should I use SwiftForth or SwiftX for this?
>
> The context is compiling trading strategies written in EasyLanguage
> [1] to machine code, to be loaded back into TradeStation [2] as a DLL.
> Think improvement in security, speed, etc. This type of a small
> self-contained Forth runtime can be loaded into all types of other
> trading applications that normally don't understand EasyLanguage.
>
> Thanks, Joel
>
> [1] http://lambda-the-ultimate.org/node/2201
> [2] http://www.tradestation.com
>
> --
> http://es.linkedin.com/in/joelreymont
> ----------------------------------------------------------------------
> sftalk_at_forth.com The SwiftForth programming discussion email list
> To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
> For list command help, send subject "help" to sftalk-request_at_forth.com
> Message archives are located at http://www.forth.com/archive/sftalk
> ----------------------------------------------------------------------
> This list is a forum for SwiftForth users. For product support and
> bug reports, please send email to support_at_forth.com
> ----------------------------------------------------------------------
>
> ----------------------------------------------------------------------
> sftalk_at_forth.com The SwiftForth programming discussion email list
> To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
> For list command help, send subject "help" to sftalk-request_at_forth.com
> Message archives are located at http://www.forth.com/archive/sftalk
> ----------------------------------------------------------------------
> This list is a forum for SwiftForth users. For product support and
> bug reports, please send email to support_at_forth.com
> ----------------------------------------------------------------------

----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
For list command help, send subject "help" to sftalk-request_at_forth.com
Message archives are located at http://www.forth.com/archive/sftalk
----------------------------------------------------------------------
This list is a forum for SwiftForth users. For product support and
bug reports, please send email to support_at_forth.com
----------------------------------------------------------------------

----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
For list command help, send subject "help" to sftalk-request_at_forth.com
Message archives are located at http://www.forth.com/archive/sftalk
----------------------------------------------------------------------
This list is a forum for SwiftForth users. For product support and
bug reports, please send email to support_at_forth.com
----------------------------------------------------------------------
Received on Fri Jan 29 2010 - 09:23:17 PST


Subscribe to our e-mail list service. It's free for all SwiftForth and SwiftX users!

This archive was generated 09-Feb-2012. Archive updated nightly.