redline plans/vision

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
20 messages Options
Reply | Threaded
Open this post in threaded view
|

redline plans/vision

Lee Breisacher-2
Hi. I have some questions about the plans/future vision for redline.

1. image vs files

It seems pretty clear that you do not picture an image-based
environment, but rather file-based like Java. Yes? So, in the future,
all Smalltalk classes will be loaded dynamically like Java does?

2. adding methods to base classes

How do you envision adding methods to base classes from an
"application"?

3. namespaces

Does the class name syntax support namespaces?

4. file format

Is the file format documented anywhere? That would probably answer #2
and #3.

5. integration with Java

Do you envision easy integration with Java? Or maybe it's already
possible? For example, can I instantiate java classes within Smalltalk
and therefore utilize existing java libraries?

Thanks,

Lee
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

SeanTAllen


On Sat, Dec 17, 2011 at 1:51 PM, Lee <[hidden email]> wrote:
Hi. I have some questions about the plans/future vision for redline.

1. image vs files

It seems pretty clear that you do not picture an image-based
environment, but rather file-based like Java. Yes? So, in the future,
all Smalltalk classes will be loaded dynamically like Java does?


We are concentrating initially on file based. We want to have optional image creation in the future.
There are times when I really like having image based development. There are times when I like files.
I really want to be able to snapshot a running program to get an image that can be worked with
and also to be able to easily create new images from source.
 
2. adding methods to base classes

How do you envision adding methods to base classes from an
"application"?


This is an open question. I initially presented an idea to James around namespaces and auto delegation
that I prefer to open classes. I think it gives functionality that would be needed without the problems
that open classes aka monkeypatching can create. That said, it will need to be tried out first before we can
know for sure.
 
If people are interested in the idea, I can clean up the initial write up and make it available for perusal and discussion.

3. namespaces

Does the class name syntax support namespaces?

We have namespaces. I'm not sure exactly what your question means beyond that.
 

4. file format

Is the file format documented anywhere? That would probably answer #2
and #3.

Not yet. That is actually a really important gap now that I think about it.
The one thing if you look at source that might not be obvious is that the 

+ & - to indicate class or instance side has to be column 0.

Until I do that, best way is to start looking at the source that exists right now.
 

5. integration with Java

Do you envision easy integration with Java? Or maybe it's already
possible? For example, can I instantiate java classes within Smalltalk
and therefore utilize existing java libraries?


Right now, it is bytecode in pragmas. Something much nicer is coming...
well, I'll let James address that because I'm not sure of the timeline.

But yes, you will be able to easily work with Java classes within Smalltalk.
As an example, I intend to provide a nice Smalltalk way to use Clojure's STM
features.
 
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

SeanTAllen
In reply to this post by Lee Breisacher-2


4. file format

Is the file format documented anywhere? That would probably answer #2
and #3.

Barely apropos of anything..

Rob sent me a screenshot of some Redline source in Notepad++ 

It can give an idea of source format...

Notepadpp screenshot.png
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

Lee Breisacher-2
In reply to this post by SeanTAllen
Thanks for all those answers.

> > Does the class name syntax support namespaces?
>
> We have namespaces. I'm not sure exactly what your question means beyond
> that.

Say I want to write a class MyClass in namespace com.foo.boo which is
a subclass of, say, st.redline.Date. What would the class declaration
look like?

Lee
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

James Ladd
Redline classes are imported by default, but for this answer lets assume they
are not. The code would look like this:

import: 'st.redline.Date'
Date < MyClass

The MyClass.st file would be in the folder com/foo/boo

Your project can put your source folders where ever you want, and use the
-s option of stic to tell it where the root is. This follows the Java convention
for packages - which was easier to fit into rather than fight against.


On Sun, Dec 18, 2011 at 8:32 AM, Lee <[hidden email]> wrote:
Thanks for all those answers.

> > Does the class name syntax support namespaces?
>
> We have namespaces. I'm not sure exactly what your question means beyond
> that.

Say I want to write a class MyClass in namespace com.foo.boo which is
a subclass of, say, st.redline.Date. What would the class declaration
look like?

Lee

Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

James Ladd
btw

import: 'packagespec'.

is short hand for

self import: 'packagespec'.

On Sun, Dec 18, 2011 at 8:37 AM, James Ladd <[hidden email]> wrote:
Redline classes are imported by default, but for this answer lets assume they
are not. The code would look like this:

import: 'st.redline.Date'
Date < MyClass

The MyClass.st file would be in the folder com/foo/boo

Your project can put your source folders where ever you want, and use the
-s option of stic to tell it where the root is. This follows the Java convention
for packages - which was easier to fit into rather than fight against.



On Sun, Dec 18, 2011 at 8:32 AM, Lee <[hidden email]> wrote:
Thanks for all those answers.

> > Does the class name syntax support namespaces?
>
> We have namespaces. I'm not sure exactly what your question means beyond
> that.

