programming tools for Windows applications development
  Home  |   SwiftForth Archive  |   SwiftX Archive  |

Re: class variables not working

From: Mike Ghan <mikeghan_at_logix-controls.com>
Date: Thu, 18 Sep 2003 20:13:41 -0700

VARIABLE (among other words) is redefined in the SWOOP wordlist. See
Swoop.F or type

CC-WORDS +ORDER LOCATE VARIABLE

Also note FVARIABLE is not defined.

Mike

-----Original Message-----
From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com]On
Behalf
Of Conrad Weyns
Sent: Thursday, September 18, 2003 11:51 AM
To: sftalk_at_forth.com
Subject: [sftalk] Re: class variables not working

----- Original Message -----
From: "Jeff Massung" <jma_at_mfire.com>
To: <sftalk_at_forth.com>
Sent: 18. september 2003 16:14
Subject: [sftalk] class variables not working

> Attached is a sample source code. Earlier when I posted about
floating-point
> members not working in classes, it appears much broader now. Run the
> attachment to see what I mean.
> If this could be fixed, it would make my life much better, as my
current
> project really needs this to work.
>
> Jeff
>
>
> jma_at_mfire.com
> http://www.simforth.com
>
>
> -- Attached file included as plaintext by Ecartis --
> -- File: sample.f
>
> \ sample code that fails
>
> class my-point
> create x 1 cells allot
> create y 1 cells allot

Weird, it works ok with VARIABLE but not with CREATE, yet VARIABLE is
supposedly:
    : VARIABLE CREATE 0 , ;

Beats me!
(Just playing - I haven't used SWOOP at all)
Conrad Weyns

>
> : set ( x y -- ) y ! x ! ;
> : show ( -- ) x @ . y @ . cr ;
> end-class
>
> my-point builds p1
> my-point builds p2
>
> 1 2 p1 set
> 3 4 p2 set
>
> p1 show
> p2 show
>

----------------------------------------------------------------------
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 Thu Sep 18 2003 - 20:17:55 PDT

This archive was generated by hypermail 2.2.0 : Wed Jan 07 2009 - 03:04:10 PST