Git Product home page Git Product logo

Comments (2)

monkeybutter avatar monkeybutter commented on July 22, 2024

I've done a test changing a couple of structs. Basically when the struct contains a lock for itself lock is declared as anonymous field. When the struct contains an field that is lockable that field is declared as a lockable struct outside and embedded in the first one.

An example can be seen at:

https://github.com/monkeybutter/glow/commit/caa111b8ce1fb837917f4b1fcd9c49450167c52d

I haven't tested the code and I don't know how these changes would affect other functions using these structs outside the files where they've been declared. This is only an example to ask for feedback about the proposal.

from glow.

chrislusf avatar chrislusf commented on July 22, 2024

Nice to learn this technique!

You can test by running the examples in both standalone mode and
distributed mode.

Chris

On Wednesday, October 28, 2015, Pablo Rozas-Larraondo <
[email protected]> wrote:

I've done a test changing a couple of structs. Basically when the struct
contains a lock for itself lock is declared as anonymous field. When the
struct contains an field that is lockable that field is declared as a
lockable struct outside and embedded in the first one.

An example can be seen at:

monkeybutter@caa111b
https://github.com/monkeybutter/glow/commit/caa111b8ce1fb837917f4b1fcd9c49450167c52d

I haven't tested the code and I don't know how these changes would affect
other functions using these structs outside the files where they've been
declared. This is only an example to ask for feedback about the proposal.


Reply to this email directly or view it on GitHub
#7 (comment).

from glow.

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.