Code Monkey home page Code Monkey logo

Comments (6)

mrkmarron avatar mrkmarron commented on May 19, 2024 1

This will be left up to the host runtime (like JavaScript does not provide its own event loop or IO facilities). For the host I am very interested in some of the state-machine designs (the P langauge) but this is an open issue for experimentation.

from bosquelanguage.

Andersmholmgren avatar Andersmholmgren commented on May 19, 2024 1

ES 8 has async / await as keywords though right?

Do you foresee no need for any language level support in Bosque?

from bosquelanguage.

mrkmarron avatar mrkmarron commented on May 19, 2024 1

There are the async/await keywords but (to the best of my knowledge) the implementations use the host provided microtask queues.

As part of research mindset in this project I would like to see how far we can go without adding any lanugage support for environmental interaction but this is definitely an open question.

from bosquelanguage.

Andersmholmgren avatar Andersmholmgren commented on May 19, 2024 1

Given how pervasive IO is in modern development (web, cloud ...) I do think it is worth considering how it will fit. From experience dealing with Promises etc is a potential area of bugs & flakiness.

FWIW, I must admit when I first saw the pipeline syntax my first thought was that it was for asynchronous streams till I read it a second time.

from bosquelanguage.

wanton7 avatar wanton7 commented on May 19, 2024

@Andersmholmgren there is always green threads instead of async await keywords & similar. Google's Go language runtime as example uses green threading. Project Loom for Java that tries to implement green threading for JVM.
I'm C# developer by profession but I find Go's green threads much cleaner and simpler from programmers perspective compared to poluting your code with async and await keywords.

There is also Erlang's VM called BEAM that uses actor model and preemptive multitasking for building highly concurrent systems where every actor runs in separate lightweight "process" handled by BEAM.

from bosquelanguage.

wanton7 avatar wanton7 commented on May 19, 2024

Maybe of interest. Golang is switching to non-cooperative preemption golang/go#24543

from bosquelanguage.

Related Issues (20)

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.