HN Theater @HNTheaterMonth

The best talks and videos of Hacker News.

Hacker News Comments on
MPS Projectional Editor

JetBrainsTV · Youtube · 60 HN points · 3 HN comments
HN Theater has aggregated all Hacker News stories and comments that mention JetBrainsTV's video "MPS Projectional Editor".
Youtube Summary
The most distinct feature of MPS is its projectional editor that enables language designers to create languages with non-parseable notations, tables, math symbols, diagrams and form-like or context-sensitive syntaxes. MPS languages can easily be modularised and provide multiple switchable notations.
HN Theater Rankings

Hacker News Stories and Comments

All the comments and stories posted to Hacker News that reference this video.
Here's proportional font for camelCase programming. It adds a padding to the left of the capital letters, and has a much wider space character.

https://ericfortis.com/portfolio/design#-verdana-camel

---

For aligning content, I think IDEs should be able to represent some parts of the code as tables. For example, similar to the Decision Tables of Jetbrains Projectional Editor:

https://youtu.be/iN2PflvXUqQ?t=357

This reminds me a lot of JetBrains MPS and their projectional editing features. https://www.youtube.com/watch?v=iN2PflvXUqQ
mgubi
I didn't knew MPS but indeed seems quite similar. Both are structured editors, in the sense that you never work with "text" but with some projection of the underlying tree structure. For example you can ask TeXmacs to show you a representation where every node tree is explicit (which look very much HTML, but where you cannot have an open environment tag without the corresponding closing tag).
We should not be constrained of only text notation, so a technology like the projectional editor of Jetbrains mps should be there. https://www.youtube.com/watch?v=iN2PflvXUqQ
May 31, 2015 · 60 points, 15 comments · submitted by pron
arkadiyt
If you enjoy these types of compiler videos then I would highly recommend the following rants against Scala by Paul Phillips (from TypeSafe and one of the core language contributors). He also talks about wanting to edit abstract syntax trees directly: https://www.youtube.com/watch?v=TS1lpKBMkgg https://www.youtube.com/watch?v=uiJycy6dFSQ
NinoScript
I think this could be the future. Some tools (like Emacs' Paredit) are trying to do things like this with text but I think projectional editing is a better solution.

The problem is that it will take some kind of miracle or great revolution for it to ever have a place in our workflows.

muescha
One caveat with this projectional editor:

Not possible to copy and paste of code inside editor

Not possible to copy code snippets (for example from a website) and pasting into the editor.

Thats very weired to write the code - you can not write natural a text

(Tested with the workflow editor from youtrack - it was a bad experience)

escherize
Really nice tooling. I like how the editor guides you 'fill in the next blank'.

Since you write the AST directly, this seems to be a lisp without parentheses.

jbnicolai
Rather, 'under the hood' it _is_ a lisp (that is, an AST). The powerful feature here is that you visualize (project) the AST into a more concise representation
pron
All programming languages are represented as ASTs under the hood. There's no need to call an AST a Lisp.
lobo42
From someone who compared MPS with Xtext : "2 days of work in MPS were recreated in 30 min using XText"

http://arnon.me/wp-content/uploads/2015/06/DSL-summary.pdf

k__
If a JavaScript dev likes the idea of AST refactoring, I recommend a look into grasp[]. It's like grep but works with the AST representation of a file instead of the Text.

[] http://www.graspjs.com

ingenter
Somehow, I shudder when thinking about meta-programming and DSLs in Java.
mike_hearn
The point of the idea is, if you combined meta-programming and DSLs with Java, you don't have Java anymore. MPS calls their Java dialect "baseLanguage" and it's actually Java + a lot of small DSLs with custom renderings and editors.

MPS is one of the most mind blowing developer projects I ever encountered. But I first played with it years ago and have tried most versions since, and unfortunately it never made it past the "cool, neat, but I don't have a use for it" stage. Somehow I always end up back with regular IntelliJ and Java or Kotlin.

One reason: MPS is one of those concepts that's just such a huge leap over what we do today, I worry about losing other possible contributors if I use it. Also, for example, the projects are stored as giant XML files on disk, so github diff viewers and other text based tools wouldn't work. Perhaps I should just take the leap for a small personal project.

zokier
Sounds bit like the problems SmallTalk has encountered with their image files etc.
pjmlp
If you look at online demos how the Xerox PARC and Symbiotic systems were being used, it is not far off from MPS and similar.

Yet here we are still trying to make it mainstream.

atap
I know what you mean. Somewhere, out there, we'll find an MBA-type, trying to paste an Excel spreadsheet into one of those tabular data types, and a black hole will open up and swallow the Earth whole.
Too
Looks similar to how mathematica works, there you also type \sum <tab> and it will transform into the mathematical sum symbol and guide you to what should be filled in next with empty boxes. Really cool that they managed do generalize this and make it available for developers.

I'm mostly worried about copy-paste becoming troublesome, one of the biggest advantages of text editing is that it's so raw and if you know your tools you can transform a lot of it quickly instead of being constrained to repetetive clicking through clunky wizards and menus with your mouse.

tyilo
Don't you mean <esc> sumt <esc> ?
HN Theater is an independent project and is not operated by Y Combinator or any of the video hosting platforms linked to on this site.
~ yaj@
;laksdfhjdhksalkfj more things
yahnd.com ~ Privacy Policy ~
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.