Programmers: please, implement a programming language so easy like #python over a safe programming language like #rust or #zig It could reduce wasting time for end users or basic skills programmers like me ;) Why we don't separate syntax and semantics of programming language: pick a syntax you want (ruby, c, haskell, etc.), translate to programming language you want (rust, c, etc.). With this programming language wars are over and we can compare solutions even if we program in different language

Follow

@somenxavier there have been many attempts of this over the years. Most have failed as the semantics of one language inevitable clash with the ones of others. As an example, consider immutable borrow of variables in rust (immutable by default) or lazy code in Haskell. How would such things be expressed in Python? You'd need to make new syntax to express those ideas in Python thus it stops being "vanilla" Python. As the number of features increases to match those of these other languages so would the syntactic differences.

Your best bet would be something like Cython or Nim. In the case of Nim, it can be compiled to C, C++, Objective-C and JavaScript while Nim itself is heavily inspired by Python.

nim-lang.org/docs/backends.htm

Sign in to participate in the conversation
Qoto Mastodon

QOTO: Question Others to Teach Ourselves
An inclusive, Academic Freedom, instance
All cultures welcome.
Hate speech and harassment strictly forbidden.