
Ask HN: What do want to see in programming language? - mubaris
I&#x27;m developing a new Programming Language. And I want it to be different.<p>If a promising langauge is out there, What do you wanna see in it?
======
andreasgonewild
I would like a C++ without the spider webs. Not different, we have plenty of
different languages out there; I have no interest in debugging other peoples
fancy ideas. I just want a powerful language that lets me say what I mean
without keeping 30 years of accumulated exceptions in mind.

~~~
Doxin
You should try D. It's pretty much C with some weirdness fixed and OOP added
on. Do mind that it's not a weak language, D has some very simple but
extremely powerful features that plain C doesn't have, or that C++ has in a
too complex way.

~~~
andreasgonewild
I've kept an eye on D over the years, but that's still too much magic for me.
What C++ (and Lisp) gets right is providing user code with the same powers as
the compiler. I realize that getting there is what turned them into complex
beasts, but plenty could be left behind should one decide to make a clean cut.
The problem from my perspective is that we're working both ends of the
spectrum, backwards compatibility and fancy new ideas; but no energy is spent
on cleaning up and refining what's already there.

~~~
Doxin
> What C++ (and Lisp) gets right is providing user code with the same powers
> as the compiler.

So what part of that isn't fulfilled by compile time function evaluation and
mixins and it's extensive introspection features? I feel like maybe you
haven't looked at D quite hard enough to see why it's awesome.

------
borplk
I doubt this is what you were looking for, but I want to see a programming
language that is not text based.

For the past decades no one has been disrupting programming at a fundamental
level.

We are stuck with a "program must be a bunch of ascii files edited with text
editors" mindset that no one dares to challenge.

The collective of programmers suffer from an extreme case of the Stockholm
syndrome.

If you are not familiar go learn about "Intentional Programming".

I recently wrote some relevant comments about it.

Here:
[https://news.ycombinator.com/item?id=14384269](https://news.ycombinator.com/item?id=14384269)

And here:
[https://news.ycombinator.com/item?id=14278605](https://news.ycombinator.com/item?id=14278605)

Current programming languages mean we share an ASCII language with the
compilers. This creates a fundamental tension and conflict of interest between
humans and computers.

It creates all sorts of artificial problems that we have spent so much time
trying to fix.

If you are interested checkout Charles Simonyi's work and talks on Youtube as
well.

~~~
LolisaKirisame
Language Server Protocol, Smalltalk, Unison, Lambdu, Etc... There are also
some similar work.

~~~
borplk
Isomorf is the closest thing I have seen to what I was talking about.

[https://isomorf.io/#!/demos](https://isomorf.io/#!/demos)

If you are interested search for "Intentional Programming".

------
S4M
In Python, I'd love to add something like const in a function definition, for
the arguments, to say that the arguments will not be modified by the function.
For example, I would want the following code to somehow return an error

    
    
        def get_last_element(const my_list):
            return mylist.pop()

~~~
rdnetto
You can do that in Python by converting the list to a tuple before passing it
in. The need for a defensive copy is unavoidable as long as you're using
mutable data types though.

------
dkersten
A statically typed, native-compiled clojure. That is, a statically typed,
native-compiled lisp with a focus on functional programming, immutable data-
structures by default, the sequence abstraction and other clojure-isms
(protocls, transducers, core.async)

------
7373737373
A language that supports both

\- the serialization of running tasks:
[http://stackless.readthedocs.io/en/2.7-slp/library/stackless...](http://stackless.readthedocs.io/en/2.7-slp/library/stackless/pickling.html)

\- sandboxing and resource control of computations within the same process

This combination doesn't seem to exist yet.

------
drallison
Programming languages are exceptionally difficult to design. Most "new"
programming languages end up looking a lot like the "old" programming
languages but with a slightly different set of warts.

Programming language design is distinctly different from programming language
implementation and distinctly different from program optimization. A
programming language designer need to have experience and skills in
implementation and in optimization. Optimization is important because it
assists in understanding the underlying concepts that need to be supported by
a programming language.

Brian Kernighan, Jon Bentley, and others have long advocated for designing and
implementing little languages, small domain-specific languages to solve a
limited class of problems using "natural" abstractions, operations, and data.
The Unix pic language is a classic example. Read the literature about "little
languages"; Google is your friend. See, for example,
[http://broadcast.oreilly.com/2009/04/an-interview-with-
brian...](http://broadcast.oreilly.com/2009/04/an-interview-with-brian-
kernig.html) to learn about little languages.

What I would like to see is for you to learn about programming languages and
their implementation before you rush off to design one. You might design,
implement, and use a little language for a class of problems you encounter in
a domain in which you work regularly. Use it to improve your productivity.
Share the language with others who have the same problems to solve. Get their
suggestions and feedback and incorporate them into your language system and
repeat. That is likely to give you joy.

Designing a programming language is just the beginning. If your language is to
have legs, you need to ensure that there are readily available implementations
with libraries and operating system support for your language. You need to
write papers and manuals and promote your language actively. And you need to
be patient since adoption of a new programming language takes decades. And you
need to be aware that language choices are often fickle.

If your goal is to eventually devise a new general purpose programming
language, you need to program a lot of different problems in a multiplicity of
languages and styles in order to understand what languages need. Asking HN is
likely to be a sub-optimal strategy because most folks who read HN tend to
conceive their problems and programs in terms of mechanisms and abstractions
in existing languages.

You might want to look at the evolution of particular programming languages
and the conceptual problem solution frameworks they express. Do this for
several different language styles: procedural, functional, distributed actors.
For example, I think the evolution of Python (including Lua and Ruby)
contrasted with Perl would be quite educational.

Also, I would be cautious about trying to be different for the sole purpose of
being different. Our current programming languages encapsulate years of
experience and scar tissue which needs to be retained.

------
dozzie
A specific purpose. What are you aiming with your programming language at?
Only to be different?

~~~
mubaris
I aim to achieve a language which is easier to read. And I don't aim to lose
the speed of a powerful language.

~~~
dozzie
Then you set up yourself for a failure. Another Python or Ada, except much
younger and with no libraries and probably no way to interact with anything
already written, most likely won't gain any traction. Especially that the goal
you've stated ("easier to read") is very vague.

------
AlexAMEEE
I'd like a programming language that kicks the programmer in the nuts if he
over engineers things and writes unreadable code.

------
tmaly
I would like to see an expressive language like Ruby or Perl 6 that runs as
fast as C and compiles very fast.

------
mabynogy
A way to mutate the code at runtime depending of the context (the stack
frame...).

------
bbcbasic
Why not create a DSL for a particular niche you are interested in.

Look at any Java enterprise app and there will be a lot of WET cruft calling
out for a DSL.

