mdg / leema Goto Github PK
View Code? Open in Web Editor NEWA functional programming language designed for concurrency and failure
Home Page: http://leema.org
License: Apache License 2.0
A functional programming language designed for concurrency and failure
Home Page: http://leema.org
License: Apache License 2.0
enums don't work right now. partly they're in stasis until generics can be worked out for structs. but once that's done, enums should be restored.
Leema needs a bigint type for doing fun math stuff with big numbers
Rug seems like the most likely, partly b/c it's build on old gnu stuff. The other alternative might be rust-num/big-in which appears to be entirely in Rust.
If a generic function is defined to do something, allow a version to be defined that overrides that specific type. C++ does this, have it be something like that.
func foo[T](a: T): T >>
<whatever>...
--
func foo[Int](a: Int): Int >>
<something else>
--
Need to be able to make and return closures.
These will be also be used in asynchronous forks.
Still need to work out some of the syntax. Maybe something like:
func make_inc(): Int => Int ->
fn(x) -> x + 1 --
--
or in the alternative model described in #16
func make_inc: Int -> Int
>>
fn(x) >> x + 1 --
--
func make_inc_short: Int -> Int
>>
fn(x) x + 1
--
Leema needs a primitive Map data type built in Rust as a persistent data type.
It should have typechecking and pattern matching too.
cout
is good for people who know C++ but is confusing for people who don't. rename it to just be print
Add interfaces that define functions.
Allow the interfaces to be implemented for specific datatypes.
Allow function parameters and struct fields to be specified as the interface type.
Need to work out the syntax for all of this still. Probably go w/ interface
keyword to define them.
lists cannot be sorted right now. that's no good. need to add a function that can sort lists.
add a list::sort()
function in src/leema/list.rs
and then add a leema wrapper for it in src/leema/prefab.rs
and add the declaration in T/prefab.lma
also include a test for it in T/test_list.lma
or something.
leema needs a memcache client. Using an existing Rust library is fine as long as it's using async I/O and doesn't block the main process.
Leema is meant to be useful as a web language. Won't be very successful at that without an HTTP server library.
I tried integrating hyper already but it's designed to only do stuff in callbacks. It's really hard to read the request and send a response separately.
Domain types (in leema) are type aliases that can only be aliased in one direction. They are to be used when constraining the values of a type to a particular, domain-specific subset of the values otherwise allowed by the type.
For example, imagine a domain type for a zip code that is aliased to a string. Once you create a zip code, you can pass it to a function that takes a string. But if you have a function that takes a zip code, you cannot pass it a string without first explicitly converting it to a zip code type.
This might function similarly to an implicit cast operator in C++.
https://en.cppreference.com/w/cpp/language/cast_operator
leema needs an http client library for calling to APIs and web services and whatnot.
and to run an http client server test.
probably easiest to use the hyper client library.
leema should have a json library for encoding and decoding json
a match block w/ no match panics.
expected: it should give some kind of failure, not completely crash w/ a rust panic.
currently there's no way to pass info from the command line to a leema program.
This should be possible!
Maybe just add an optional args: [Str]
parameter to main
Let's get it down to 0 and then make it part of the tests to report warnings as errors
The current formatting is pretty inconsistent. Switch it to use whatever cargo fmt
does.
Leema needs a way to execute things concurrently.
seems like adding closures #19 might be easier if I add currying first and use that to implement closures.
still need to work out the syntax.
Make the Rust Regex library available in leema:
https://docs.rs/regex/1.0.2/regex/struct.Regex.html
even when it's not doing anything, leema still pegs the CPU. it should pause more and hang out if it's not doing work.
the current plan is if there's nothing to do for 2 or more consecutive iterations, then sleep for a bit before trying again.
need to restore the integration test for fail_nonlinear.lma
When compiling and typechecking, a block of scope can be pushed onto the stack. But the programmer has to remember to pop it off when done. These scopes should be automatically popped using the Drop trait.
Lines 389 to 392 in 2f4e240
Right now leema can only find library code in one directory. This causes problems when doing things like running unit tests.
Expected: it should allow searching code in multiple directories.
Hook up the clippy linter to the build chain. Fix all the errors then make it fail the CI build.
run clippy with cargo +nightly clippy
Sometimes we want to be explicit the type of a particular variable. Currently there's no way to do this.
Expected: This should be possbile. Probably best to just use the Rust syntax for it with a colon and the type after the let's LHS. Like...
let empty: [Int] := []
Users need to be able to assign to a structure's fields.
Probably do this in an immutable data structure way
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.