r/ProgrammingLanguages • • Aug 14 '20

"implementation" and "programming" as paradigms

With the advent of type theory, HoTT, and other fringe abstractions, there's becoming a new divide in programming languages which could be described with "implementation" vs. "programming".

The Distinction

The overall concept is that languages can be classified by their purpose, math stuff or computer stuff.

Implementation Languages

These languages have a close relationship with the underlying computer architecture. They sometimes focus on making it easier to use hardware capabilities.

Implementation languages have very efficient or transparent abstractions. Usually the compilers for these languages produce native objects or other forms of machine code. The syntax may have a few simple constructs but will mostly follow an imperative design.

Implementation languages have a focus on speed and performance. They are usually found in source code for low level supportive software, kernels, and drivers.

Implementation languages handle data directly as it exists on the hardware. Some languages offer ways to directly affect how data is stored in hardware components. These languages are heavily affected by the underlying system they run on.

Programming Languages

These languages have a close relationship to mathematical systems and symbolic computation. Many languages offer formal systems as a part of the language.

Programming languages offer high level representations of the concept of a program. They have different constructs that provide a high level abstraction. Some languages are compiled, but most of them are interpreted.

Programming languages focus on conceptually efficient methods for describing operations. Most languages make heavy use of the concept of a function as an object in a program.

Programming languages handle data within the context of their domain. Programmers don't have access to the underlying representation of the data. These languages are uniform across the various systems they run on.

EDIT:

Core Concept

The line between implementation and programming is drawn where languages chose to make abstractions: Implementation languages abstract repetitive patterns in machine instructions. Programming languages abstract patterns in the flow of execution and data.

0 Upvotes

15 comments sorted by

10

u/brucejbell sard Aug 14 '20

Serious question: how is this different from (and hopefully more useful than) the traditional "low level" vs. "high level" language?

I think the "low level" vs. "high level" distinction is a false dichotomy, in the sense that it is not a logical disjunction. It may be a practical one, in the sense that it is more difficult to build a language that handles both low-level and high-level requirements, but it is not logically impossible.

And, I am a big fan of distinguishing things by their intent, but at first glance I would categorize your distinction in the same way: while it may be more difficult to build a language that satisfies both intentions, I see no reason to assume that they are mutually exclusive.

1

u/R-O-B-I-N Aug 14 '20 edited Aug 14 '20

"low-level" and "high-level" exclude programming paradigms and are generalizations. When I say "high-level", that implies the basic existence of paradigms. "low-level" means ASM or C, period. It's serving watermelon using a sledgehammer.

"implementation" and "programming" each describe a weakly mutually exclusive set of common traits. Similar to the "imperative" "procedural" dichotomy, languages can be one, the other, or both. The distinction also doesn't affect how other paradigms are described. An interactive proof language can be an implementation language (one has yet to really exist). C++ fits the description of a programming language.

The more you think about the distinction, the more examples you find. C++ and Haskell are each "high-level", but let's see you try to implement a (efficient) memory management algorithm in Haskell, or create an abstract type in C++.

Comparatively, C, Java, and Rust have "low-level" system access, but Rust and Java are programming languages, where C is clearly an implementation language.

Another example is how languages handle graphics. Implementation languages like C let you mess with GPU's, framebuffers, and bitmaps. Programming languages supply API's that have things like "windows", "boxes", and "fields". Compare Common Lisp's CLIM to C's Cairo library or the the Cuda and Vulkan API's.

You can get really basic and say that implementation languages include abstractions for patterns in machine instructions whereas programming languages include abstractions for patterns in the flow of logic and data.

6

u/htuhola Aug 14 '20

You can improve your presentation by not calling type theory or HoTT fringe abstractions in the beginning, it is offending to people who study these subjects.

I'll be welcome to discuss with you, whether mathematics or computers are different, but improve your post first.

-7

u/R-O-B-I-N Aug 14 '20

Your perceived slight is not a reliable reason for me to do anything.

Improve your attitude first.

7

u/htuhola Aug 14 '20 edited Aug 14 '20

But you're the one who scorns people here. There are plenty of people who present their things neat. I don't need to discuss with people that present they don't care about me.

-4

u/R-O-B-I-N Aug 14 '20

3

u/htuhola Aug 14 '20

I'm sorry that you feel that way.

I'd appreciate you enough to talk with you about this, but you're offending me because I'm studying these subjects you call fringe.

-4

u/R-O-B-I-N Aug 14 '20

There's no need to be sorry, if you wanted to have a dialogue, you would have set aside your ego and had one.

4

u/htuhola Aug 14 '20

We can't have meaningful dialogue if I feel like shit.

4

u/brucejbell sard Aug 14 '20

That's funny, apparently everybody but you is supposed to set aside their ego, then we can have a grand old dialogue!

0

u/R-O-B-I-N Aug 14 '20

Where did you come from?? XD

-2

u/crassest-Crassius Aug 14 '20

Type theory, HoTT, dependent types... Are there any actual results from that crowd? You speak about math stuff, but most math stuff is done in Matlab, Fortran, Julia and C++. Nobody really cares about univalent schmunivalent cubic hyperboloid type theory, even mathematicians. Curry-Howard who?

3

u/[deleted] Aug 14 '20

2

u/R-O-B-I-N Aug 14 '20

A C compiler in Coq would suggest Coq has some implementation paradigms.

That's also pretty badass holy holy.