Changed around line 1
+ ../code/conceptPage.scroll
+
+ id Star-lang
+ name Star
+ appeared 2014
+ creators Francis McCabe
+ tags pl
+ website https://github.com/fgmccabe/star
+ description
+ writtenIn C, Prolog, Star
+
+ example
+
+ gitRepo https://github.com/fgmccabe/star
+
+ Star is a language originally focused on processing realtime events. However, it is a general purpose 'function forward' language.
+
+ It's type system is based on an extension of Hindley-Milner with type constraints. This allows for well defined overloading and other language features such as dynamic scoping.
+
+ Star has a fairly rich set of features, including built-in querying, built-in grammar notation, coroutining, and structured concurrency.
+
+ test.q0{
+ import star.
+ import star.assert.
+
+ -- Some simple query expressions
+
+ parent:cons[(string,string)].
+ parent = [("a","ab"),("b","ab"),("a","c"),("c","aa"),("ab","abc"),
+ ("de","abc"),("d","de"),("e","de"),
+ ("f","a"),("g","f")].
+
+ gp : cons[(string,string)].
+ gp = { (X,Y) | (X,Z) in parent && (Z,Y) in parent}.
+
+ pp : cons[string].
+ pp = {X | (X,"ab") in parent || (X,D) in parent && "de".=D}.
+
+ -- A different example, filtering positive numbers
+ someInts : cons[integer].
+ someInts = [0,2,-1,-10,4,6,7,-3].
+
+ pos : cons[integer].
+ pos = { X | X in someInts && X>0 }.
+
+ main:() => ().
+ main() => valof{
+ show parent;
+
+ assert size(parent)==10;
+
+ show gp;
+
+ show pp;
+
+ show pos;
+
+ -- add up all the positive integers in someInts
+ show { (+) <* X <* 0 | X in someInts && X>0 };
+
+ valis ()
+ }
+ }