Skip to content

ajlopez/DartSharp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 

Repository files navigation

DartSharp

Dart-like programming language, implemented as interpreter using C#, with access .NET types and objects. After completing the interpreter, maybe I could compile to C# code (or IL?).

Work in Progress.

Examples

The interpreter is under development. You can use if, while, declare functions and variables. You can start the interactive interpreter with command

dartsharp

It is the .exe produced by the compilation of DartSharp.Console project.

Hello world

print("Hello, world");

Fibonacci example:

int fib(int  n) {
  if (n < 2) return n;
  return fib(n - 1) + fib(n - 2);
}

main() {
  print(fib(20));
}

Access to native methods

var a = "foo";
print(a.Length);
3
print(a.Substring(1));
oo
print(a.ToUpper());
FOO

About

Dart Programming Language Interpreter and Compiler (to C#). It can access .NET libraries

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages