Jump to content

Recommended Posts

Introduction thread here:

 

I am starting a new thread, because Meta has a new website:

https://language.metaproject.frl

 

The old links from the early development period are gone, and a few of the method names in the program examples have changed. I will post progress here now, so that the website is on top, and examples on the website, where they can be updated.

 

MortalCoil.png

Edited by Kaj de Vos
Added screenshot
  • Like 1

Share this post


Link to post
Share on other sites

Maybe it's me, but I can't find anything on the web site that shows anything on how

the language is structured, reserved words etc. etc.

 

There are no examples of the code and the link to examples in the Community come to this thread.

 

Please provide more technical information as to why this will be so good compared to other languages.

  • Like 1

Share this post


Link to post
Share on other sites

Philosophically, it kind of reminds me of FORTH in a way, it's a tool for creating your own language, essentially, thus the name Meta, I think. Cool if you are interested in playing around with language constructs, but I'm still not sure of applicability in our world, which is dominated by tight RAM and speed requirements. Not a shot, Kaj, just my viewpoint so far.

  • Like 1

Share this post


Link to post
Share on other sites
24 minutes ago, danwinslow said:

Philosophically, it kind of reminds me of FORTH in a way, it's a tool for creating your own language, essentially, thus the name Meta, I think. Cool if you are interested in playing around with language constructs, but I'm still not sure of applicability in our world, which is dominated by tight RAM and speed requirements. Not a shot, Kaj, just my viewpoint so far.

I'm afraid you might be right. Even if you master the Meta language, each domain specific language implemented in it could look totally different from each other.  Not sure if that is a good thing. Could you implement C in Meta? If there are indeed no keywords and everything can be redefined, this should be possible, is it?

Share this post


Link to post
Share on other sites

Just give it a try, you may be surprised.

 

I did my best to address these concerns over the past year in the development thread. Given that Meta can target 2600, do you not think it would be usable on 8-bit? Given that I have shown some hardware programming examples that generate identical code to hand-optimised assembly, do you think that would not be fast or small enough?

 

DSL's in Meta will not look totally different from each other, because they are dialects, that's the point of the design:

https://language.metaproject.frl/#how

 

It won't be possible to implement C in Meta the way you are hinting at, because Meta is defined at a higher level. There is no way to define pointers and some other unsafe constructs in the default Meta "do" dialect. You could still write a C compiler in Meta, but it would be more classic. It's C, so you have to write a text parser for the C specification, which is simply not a Meta dialect. Then you would have intermediate data which would by definition be some sort of Meta data dialect. But you can't compile it to the Meta "do" dialect, or even to the internal intermediate dialect of my compiler, because they are at a higher level than C. Well, you could, but you would have to include a very inefficient virtual machine emulating C. To achieve reasonable speed, you would have to write a fairly traditional code generator. That could generate the internal Meta dialects for the native back-ends of my compiler, but these are again quite far removed from the "do" dialect.

Share this post


Link to post
Share on other sites
30 minutes ago, Kaj de Vos said:

Just give it a try, you may be surprised.

 

I did my best to address these concerns over the past year in the development thread. Given that Meta can target 2600, do you not think it would be usable on 8-bit? Given that I have shown some hardware programming examples that generate identical code to hand-optimised assembly, do you think that would not be fast or small enough?

Sorry to say, but the examples you showed were mostly inline assembly, and in hexadecimal.

 

How about an example that prints the nth Fibonacci number?

 

Quote

DSL's in Meta will not look totally different from each other, because they are dialects, that's the point of the design:

https://language.metaproject.frl/#how

My assumption was that if there are indeed no keywords, and you can overload everything, the dialects could be far apart. Perhaps it hasn't happened yet with REBOL, but with Forth it definitely has, even though Forth has some reserved tokens.

 

Quote

It won't be possible to implement C in Meta the way you are hinting at, because Meta is defined at a higher level. There is no way to define pointers and some other unsafe constructs in the default Meta "do" dialect. You could still write a C compiler in Meta, but it would be more classic. It's C, so you have to write a text parser for the C specification, which is simply not a Meta dialect. Then you would have intermediate data which would by definition be some sort of Meta data dialect. But you can't compile it to the Meta "do" dialect, or even to the internal intermediate dialect of my compiler, because they are at a higher level than C. Well, you could, but you would have to include a very inefficient virtual machine emulating C. To achieve reasonable speed, you would have to write a fairly traditional code generator. That could generate the internal Meta dialects for the native back-ends of my compiler, but these are again quite far removed from the "do" dialect.

I see what you mean, as for Meta being at a higher level. How would you say Meta compares to Rust? Rust can do unsafe things if it really needs to and stick to its own syntax. Does Meta always needs inline assembly to be really unsafe, i.e. reading/writing hardware registers on a SOC or something?

 

BTW I'm not promoting Rust. I find its syntax terrible, and its community even worse ;) But they insist it could be used to write an OS. Could that be done in Meta?

 

Edited by ivop

Share this post


Link to post
Share on other sites
1 minute ago, ivop said:

Sorry to say, but the examples you showed were mostly inline assembly, and in hexadecimal.

 

Nope, look again.

 

2 minutes ago, ivop said:

How about an example that prints the nth Fibonacci number?

It's the third post in the above introduction thread, the first day I introduced the project.

 

7 minutes ago, ivop said:

My assumption was that if there are indeed no keywords, and you can overload everything, the dialects could be far apart. Perhaps it hasn't happened yet with REBOL, but with Forth it definitely has, even though Forth has some reserved tokens.

It's in the eye of the beholder. It would probably be similar to the situation in Forth, but those dialects are still much closer than for example Meta and C. The issue is real, but it's the same as programmers speaking a different kind of English than the man in the street. It can be just a secret language to keep that man in the street out of the club, but it's usually considered a more effective way for programmers to communicate amongst each other. It has a learning curve, but if you live long enough, you will profit.

 

Also, if this is a problem in Forth, how does that make Meta not applicable for Atari? Forth is one of the original language designs, always considered especially suited to small systems.

 

I do agree about your position on Rust. Dunno about its community, but I try to have similar language features in a much simpler way. Much smaller, too, surprisingly. Meta has minimal extra syntax to go into unsafe territory. We discussed it before.

 

I think there are a few small operating systems written in Rust, so that is true, although they include assembly. Actually, Meta already is an OS. What I didn't mention is that the compile.ape I released can also run as a boot sector on a bare metal PC. That is not a very useful mode to run the remote compiler in, but your own Meta programs will be able to use it when I release that.

Share this post


Link to post
Share on other sites
1 hour ago, Kaj de Vos said:

Nope, look again.

Sorry, should have said Atari examples.

1 hour ago, Kaj de Vos said:

It's the third post in the above introduction thread, the first day I introduced the project.

Does that run on an 8-bit Atari?

 

1 hour ago, Kaj de Vos said:

It's in the eye of the beholder. It would probably be similar to the situation in Forth, but those dialects are still much closer than for example Meta and C. The issue is real, but it's the same as programmers speaking a different kind of English than the man in the street. It can be just a secret language to keep that man in the street out of the club, but it's usually considered a more effective way for programmers to communicate amongst each other. It has a learning curve, but if you live long enough, you will profit.

Partly true. But if every company had its own kind of English, and you have to know the quirks and how something could mean something completely different than what you are accustomed to from a previous company, that's pretty hard to work with IMHO. Consider operator overloading in C++. It's a mess. You can never be sure what a+b means at a first reading of the code.

 

1 hour ago, Kaj de Vos said:

Also, if this is a problem in Forth, how does that make Meta not applicable for Atari? Forth is one of the original language designs, always considered especially suited to small systems.

Agreed. I never said Meta was not applicable for Atari. It could very well be if it compiles high level constructs to compact 6502 assembly, without the need of inline assembly by the programmer.

 

1 hour ago, Kaj de Vos said:

I think there are a few small operating systems written in Rust, so that is true, although they include assembly. Actually, Meta already is an OS. What I didn't mention is that the compile.ape I released can also run as a boot sector on a bare metal PC. That is not a very useful mode to run the remote compiler in, but your own Meta programs will be able to use it when I release that.

That sounds cool! Bootstrap assembly is no problem IMHO, and once the application is running, it should be relatively easy to do things like peeking or poking a hardware register.

Share this post


Link to post
Share on other sites
19 minutes ago, ivop said:

Sorry, should have said Atari examples.

Still nope. I started every example with a pure Meta version. Then for the hardware programming examples, I continued with versions in mixed Meta/assembly and in pure assembly, just to show what the integrated assembler can do and how the generated Meta code compares to it.

 

21 minutes ago, ivop said:

Does that run on an 8-bit Atari?

Why not? I posted this Fibonacci example on AtariAge and proceeded to give an optimised version for Atari 8-bit.

 

27 minutes ago, ivop said:

Partly true. But if every company had its own kind of English, and you have to know the quirks and how something could mean something completely different than what you are accustomed to from a previous company, that's pretty hard to work with IMHO. Consider operator overloading in C++. It's a mess. You can never be sure what a+b means at a first reading of the code.

