Skip to content
forked from matz/streem

prototype of stream based programming language

License

Notifications You must be signed in to change notification settings

streem-lang/streem

This branch is 893 commits behind matz/streem:master.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

75e39b5 · Dec 28, 2014

History

93 Commits
Dec 21, 2014
Dec 26, 2014
Dec 20, 2014
Dec 15, 2014
Dec 20, 2014
Dec 11, 2014
Dec 11, 2014
Dec 26, 2014
Dec 27, 2014

Repository files navigation

Streem

Build Status ![Gitter](https://badges.gitter.im/Join Chat.svg)

Streem is a stream based concurrent scripting language. It is based on a programming model similar to the shell, with influences from Ruby, Erlang, and other functional programming languages.

Note: Streem is still in the design stage. It's not working yet. Stay tuned.

Examples

In Streem, a simple cat program looks like this:

STDIN | STDOUT

Streem is a (sort of) DSL for data flows. Above code means building data-flow connection between STDIN and STDOUT. Actual data processing will be done in the event loop invoked after program execution.

For another example, a simple FizzBuzz will look like this:

seq(100) | {|x|
  if x % 15 == 0 {
    "FizzBuzz"
  }
  else if x % 3 == 0 {
    "Fizz"
  }
  else if x % 5 == 0 {
    "Buzz"
  }
  else {
    x
  }
} | STDOUT

The second part in the pipeline ({|x|...}) is a function object. If a function object is connected in the pipeline, it will be invoked for each elements in the stream.

Compiling

Install dependencies

  • bison
  • flex
  • gcc / clang

Run make

make

Please note that Streem will not run any scripts yet, but you can check parse files and check syntax.

Contributing

Send a pull request to http://github.com/matz/streem. We consider you have granted non-exclusive right to your contributed code under MIT license. Use http://github.com/matz/streem/issues for discussion.

License

MIT license (© 2015 Yukihiro Matsumoto)

About

prototype of stream based programming language

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Bison 81.2%
  • Makefile 9.8%
  • Ruby 6.9%
  • Shell 2.1%