Skip to content

InspiredImpact/petuhlang

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Non-English documentaion

Russian | Русский

SOON (PRE-ALPHA)

What is petuhlang?

Petuhlang is a joke-like language, based on Python. It updates builtins to make a new syntax based on operators rewrite.

Classes

from petuhlang import build
build.using >> "petuhlang"


class PythonClass:
    def foo(self) -> None:
        print("bar")


pyclass >> MyClass(extends=PythonClass)


function >> main(
    arg("user") >> str,
    kwarg("greeting", value="Hello") >> str,
) [
    MyClass.createInstance(bindTo="instance") >> then [
        console.log(f"It works:) -> {instance.__class__.__name__}")
    ]
]

main()

Base functions

from petuhlang import build
build.using >> "petuhlang"


function >> main() [
    retrieve >> (1 + 1)
]

console.log(main())

Releases

No releases published

Packages

No packages published

Languages