a+b is easy in Meta and REBOL: it's one word. 😄 Now for [a + b], you can never know what it means. But the same goes for a+b: you don't know what value it has, or if it is even bound to a value. Until you ask it. Same as in other languages. And you can also ask [a + b] what it means. Or you can tell it what it means, if you want something else. It's context-dependent. Same basic principle as in other languages. Including English. If somebody invites you into the living room and tells you to sit on the chair, you're not expected to go to the kitchen to sit on the chair there. They're both equally chairs, but the living room is the context that defines what chair means there. And if the maid tells you to sit on the chair, you wouldn't go from the kitchen to the living room to sit with the lord. It can get you in trouble, but it doesn't happen.

 

Now you can get in trouble when languages manage their contexts badly. REBOL and Meta are designed to do a better job.

 

Most programs use data structures. You don't know what they mean until you have studied the program. A data structure in Meta is by definition a Meta dialect. Every program using its own data structures is like your example of every company using a different variety of English. Yet this is what seems necessary to write effective programs. Programming is hard. What Meta does, is to make all the different forms programmers need as similar as possible.

 

That's what you do to communicate: you establish conventions about what sound means what. Dutch people usually understand each other's sounds. Frisian people usually understand each other's sounds. Frisian people understand Dutch sounds, yet Dutch people don't understand Frisian sounds. It's all a matter of contexts and effort.

 

59 minutes ago, ivop said:

That sounds cool! Bootstrap assembly is no problem IMHO, and once the application is running, it should be relatively easy to do things like peeking or poking a hardware register.

That's basically what Meta also does on Atari 2600. There is no operating system there, so it has no choice but to run as its own operating system. On "bare metal" PC, there is still a BIOS, which is actually the same situation as on Atari 8-bit.

Share this post


Link to post
Share on other sites

Long story short, perhaps a better question is: what are the primitives of your Meta language? That is what people (me included) want to know.

 

Then have some downloadable examples from your website. Source and executable for each target. After that, perhaps a compiler that is not a binary blob ;)

 

 

 

Edited by ivop

Share this post


Link to post
Share on other sites
17 hours ago, Kaj de Vos said:

Hint: there are no reserved words. 😎

1. if there are no reserved words what are "let", "either", "loop" in the Fibonacci example? 

2. Language seems to be similar in concept to Lisp. I find the Common Lisp style macros very useful as macro system in a language (used in many including I think Rust, Julia, Scala) but don't you think this is a dead-end for mainstream programming? One of the reasons why Lisp failed was lack of "standardization" of the language and it ended with ton of dialects that nobody could understand. Basically you had to learn a new programming language for each project and you couldn't easily use concept of shared libraries, where each word could have different meaning in each library.

Edited by ilmenit

Share this post


Link to post
Share on other sites

Good questions. Full answers could fill a book.

 

7 hours ago, ilmenit said:

1. if there are no reserved words what are "let", "either", "loop" in the Fibonacci example?

They are words that are bound to built-in methods. They are predefined, but not reserved, so they can be bound to other values, including non-methods. This actually makes it easier to know what a word means, because your own definition is leading. You don't have to know all the words in the language to prevent conflicts, and when the language adds a word, it doesn't conflict with your previous uses, because your existing programs rebind the predefined word.

 

Yes, Meta is mostly inspired by REBOL, and REBOL is mostly inspired by Lisp. I think Lisp is arguably the most successful of the early language designs. Indeed, it didn't become mainstream in the dialect of Lisp itself, but as you say, its principles permeate many other languages and other software systems. And while the other early languages have died out, Lisp itself is still a strong language segment. Its dialects have evolved over those sixty years, but English has also changed quite considerably over that time, and I think it's only fair for a newborn computer language style.

 

Why Lisp is not mainstream in its own dialect is a difficult topic. Part of it is the superficial dialect, because many of the underlying principles did become mainstream. Mainstream programmers don't grasp the full extent of Lisp. You could view Meta as offering a more human-friendly variety of the Lisp dialect. However, REBOL has important innovations over Lisp, the most fundamental of which is that Lisp binds contexts per list (which REBOL and Meta call a block), while REBOL binds contexts per single word. One consequence of this is that REBOL doesn't need macros, because its code generation can do anything that Lisp macros can do. Lispers don't grasp this, so there is a hierarchy of non-understanding here.

 

REBOL doesn't have a particular problem with sharing libraries. In general, you don't need many, because so much functionality is contained in REBOL itself. But beyond that, there is an ecosystem of people providing code in some library form, that becomes popular to use by others. Perhaps library code redefines words, but that is only of concern within the library. Remember, it's all about contexts. A library should be a context that manages itself. What's important is the interface. A library could provide extra functions for the standard "do" dialect, which must be assigned to words, but ideally, a more complex library defines a specialised dialect that outside code can use. Dialects are very strong and flexible interface definitions, so you can make interfaces exactly how you need them.

Share this post


Link to post
Share on other sites

I still don't see how to use this, there's no documentation describing how to use it, the program/utility itself,

only 2 downloads of dependant programs, all the links you supply go to the same page which really tells

us nothing about how to see real examples, how to use etc. etc.

Share this post


Link to post
Share on other sites

Please have patience and stay tuned to watch your wishes come true.

 

I plastered the website and this forum full with notifications that the work is not finished yet, and in what order you can expect it. I don't know what else to say, except that in the future, you will be able to crowdfund your wishes.

Share this post


Link to post
Share on other sites

Kaj, don't get angry on people here, but I also think the new language would benefit greatly from:

  • examples - programmers of other languages understand much quicker language concepts on actual code that is solving some known problems. The example should compile so person trying it could play with it.
  • compiler that can be used locally - at least for me it's a very poor workflow when to compile even "hello world" I need to send it to Internet. 
  • source code of the language itself e.g. on GitHub - for transparency what's behind it
  • Like 2

Share this post


Link to post
Share on other sites

Kaj -

I think a good project would be to do the benchmark suite as found in, for instance, the MAD Pascal thread, and show results and source codes. That would kill 2 objectives with 1 effort. If you want to get real traction for your language here that would be a step towards it. I would not expect someone else to take that on...you never know but when you get things finished to your liking I think that would be a logical next step. We are not as interested in the niceties of language constructs and flexibility as we would be in actual performance and accompanying source.

Share this post


Link to post
Share on other sites

Sure, but what's so hard to understand about that work takes time? If you know a secret incantation with which I can snap my fingers to finish it all at once, I'm all ears.

 

I have worked double-time for a year and a half to offer what is here now. I made it work, so I offered it to you all. Surely not everyone will be able to use it right away, that's why I put in all the caveats, and drew up a road map. It's not an option to wait until it's usable for everyone, because that day would never come. It would take decades, and during that time I would have no feedback, so it would go in wrong directions. For one thing, it's quite a surprise to me that, apparently, most people here need much more hand-holding than I expected.

 

The fact that Meta works as a remote client to a build server is exactly to facilitate easier use and quick improvements. Installing it locally would be too hard for all but a handful of people. Heck, even just using the minimal client already turns out to be too hard. I make improvements to Meta almost every day. On the build server, I can deploy them without people even noticing. Installed locally, you would have to reinstall every few days. A form of Meta that can be installed locally is in the road map, but it's years away.

 

There are a few ways out of this. Implementing all your wishes right now is not one of them.

 

I could just roll up the project and leave, and just use it for myself. That's a realistic option. The Boron REBOL descendant operates that way. It would save me a lot of time and make Meta even more valuable to myself. But I don't want to go that route. I wish to share my work with whoever wants it.

 

I have dealt with this problem before. It's not your fault, it seems to be an issue with humans in general. The solution I have devised is the planned crowd-funding system. Instead of being vocal, people will be able to fund their wishes, and I will execute them fairly strictly in the order of funding. The problem is that I decided to release Meta before the crowd-funding. Perhaps that was a mistake, because the issue I expected is right here, right away. It's too late now. We will see how this continues. If people are too unhappy, I may go silent until I have implemented the crowd-funding.

Share this post


Link to post
Share on other sites
4 minutes ago, danwinslow said:

Kaj -

I think a good project would be to do the benchmark suite as found in, for instance, the MAD Pascal thread, and show results and source codes. That would kill 2 objectives with 1 effort. If you want to get real traction for your language here that would be a step towards it. I would not expect someone else to take that on...you never know but when you get things finished to your liking I think that would be a logical next step. We are not as interested in the niceties of language constructs and flexibility as we would be in actual performance and accompanying source.

Dan, I agree, I have a preliminary Sieve of Eratosthenes benchmark. But it takes a lot of work to make new examples, because they always push new language features to be implemented and optimised. So it's on the shelf to be finished.

Share this post


Link to post
Share on other sites
16 minutes ago, Kaj de Vos said:

We will see how this continues. If people are too unhappy, I may go silent until I have implemented the crowd-funding.

I'm not unhappy :) (well, at least not because of you ;) ). Sorry if I came across a little harsh yesterday. Bad day. Not your fault.

  • Like 3

Share this post


Link to post
Share on other sites
Quote

Meta remote cross-compiler for Atari 8-bit


* compile.ape Windows, Apple Mac, Linux, FreeBSD, NetBSD, OpenBSD

This is a command-line program that takes a Meta program text and produces a binary Atari 8-bit program. So far, it has only been tested on Linux. We are interested in reports of success or failure.

 

 

I tried it on an AMD64 PC running FreeBSD 10.1. The result: illegal system call (core dumped).

Edited by drac030
  • Thanks 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...