Say I want to write a class MyClass in namespace com.foo.boo which is
a subclass of, say, st.redline.Date. What would the class declaration
look like?

Lee


Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

Lee Breisacher-2
> import: 'packagespec'.> > is short hand for> > self import: 'packagespec'.
Interesting..what is "self" in this case? This sorta gets back to the
file format. I've noticed that a file can contain either a class def
(Object < #Collection..) or just expressions (| x | x := 3. ...).

Lee
On Dec 17, 1:39 pm, James Ladd <[hidden email]> wrote:

> btw
>
> import: 'packagespec'.
>
> is short hand for
>
> self import: 'packagespec'.
>
>
>
>
>
>
>
> On Sun, Dec 18, 2011 at 8:37 AM, James Ladd <[hidden email]> wrote:
> > Redline classes are imported by default, but for this answer lets assume
> > they
> > are not. The code would look like this:
>
> > import: 'st.redline.Date'
> > Date < MyClass
>
> > The MyClass.st file would be in the folder com/foo/boo
>
> > Your project can put your source folders where ever you want, and use the
> > -s option of stic to tell it where the root is. This follows the Java
> > convention
> > for packages - which was easier to fit into rather than fight against.
>
> > On Sun, Dec 18, 2011 at 8:32 AM, Lee <[hidden email]> wrote:
>
> >> Thanks for all those answers.
>
> >> > > Does the class name syntax support namespaces?
>
> >> > We have namespaces. I'm not sure exactly what your question means beyond
> >> > that.
>
> >> Say I want to write a class MyClass in namespace com.foo.boo which is
> >> a subclass of, say, st.redline.Date. What would the class declaration
> >> look like?
>
> >> Lee
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

SeanTAllen
In the case of Object < #Collection

It is a class. 

In the case of 

| x |

x := 3

It is a script that is the equivalent to executing the code within a Smalltalk workspace.

Make sense?

James can correct me on this as I always misspeak slightly on this. But that is the general idea.


On Sat, Dec 17, 2011 at 7:49 PM, Lee <[hidden email]> wrote:
> import: 'packagespec'.> > is short hand for> > self import: 'packagespec'.
Interesting..what is "self" in this case? This sorta gets back to the
file format. I've noticed that a file can contain either a class def
(Object < #Collection..) or just expressions (| x | x := 3. ...).

Lee
On Dec 17, 1:39 pm, James Ladd <[hidden email]> wrote:
> btw
>
> import: 'packagespec'.
>
> is short hand for
>
> self import: 'packagespec'.
>
>
>
>
>
>
>
> On Sun, Dec 18, 2011 at 8:37 AM, James Ladd <[hidden email]> wrote:
> > Redline classes are imported by default, but for this answer lets assume
> > they
> > are not. The code would look like this:
>
> > import: 'st.redline.Date'
> > Date < MyClass
>
> > The MyClass.st file would be in the folder com/foo/boo
>
> > Your project can put your source folders where ever you want, and use the
> > -s option of stic to tell it where the root is. This follows the Java
> > convention
> > for packages - which was easier to fit into rather than fight against.
>
> > On Sun, Dec 18, 2011 at 8:32 AM, Lee <[hidden email]> wrote:
>
> >> Thanks for all those answers.
>
> >> > > Does the class name syntax support namespaces?
>
> >> > We have namespaces. I'm not sure exactly what your question means beyond
> >> > that.
>
> >> Say I want to write a class MyClass in namespace com.foo.boo which is
> >> a subclass of, say, st.redline.Date. What would the class declaration
> >> look like?
>
> >> Lee

Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

Lee Breisacher-2
hm, not sure I get it. James said import: is shorthand for 'self
import:'. So what is the reciever? I do not see an #import: method in
any of the existing classes. Where is that import implemented?

Also, I'm sortof uneasy about any kind of "shorthand". One of the
things that makes Smalltalk excellent is that there is one and only
one way of doing something. The #1 rule (and #2 rule imo) is,
Everything is an object and you always send messages to objects.
That's it.  This means you always supply "self" (unlike java where
foo() works just as well as this.foo() -- it's a small thing, but all
these little small inconsistencies add up to language weakness imo).
Smalltalk is simple yet powerful.

Two cents...

Lee

On Dec 17, 5:01 pm, Sean Allen <[hidden email]> wrote:

> In the case of Object < #Collection
>
> It is a class.
>
> In the case of
>
> | x |
>
> x := 3
>
> It is a script that is the equivalent to executing the code within a
> Smalltalk workspace.
>
> Make sense?
>
> James can correct me on this as I always misspeak slightly on this. But
> that is the general idea.
>
>
>
>
>
>
>
> On Sat, Dec 17, 2011 at 7:49 PM, Lee <[hidden email]> wrote:
> > > import: 'packagespec'.> > is short hand for> > self import:
> > 'packagespec'.
> > Interesting..what is "self" in this case? This sorta gets back to the
> > file format. I've noticed that a file can contain either a class def
> > (Object < #Collection..) or just expressions (| x | x := 3. ...).
>
> > Lee
> > On Dec 17, 1:39 pm, James Ladd <[hidden email]> wrote:
> > > btw
>
> > > import: 'packagespec'.
>
> > > is short hand for
>
> > > self import: 'packagespec'.
>
> > > On Sun, Dec 18, 2011 at 8:37 AM, James Ladd <[hidden email]>
> > wrote:
> > > > Redline classes are imported by default, but for this answer lets
> > assume
> > > > they
> > > > are not. The code would look like this:
>
> > > > import: 'st.redline.Date'
> > > > Date < MyClass
>
> > > > The MyClass.st file would be in the folder com/foo/boo
>
> > > > Your project can put your source folders where ever you want, and use
> > the
> > > > -s option of stic to tell it where the root is. This follows the Java
> > > > convention
> > > > for packages - which was easier to fit into rather than fight against.
>
> > > > On Sun, Dec 18, 2011 at 8:32 AM, Lee <[hidden email]> wrote:
>
> > > >> Thanks for all those answers.
>
> > > >> > > Does the class name syntax support namespaces?
>
> > > >> > We have namespaces. I'm not sure exactly what your question means
> > beyond
> > > >> > that.
>
> > > >> Say I want to write a class MyClass in namespace com.foo.boo which is
> > > >> a subclass of, say, st.redline.Date. What would the class declaration
> > > >> look like?
>
> > > >> Lee
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

James Ladd
Ok, you can write

self import: 'com.foo.*'.

and it will work. In this case the self is the EigenClass that represents the file.
A class is created to represent the file and executed - the result being the execution
of the statements within the file. When 'self import:" is send the EigenClass
has the imported classes added to their name space, this then help when a class
is looked up, which in the first instance is looked up against this EigenClass.

I'm writing an extensive blog post on this.

The import method itself is implemented in the Java class:
src/main/java/st/redline/bootstrap/ImportMethod.java

This is because the import may be required before the full Smalltalk runtime is
ready.

I'll think more about what you have said. Ironically the preprocessor turns import into self import.



On Sun, Dec 18, 2011 at 12:17 PM, Lee <[hidden email]> wrote:
hm, not sure I get it. James said import: is shorthand for 'self
import:'. So what is the reciever? I do not see an #import: method in
any of the existing classes. Where is that import implemented?

Also, I'm sortof uneasy about any kind of "shorthand". One of the
things that makes Smalltalk excellent is that there is one and only
one way of doing something. The #1 rule (and #2 rule imo) is,
Everything is an object and you always send messages to objects.
That's it.  This means you always supply "self" (unlike java where
foo() works just as well as this.foo() -- it's a small thing, but all
these little small inconsistencies add up to language weakness imo).
Smalltalk is simple yet powerful.

Two cents...

Lee

On Dec 17, 5:01 pm, Sean Allen <[hidden email]> wrote:
> In the case of Object < #Collection
>
> It is a class.
>
> In the case of
>
> | x |
>
> x := 3
>
> It is a script that is the equivalent to executing the code within a
> Smalltalk workspace.
>
> Make sense?
>
> James can correct me on this as I always misspeak slightly on this. But
> that is the general idea.
>
>
>
>
>
>
>
> On Sat, Dec 17, 2011 at 7:49 PM, Lee <[hidden email]> wrote:
> > > import: 'packagespec'.> > is short hand for> > self import:
> > 'packagespec'.
> > Interesting..what is "self" in this case? This sorta gets back to the
> > file format. I've noticed that a file can contain either a class def
> > (Object < #Collection..) or just expressions (| x | x := 3. ...).
>
> > Lee
> > On Dec 17, 1:39 pm, James Ladd <[hidden email]> wrote:
> > > btw
>
> > > import: 'packagespec'.
>
> > > is short hand for
>
> > > self import: 'packagespec'.
>
> > > On Sun, Dec 18, 2011 at 8:37 AM, James Ladd <[hidden email]>
> > wrote:
> > > > Redline classes are imported by default, but for this answer lets
> > assume
> > > > they
> > > > are not. The code would look like this:
>
> > > > import: 'st.redline.Date'
> > > > Date < MyClass
>
> > > > The MyClass.st file would be in the folder com/foo/boo
>
> > > > Your project can put your source folders where ever you want, and use
> > the
> > > > -s option of stic to tell it where the root is. This follows the Java
> > > > convention
> > > > for packages - which was easier to fit into rather than fight against.
>
> > > > On Sun, Dec 18, 2011 at 8:32 AM, Lee <[hidden email]> wrote:
>
> > > >> Thanks for all those answers.
>
> > > >> > > Does the class name syntax support namespaces?
>
> > > >> > We have namespaces. I'm not sure exactly what your question means
> > beyond
> > > >> > that.
>
> > > >> Say I want to write a class MyClass in namespace com.foo.boo which is
> > > >> a subclass of, say, st.redline.Date. What would the class declaration
> > > >> look like?
>
> > > >> Lee

Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

SeanTAllen
In reply to this post by Lee Breisacher-2
So roughly...

there is what really happens...

self import:

and then we have a preprocessor for source that take the textual representation and turns into message sends.

So, in a sense the implicit isn't actually implicit. It is a preprocessor shortcut for right the code.

I think that having to type

self import: x.
self import: y.

etc is going to get annoying to people.

although they could do

self import: x;
      import: y.

So, we have a preprocessor that take a more human friendly format and turns it into message sends.

My idea is that someday much like how at the top of a racket file you indicate a language ( aka set of reader macros
used to interpret the source ), we too would have that with redline. An example usage could be to have a syntax
that is like pattern matching in Erlang or Haskell but have it turned into message sends.




On Sat, Dec 17, 2011 at 8:17 PM, Lee <[hidden email]> wrote:
hm, not sure I get it. James said import: is shorthand for 'self
import:'. So what is the reciever? I do not see an #import: method in
any of the existing classes. Where is that import implemented?

Also, I'm sortof uneasy about any kind of "shorthand". One of the
things that makes Smalltalk excellent is that there is one and only
one way of doing something. The #1 rule (and #2 rule imo) is,
Everything is an object and you always send messages to objects.
That's it.  This means you always supply "self" (unlike java where
foo() works just as well as this.foo() -- it's a small thing, but all
these little small inconsistencies add up to language weakness imo).
Smalltalk is simple yet powerful.

Two cents...

Lee

On Dec 17, 5:01 pm, Sean Allen <[hidden email]> wrote:
> In the case of Object < #Collection
>
> It is a class.
>
> In the case of
>
> | x |
>
> x := 3
>
> It is a script that is the equivalent to executing the code within a
> Smalltalk workspace.
>
> Make sense?
>
> James can correct me on this as I always misspeak slightly on this. But
> that is the general idea.
>
>
>
>
>
>
>
> On Sat, Dec 17, 2011 at 7:49 PM, Lee <[hidden email]> wrote:
> > > import: 'packagespec'.> > is short hand for> > self import:
> > 'packagespec'.
> > Interesting..what is "self" in this case? This sorta gets back to the
> > file format. I've noticed that a file can contain either a class def
> > (Object < #Collection..) or just expressions (| x | x := 3. ...).
>
> > Lee
> > On Dec 17, 1:39 pm, James Ladd <[hidden email]> wrote:
> > > btw
>
> > > import: 'packagespec'.
>
> > > is short hand for
>
> > > self import: 'packagespec'.
>
> > > On Sun, Dec 18, 2011 at 8:37 AM, James Ladd <[hidden email]>
> > wrote:
> > > > Redline classes are imported by default, but for this answer lets
> > assume
> > > > they
> > > > are not. The code would look like this:
>
> > > > import: 'st.redline.Date'
> > > > Date < MyClass
>
> > > > The MyClass.st file would be in the folder com/foo/boo
>
> > > > Your project can put your source folders where ever you want, and use
> > the
> > > > -s option of stic to tell it where the root is. This follows the Java
> > > > convention
> > > > for packages - which was easier to fit into rather than fight against.
>
> > > > On Sun, Dec 18, 2011 at 8:32 AM, Lee <[hidden email]> wrote:
>
> > > >> Thanks for all those answers.
>
> > > >> > > Does the class name syntax support namespaces?
>
> > > >> > We have namespaces. I'm not sure exactly what your question means
> > beyond
> > > >> > that.
>
> > > >> Say I want to write a class MyClass in namespace com.foo.boo which is
> > > >> a subclass of, say, st.redline.Date. What would the class declaration
> > > >> look like?
>
> > > >> Lee

Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

Lee Breisacher-2
Thanks for the explanations. This stuff is obviously at the boundary
between "pure" Smalltalk and the world it is living inside of (JVM),
so I suppose there's some leeway. But still, I personally would fight
hard to keep things as pure as possible. There's very little
difference between

import: x.
import: y.

and

self import: x; import: y.

So why not enforce the "self"?  Also note that, for Java (where
imports can also be a pain), eclipse completely handles them for me.
We will surely have nice development tools like eclipse for redline,
right?

Lee

On Dec 18, 4:47 am, Sean Allen <[hidden email]> wrote:

> So roughly...
>
> there is what really happens...
>
> self import:
>
> and then we have a preprocessor for source that take the textual
> representation and turns into message sends.
>
> So, in a sense the implicit isn't actually implicit. It is a preprocessor
> shortcut for right the code.
>
> I think that having to type
>
> self import: x.
> self import: y.
>
> etc is going to get annoying to people.
>
> although they could do
>
> self import: x;
>       import: y.
>
> So, we have a preprocessor that take a more human friendly format and turns
> it into message sends.
>
> My idea is that someday much like how at the top of a racket file you
> indicate a language ( aka set of reader macros
> used to interpret the source ), we too would have that with redline. An
> example usage could be to have a syntax
> that is like pattern matching in Erlang or Haskell but have it turned into
> message sends.
>
>
>
>
>
>
>
> On Sat, Dec 17, 2011 at 8:17 PM, Lee <[hidden email]> wrote:
> > hm, not sure I get it. James said import: is shorthand for 'self
> > import:'. So what is the reciever? I do not see an #import: method in
> > any of the existing classes. Where is that import implemented?
>
> > Also, I'm sortof uneasy about any kind of "shorthand". One of the
> > things that makes Smalltalk excellent is that there is one and only
> > one way of doing something. The #1 rule (and #2 rule imo) is,
> > Everything is an object and you always send messages to objects.
> > That's it.  This means you always supply "self" (unlike java where
> > foo() works just as well as this.foo() -- it's a small thing, but all
> > these little small inconsistencies add up to language weakness imo).
> > Smalltalk is simple yet powerful.
>
> > Two cents...
>
> > Lee
>
> > On Dec 17, 5:01 pm, Sean Allen <[hidden email]> wrote:
> > > In the case of Object < #Collection
>
> > > It is a class.
>
> > > In the case of
>
> > > | x |
>
> > > x := 3
>
> > > It is a script that is the equivalent to executing the code within a
> > > Smalltalk workspace.
>
> > > Make sense?
>
> > > James can correct me on this as I always misspeak slightly on this. But
> > > that is the general idea.
>
> > > On Sat, Dec 17, 2011 at 7:49 PM, Lee <[hidden email]> wrote:
> > > > > import: 'packagespec'.> > is short hand for> > self import:
> > > > 'packagespec'.
> > > > Interesting..what is "self" in this case? This sorta gets back to the
> > > > file format. I've noticed that a file can contain either a class def
> > > > (Object < #Collection..) or just expressions (| x | x := 3. ...).
>
> > > > Lee
> > > > On Dec 17, 1:39 pm, James Ladd <[hidden email]> wrote:
> > > > > btw
>
> > > > > import: 'packagespec'.
>
> > > > > is short hand for
>
> > > > > self import: 'packagespec'.
>
> > > > > On Sun, Dec 18, 2011 at 8:37 AM, James Ladd <[hidden email]>
> > > > wrote:
> > > > > > Redline classes are imported by default, but for this answer lets
> > > > assume
> > > > > > they
> > > > > > are not. The code would look like this:
>
> > > > > > import: 'st.redline.Date'
> > > > > > Date < MyClass
>
> > > > > > The MyClass.st file would be in the folder com/foo/boo
>
> > > > > > Your project can put your source folders where ever you want, and
> > use
> > > > the
> > > > > > -s option of stic to tell it where the root is. This follows the
> > Java
> > > > > > convention
> > > > > > for packages - which was easier to fit into rather than fight
> > against.
>
> > > > > > On Sun, Dec 18, 2011 at 8:32 AM, Lee <[hidden email]>
> > wrote:
>
> > > > > >> Thanks for all those answers.
>
> > > > > >> > > Does the class name syntax support namespaces?
>
> > > > > >> > We have namespaces. I'm not sure exactly what your question
> > means
> > > > beyond
> > > > > >> > that.
>
> > > > > >> Say I want to write a class MyClass in namespace com.foo.boo
> > which is
> > > > > >> a subclass of, say, st.redline.Date. What would the class
> > declaration
> > > > > >> look like?
>
> > > > > >> Lee
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

SeanTAllen


On Sun, Dec 18, 2011 at 9:04 AM, Lee <[hidden email]> wrote:
We will surely have nice development tools like eclipse for redline,
right?

Stefan started work on an eclipse plugin.


We really need some people to join in to get this through to completion.
*hint* *hint*

-Sean-
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

Lee Breisacher-2
Yes, I downloaded and installed Stefan's plugin yesterday, but could not quite get it working. I sent an email to Stefan about it. Maybe I should post that email here also. 
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

James Ladd
If people are ok with

self import: ''

I can take the short hand out of the pre-processor.

I *REALLY* appreciate the thought you are putting in

On Mon, Dec 19, 2011 at 1:33 AM, Lee Breisacher <[hidden email]> wrote:
Yes, I downloaded and installed Stefan's plugin yesterday, but could not quite get it working. I sent an email to Stefan about it. Maybe I should post that email here also. 

Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

Steven! Ragnarök
On 12/18/11 12:47 PM, James Ladd wrote:

> If people are ok with
>
> self import: ''
>
> I can take the short hand out of the pre-processor.
>
> I *REALLY* appreciate the thought you are putting in
>
> On Mon, Dec 19, 2011 at 1:33 AM, Lee Breisacher <[hidden email]
> <mailto:[hidden email]>> wrote:
>
>     Yes, I downloaded and installed Stefan's plugin yesterday, but could
>     not quite get it working. I sent an email to Stefan about it. Maybe
>     I should post that email here also.
>
>

As a non-Smalltalker, I'm certainly not offended or put off by
``` redline-st
self import: 'aFile.st';
   import: 'anotherFile.st'.
```

It seems similar enough to Ruby's
``` ruby
Dir.glob("controllers/*_controller.rb").each do |controller|
   require_relative controller
end
```

It's also far more indicative of the fact that you can load code
programmatically rather than only through the use of #includes and
import java.util.*; declarations as in C-style languages and Java.

--
Steven! Ragnarök
T 408 256 0278
[hidden email]
http://nuclearsandwich.com
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

SeanTAllen


On Sun, Dec 18, 2011 at 3:51 PM, "Steven! Ragnarök" <[hidden email]> wrote:
On 12/18/11 12:47 PM, James Ladd wrote:
If people are ok with

self import: ''

I can take the short hand out of the pre-processor.

I *REALLY* appreciate the thought you are putting in

On Mon, Dec 19, 2011 at 1:33 AM, Lee Breisacher <[hidden email]
<mailto:[hidden email]>> wrote:

   Yes, I downloaded and installed Stefan's plugin yesterday, but could
   not quite get it working. I sent an email to Stefan about it. Maybe
   I should post that email here also.



As a non-Smalltalker, I'm certainly not offended or put off by
``` redline-st
self import: 'aFile.st';
 import: 'anotherFile.st'.
```

It seems similar enough to Ruby's
``` ruby
Dir.glob("controllers/*_controller.rb").each do |controller|
 require_relative controller
end
```


This does start down a slippery slope in that there are other changes that should logically be done.
Each seemingly not that big but when you look at the end result. Its a little, *eh*. 

I think this could be an interesting discussion to have again someday but not now.

James, myself & Hernan Wilkinson spent a large amount of time in the spring trying to come up with a good balance.
( and then got input from Stéfan Ducasse, Avi Bryant and a mess of other people I can't remember right now ).

Given the ability to swap out preprocessors eventually, I'd rather reopen issues of syntax like this at a later point in time.

I personally want to come up with a homoiconic way of representing Smalltalk and have it eventually be the preferred form.
That said, I think what we have is a nice balance between that and something that shouldn't turn off people who prefer
more brevity. I'd rather we put our energies into bigger problems like IDE integration, koans, porting and the other massive 
tons of work that remain to be done.

-Sean-
Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

bobcalco
So basically, 'self' in the context of a method block refers to the class in whose scope it is written, and 'self' outside of a method block refers to the file in which the code is written? In this case, it is made implicit and thus grammatically unnecessary -- is that the idea?

I can see the benefit of this non-standard approach for conciseness but GNU Smalltalk takes a file-based approach with far fewer such unusual modifications to the language (it seems to me). Why is GNU Smalltalk syntax not adopted as the model for file-based Redline (even if library compatibility wise it Redline aspires to close similarity with Pharo)? 

Personally, image-based development is one of the things I find most compelling and even liberating about Smalltalk (if you can keep your image healthy, and safely backed up, of course). I don't have a problem with file-based coding a la GNU Smalltalk, and I love the idea of being able to use file-bsaed sources to construct ad hoc images. However I think an image-based environment for coding must be at least optionally available to really bring the spirit of the language to the JVM.

I remember back in the late 90's watching a person code in IBM VisualAge for Java. I remember thinking how odd it was, and I didn't see much value in it. (This is because I didn't have the Smalltalk background required to grasp the metaphors it was using). Now I realize what they were trying to do with it.

In retrospect I can only imagine if IBM had instead ported VisualAge Smalltalk to the JVM, instead of trying to make Java development 'feel like' VA development, where Smalltalk would be? But the JVM in those early days was probably not up to snuff at all for such a mammoth undertaking. Even now hacks like type erasure and lack of real tail-call optimization etc. annoy me about it. But it's pretty impressive how close Redline is to achieving that, I must admit.

And this is one reason I'm excited about Redline. I've never really been a huge JVM evangelist -- actually I'm rather agnostic about such matters, and enjoy a lot of different platforms, native and VM-based. But I think Redline is one of the surest ways to bring Smalltalk's best concepts and liberating syntax back to life. The JVM has many things to commend it, but none so compelling as its user base. How ironic if after all these years Smalltalk can hijack Java's VM to spring back into the mainstream. I like it when what is 'old' is made 'new' again. :)

- Bob

On Sun, Dec 18, 2011 at 9:21 PM, Sean Allen <[hidden email]> wrote:


On Sun, Dec 18, 2011 at 3:51 PM, "Steven! Ragnarök" <[hidden email]> wrote:
On 12/18/11 12:47 PM, James Ladd wrote:
If people are ok with

self import: ''

I can take the short hand out of the pre-processor.

I *REALLY* appreciate the thought you are putting in

On Mon, Dec 19, 2011 at 1:33 AM, Lee Breisacher <[hidden email]
<mailto:[hidden email]>> wrote:

   Yes, I downloaded and installed Stefan's plugin yesterday, but could
   not quite get it working. I sent an email to Stefan about it. Maybe
   I should post that email here also.



As a non-Smalltalker, I'm certainly not offended or put off by
``` redline-st
self import: 'aFile.st';
 import: 'anotherFile.st'.
```

It seems similar enough to Ruby's
``` ruby
Dir.glob("controllers/*_controller.rb").each do |controller|
 require_relative controller
end
```


This does start down a slippery slope in that there are other changes that should logically be done.
Each seemingly not that big but when you look at the end result. Its a little, *eh*. 

I think this could be an interesting discussion to have again someday but not now.

James, myself & Hernan Wilkinson spent a large amount of time in the spring trying to come up with a good balance.
( and then got input from Stéfan Ducasse, Avi Bryant and a mess of other people I can't remember right now ).

Given the ability to swap out preprocessors eventually, I'd rather reopen issues of syntax like this at a later point in time.

I personally want to come up with a homoiconic way of representing Smalltalk and have it eventually be the preferred form.
That said, I think what we have is a nice balance between that and something that shouldn't turn off people who prefer
more brevity. I'd rather we put our energies into bigger problems like IDE integration, koans, porting and the other massive 
tons of work that remain to be done.

-Sean-

Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

James Ladd
Response inline ...

On Mon, Dec 19, 2011 at 8:30 PM, Robert Calco <[hidden email]> wrote:
So basically, 'self' in the context of a method block refers to the class in whose scope it is written, and 'self' outside of a method block refers to the file in which the code is written? In this case, it is made implicit and thus grammatically unnecessary -- is that the idea
Yes.
 
I can see the benefit of this non-standard approach for conciseness but GNU Smalltalk takes a file-based approach with far fewer such unusual modifications to the language (it seems to me). Why is GNU Smalltalk syntax not adopted as the model for file-based Redline (even if library compatibility wise it Redline aspires to close similarity with Pharo)? 

While GNU Smalltalk is great, its file format requires more work than Redline. ie: [] to delimit various 'chunks' if the
file. RL has the goal requiring you to add the least amount of additional keystrokes. +/- is pretty minimal.
 

Personally, image-based development is one of the things I find most compelling and even liberating about Smalltalk (if you can keep your image healthy, and safely backed up, of course). I don't have a problem with file-based coding a la GNU Smalltalk, and I love the idea of being able to use file-bsaed sources to construct ad hoc images. However I think an image-based environment for coding must be at least optionally available to really bring the spirit of the language to the JVM.
There is a project for the JVM that is attempting to snapshot the memory image to disk. When this is available we will look at
incorporating it to make an "image"
 

I remember back in the late 90's watching a person code in IBM VisualAge for Java. I remember thinking how odd it was, and I didn't see much value in it. (This is because I didn't have the Smalltalk background required to grasp the metaphors it was using). Now I realize what they were trying to do with it.

In retrospect I can only imagine if IBM had instead ported VisualAge Smalltalk to the JVM, instead of trying to make Java development 'feel like' VA development, where Smalltalk would be? But the JVM in those early days was probably not up to snuff at all for such a mammoth undertaking. Even now hacks like type erasure and lack of real tail-call optimization etc. annoy me about it. But it's pretty impressive how close Redline is to achieving that, I must admit.

Wait until you see the ability to change classes on the fly. We hope you will continue to be impressed.
 
And this is one reason I'm excited about Redline. I've never really been a huge JVM evangelist -- actually I'm rather agnostic about such matters, and enjoy a lot of different platforms, native and VM-based. But I think Redline is one of the surest ways to bring Smalltalk's best concepts and liberating syntax back to life. The JVM has many things to commend it, but none so compelling as its user base. How ironic if after all these years Smalltalk can hijack Java's VM to spring back into the mainstream. I like it when what is 'old' is made 'new' again. :)

Bringing Smalltalk back to life and to a wider audience is our dream.
We are glad to have your interest.
 
- Bob


On Sun, Dec 18, 2011 at 9:21 PM, Sean Allen <[hidden email]> wrote:


On Sun, Dec 18, 2011 at 3:51 PM, "Steven! Ragnarök" <[hidden email]> wrote:
On 12/18/11 12:47 PM, James Ladd wrote:
If people are ok with

self import: ''

I can take the short hand out of the pre-processor.

I *REALLY* appreciate the thought you are putting in

On Mon, Dec 19, 2011 at 1:33 AM, Lee Breisacher <[hidden email]
<mailto:[hidden email]>> wrote:

   Yes, I downloaded and installed Stefan's plugin yesterday, but could
   not quite get it working. I sent an email to Stefan about it. Maybe
   I should post that email here also.



As a non-Smalltalker, I'm certainly not offended or put off by
``` redline-st
self import: 'aFile.st';
 import: 'anotherFile.st'.
```

It seems similar enough to Ruby's
``` ruby
Dir.glob("controllers/*_controller.rb").each do |controller|
 require_relative controller
end
```


This does start down a slippery slope in that there are other changes that should logically be done.
Each seemingly not that big but when you look at the end result. Its a little, *eh*. 

I think this could be an interesting discussion to have again someday but not now.

James, myself & Hernan Wilkinson spent a large amount of time in the spring trying to come up with a good balance.
( and then got input from Stéfan Ducasse, Avi Bryant and a mess of other people I can't remember right now ).

Given the ability to swap out preprocessors eventually, I'd rather reopen issues of syntax like this at a later point in time.

I personally want to come up with a homoiconic way of representing Smalltalk and have it eventually be the preferred form.
That said, I think what we have is a nice balance between that and something that shouldn't turn off people who prefer
more brevity. I'd rather we put our energies into bigger problems like IDE integration, koans, porting and the other massive 
tons of work that remain to be done.

-Sean-


Reply | Threaded
Open this post in threaded view
|

Re: redline plans/vision

bobcalco
James,

On Tue, Dec 20, 2011 at 8:53 AM, James Ladd <[hidden email]> wrote:
Response inline ...

On Mon, Dec 19, 2011 at 8:30 PM, Robert Calco <[hidden email]> wrote:
So basically, 'self' in the context of a method block refers to the class in whose scope it is written, and 'self' outside of a method block refers to the file in which the code is written? In this case, it is made implicit and thus grammatically unnecessary -- is that the idea
Yes.
 
I can see the benefit of this non-standard approach for conciseness but GNU Smalltalk takes a file-based approach with far fewer such unusual modifications to the language (it seems to me). Why is GNU Smalltalk syntax not adopted as the model for file-based Redline (even if library compatibility wise it Redline aspires to close similarity with Pharo)? 

While GNU Smalltalk is great, its file format requires more work than Redline. ie: [] to delimit various 'chunks' if the
file. RL has the goal requiring you to add the least amount of additional keystrokes. +/- is pretty minimal.

Point taken. I do like it better. I suppose at the end of the day it's not a big deal to change a few of these kinds of things. Compatibility is nice but progress is better.

 

Personally, image-based development is one of the things I find most compelling and even liberating about Smalltalk (if you can keep your image healthy, and safely backed up, of course). I don't have a problem with file-based coding a la GNU Smalltalk, and I love the idea of being able to use file-bsaed sources to construct ad hoc images. However I think an image-based environment for coding must be at least optionally available to really bring the spirit of the language to the JVM.
There is a project for the JVM that is attempting to snapshot the memory image to disk. When this is available we will look at
incorporating it to make an "image"

Hmmm. Do you have a link for that project?
 
 

I remember back in the late 90's watching a person code in IBM VisualAge for Java. I remember thinking how odd it was, and I didn't see much value in it. (This is because I didn't have the Smalltalk background required to grasp the metaphors it was using). Now I realize what they were trying to do with it.

In retrospect I can only imagine if IBM had instead ported VisualAge Smalltalk to the JVM, instead of trying to make Java development 'feel like' VA development, where Smalltalk would be? But the JVM in those early days was probably not up to snuff at all for such a mammoth undertaking. Even now hacks like type erasure and lack of real tail-call optimization etc. annoy me about it. But it's pretty impressive how close Redline is to achieving that, I must admit.

Wait until you see the ability to change classes on the fly. We hope you will continue to be impressed.

How will that work?
 
 
And this is one reason I'm excited about Redline. I've never really been a huge JVM evangelist -- actually I'm rather agnostic about such matters, and enjoy a lot of different platforms, native and VM-based. But I think Redline is one of the surest ways to bring Smalltalk's best concepts and liberating syntax back to life. The JVM has many things to commend it, but none so compelling as its user base. How ironic if after all these years Smalltalk can hijack Java's VM to spring back into the mainstream. I like it when what is 'old' is made 'new' again. :)

Bringing Smalltalk back to life and to a wider audience is our dream.
We are glad to have your interest.

And more than my interest. I was so jazzed by my experience with Smalltalk recently that I was about to embark on an insane adventure to implement a new Smalltalk VM using Delphi XE2, mainly because I covet the 2D and 3D GPU-powered capabilities of its new cross-platform UI framework, FireMonkey. 

However, that is a *very difficult* and lonely road and I need something now that is going to prepare me for it. Redline is the perfect chance to jump into a new Smalltalk in media res, and from a sufficiently different frame of reference to give me a needed wider perspective. So, I am deferring that and ready to commit my time to this first.

I've been taking some time to study the existing code so that I understand it before I get too gung-ho on the runtime work, and I'm really liking what I'm seeing. As I mentioned previously I'm most excited about using it for data visualization, a la Processing, and would love to come up with something that competes admirably with Processing in that space.

- Bob