Giter VIP home page Giter VIP logo

chorer's Introduction

ChorEr

ChorEr is a static analyzer to generate Choreography Automata from Erlang source code.

Requirements

The project requires erlang and rebar3 to run.

Usage

Use rebar3 to run the program from the command line or to compile it.

# rebar3 escriptize
# ./_build/default/bin/chorer ./path/to/your/program.erl main/0 path/to/folder

or

# rebar3 shell
1> chorer:generate("./examples/ticktack/tictacstop.erl", "start/0").
finished

Output

The tool will create a DOT file for each actor's local view and a DOT file for the global view in the specified folder. To visualize the Choreography Automatas copy and paste the .dot files' content in a DOT viewer.

Documentation

The documentation of the project is aviable at this link. You can also generete it with

# rebar3 ex_doc --output docs

Test

Try out the tool using the ./test.py script.

Supported expression

Expression Support
atom ✅ yes
integer ✅ yes
float ✅ yes
boolean ✅ yes
tuple ✅ yes
list 🟡 partial
string 🟡 partial
record ❌ no
map ❌ no
binary ❌ no
if ✅ yes
case ✅ yes
receive ✅ yes
send ✅ yes
spawn ✅ yes
spawn_monitor ❌ no
match 🟡 partial
function ✅ yes
guards ❌ no
register 🟡 static eval
unregister ❌ no
whereis ❌ no
rand:uniform ✅ yes
self ✅ yes
anon functions ✅ yes
try catch ❌ no
after ❌ no
math operation ❌ no

Credits

This project was made for the Bachelor's degree Thesis of the Computer Science course at Alma Mater Studiorum - University of Bologna. I am grateful to the professor Ivan Lanese, who supervised the development of this project.

chorer's People

Contributors

gabrielegenovese avatar german-vidal avatar lanese avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

chorer's Issues

Set final state for a global view

Add a function to determinate the final state of a global view. In my opinion, a state in a globalview is final iff all the actors (local views) are in a final state and there are no dangling messages.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.