Hacker News new | past | comments | ask | show | jobs | submit login
New release of Self programming language (selflanguage.org)
105 points by russellallen on Jan 12, 2014 | hide | past | favorite | 42 comments



Haha ... funny to read about people scratching their head over Self. I feel like once you've wrapped your head around the Squeak version of Smalltalk, your about 50% of the way towards understanding Self. It's not a language the way we think of it, with CLI tools and syntax and text editors. It is a mutable environment of programmable objects. Sure there's some writing inside of objects to create methods, but you're not gonna find a "try this in the browser" code.

Self is/was http://noflojs.org/ 's grandfather.

http://www.youtube.com/watch?v=NYEKO7JcmLE

I would also argue that Self is to programming languages what Haiku is to OS development. No on is writing a web framework in self, it's more of a toy and a neat artifact of where programming has been and could go in the future.


Smalltalk is still class based. The only strong connection between Self and Squeak is Morphic.


Much of the syntax is similar too:

  (2 + 4) == 5 ifTrue: [ Transcript show: 'Yay!' ] "Squeak"
  (2 + 4) == 5 ifTrue: [ 'Yay!' printLine ] "Self"


C and Java also have a similar syntax.

Most of the Self people were Smalltalk people before, so you could see Self as being heavily inspired by Smalltalk in its syntax and image-based persistence. However Squeak is still Smalltalk while Self is a full successor language (you could say Morphic was backported from Self back to Smalltalk).


I feel like my personal challenges coming to understand Self are often exaggerated by Morphic. Most of the linguistic notions I gather from reading papers aren't too tough, but I always bounce off when trying to translate that to effects in the Self environment.


A.K.A. UI poorly solved usability challenges.

In a way, the fundamentals of Self is the future of programming but we need to get designers helping with the UI/UX

Smalltalk has a similar challenge


I encounter that too. I started writing Self code in a text editor and loading it in the REPL. Some of the code shipped with Self is like this (The Mango parser code for example).

Once I was more familiar I started learning the GUI environment. It took me a while to work out how the object transporter worked to export code back to text files but once I got that Self became a lot more friendly to use.


See, I'd love to do that but I don't think the documentation ever bothers to explain it.


I stand corrected :)


There is actually a basic web server example. It includes a web based object browser. I'm not sure if it's in the 4.5.0 release but it's one of the branches IIRC.


They mean you won't find something like http://tryruby.org


It is done for Smalltalk. Why not for Self?

http://amber-lang.net/


If this language is looking for greater adoption, its website is doing a big disservice. It is incredibly challenging to find a single code snippet, and the documentation is mediocre at best. The interfaces that are shown in the documentation remind me of the computer system you see DMV employees fumbling around with. I love picking up random languages on a Sunday, but not this one.


Yeah, its a fair cop. The website is old and more about people who already know about Self than people who don't. I'll put fixing it on my todo list.


Thank you for not taking my comment negatively, I completely understand the amount of work that goes into documentation and the other comments on this article helped me understand the usefulness of Self. I've bookmarked the page and will check it out some Sunday in the future.


That's the spirit!

It would be greatly appreciated


Just follow the link on the site to the Wikipedia article ;)


concur (and upvoted). i took a few minutes, peeked around at some other "niche" languages (you know, not exactly mainstream) to see how they fare in this - rust, D, julia, haskell - and compared them to python.org's website. python's is far more like the self site than like those others, it takes several clicks to get to a code snippet.

so, i concur, but i think it's (sadly) not alone in that shortcoming.


Self was one of the inspirations behind JavaScript, particularly its prototype system.

http://en.wikipedia.org/wiki/Self_(programming_language)


I spent some time with Self in the late 90s (at college of course!) and it was impressive on several counts: first, it's JIT compiler allowed Smalltalk to run faster when implemented in Self than without - the same JIT technique was later re-used in Java Hotspots [1]; second, the programming environment was a multi-user environment called Kansas that allowed a whole classroom of students to develop "prototypes" in the same environment (Kansas [2] [3])

[1] http://www.princeton.edu/~achaney/tmve/wiki100k/docs/Self_(p...

[2] http://web.media.mit.edu/~lieber/Lieberary/Softviz/CACM-Debu...

[3] http://bluishcoder.co.nz/2013/09/16/multiple-users-in-a-self...


Except for the part where what Self calls prototype has no equivalent in javascript (constructors are close to Self's `copy` message, but not quite the same) and what javascript calls prototype Self calls mixin (or traits, depending whether they've got ancestors up to the lobby themselves). And a Self object can have multiple mixins and add or remove them at runtime.


The "JavaScript is like Self" fallacy is just another variant of the "JavaScript is like Scheme" fallacy. It sounds great to the person claiming it, and to an unsuspecting audience. But on closer inspection, the similarities between the two languages are minimal at best.


Newtonscript was also a descendent. Although I like Objective-C, I do miss Newtonscript and the soup. Prototype-based programming often had a nicer feel than [edit]class[/edit] systems.

http://newtonscript.org - look at the "SELF and the Origins of NewtonScript" down the page


I've never heard of Self. So I wanted to find more about it. I had to click on several links to find some example of the language. I found this.[1]

    In the graphical representation of the object, we can distinguish
    method slots from data slots, and constant slots from assignable
    slots, by the icon in the button at the right hand of the slot.
Huh? Maybe I should go find a description of the language.[2]

    Self is an object-oriented programming language and associated
    programming environment. It is close in spirit and semantics to
    Smalltalk
Oh! Okay. Now I get it. But that's only because I'm vaguely familiar with Smalltalk.

(My intention of this comment is to save others some time trying to discover some basic facts about Self.)

[1] - http://selflanguage.org/_static/tutorial/Language/ObjectsAnd...

[2] - http://selflanguage.org/_static/tutorial/General/WhatIsSelf....



Thanks. I watched your videos and now I have a better clue about what Self is. It's personally not my cup of tea, but it would have been really nice if the Self web site had one of your videos on it (or something a bit more introductory). Particularly given its graphical nature...


I guess I'm the only dummy who wasn't thinking of the actual Self language and thought I was going to be reading about a programming language that wrote programs by itself.

Yeah. I'll show myself to the seat in the corner. Sheesh.


You're not alone...


There's some interesting Self papers listed in the /r/selflanguage reddit for those that want to do some reading:

http://www.reddit.com/r/selflanguage

This is my attempt at a JSON parser using Self's Mango parser package:

https://gist.github.com/doublec/7132119


IIRC, some of the techniques used in the Self VM eventually made it into the JVM.

Ahh yes, the relevant LtU thread. http://lambda-the-ultimate.org/node/1185#comment-12831


They transferred via Sun's acquisition of the Strongtalk team (that also got them Gilad Bracha). Strongtalk was also one of the first hybrid typed languages (like Dart and Typescript).

Much of the innovation in dynamic language run-times today also uses ideas from Self. Most of the Self people are working at Google today in various high positions.


Here's a talk from Lars Bak about v8 and Dart http://www.infoq.com/presentations/Performance-V8-Dart


and here is mine with a focus on the Dart VM and V8 optimizing compilers: http://www.infoq.com/presentations/dart-compiler


Very nice overview, thanks.


I always wonder if the Self people felt bad about their VM efforts going into Java. Java has really been one of the least inventive and progressive languages.


I doubt they would feel sad about their technology being adopted by a mainstream language used by millions of developers vs. a research experimental language that many outside of research haven't even heard of before.


wasnt smalltalk once a mainstream language? in ancient times, late 80s?


The number of programmers back then was much less than now, but even then I don't think Smalltalk was a top 10 language. I guess it depends on how you define mainstream, Smalltalk has/had its niches, some of which are still active. But there is nothing wrong with using research languages like self (which was never mainstream) to explore and develop new tech that can be applied to mainstream languages.


Presumably some of that effort is responsible for the JVM begin chosen to host other languages.


Java brought garbage collection into the mainstream. That alone is enough to consider it progressive.


Any big company with that kind of money and connections can bring pretty much anything into the mainstream, not a big merit IMHO...


I've always wondered that about Guy Steele. Must've been an awfully well-paid job.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: