GithubHelp home page GithubHelp logo

thesecondcoming123 / unlab Goto Github PK

View Code? Open in Web Editor NEW
8.0 1.0 4.0 12.38 MB

The unlab golfing language

License: MIT License

Python 99.43% Tcl 0.51% PowerShell 0.03% Batchfile 0.03%
language python-3-10 golfing-language prefix-notation programming-language

unlab's Introduction

TheSecondComing123's GitHub stats

unlab's People

Contributors

kokonut27 avatar lyxal avatar mathcat4 avatar thesecondcoming123 avatar zoomlogo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

unlab's Issues

Change CLI -> File run

I think adding a command line might be a good idea, but maybe make it rather instead so you can actually download the language, and use it like other Programming Languages. In my language, I use the module click to allow file running - like other languages. Check out line 42 and line 43.

Addition, subtraction, multiplication and division do not work.

>>> +1 1
Traceback (most recent call last):
  File "main.py", line 47, in <module>
    cli()
  File "main.py", line 31, in cli
    shell()
  File "main.py", line 43, in shell
    print(main(code))
  File "main.py", line 16, in main
    output = run(code, ctx=ctx)
  File "interpreter.py", line 55, in run
    return Interprete().main(parse(unpack(structure(tokenize(text)))), ctx)
  File "interpreter.py", line 19, in main
    main_output = self.interprete(tokens, ctx)
  File "interpreter.py", line 47, in interprete
    output = func(*list(args))
  File "functions.py", line 39, in Add
    if typecheck(args=[a, b], types=[Rational, Rational]):
  File "helper.py", line 43, in typecheck
    raise TypeError(f"Did you mean: [{args}]?") from None
TypeError: Did you mean: [[1, 1]]?

The error can be in the typecheck function, the functions in functions.py, Rational limitations, line 47 of interperator.py, and line 23 of parse.py.

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.