Skip to content

toString override on Structs #33

Description

@miberss

Suggestion Description

struct path:
    const real: object
    const path: string
    converts to:
        string via this->path

struct value:
    const min: number
    const max: number

on load:
   broadcast value struct instance:
     min: 0
     max: 1
   # should broadcast `value of (min: 0, max: 0)`
   
   set {_path} to "hi"
   broadcast path struct instance:
     real: Path.of({_path})
     path: {_path}
   # should broadcast `hi`

Easier way to define string representation without string within %struct% for converts to, aswell as a better default.

Screenshots

No response

Other

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions