Questions tagged [programming-languages]
Artificial languages for instructing computers to do steps of computation in order to complete tasks. They allow programmers to communicate with computers.
1,406 questions
2 votes
5 answers
1k views
Why don't languages auto import everything based on namespace?
This is basically a continuation of "Why don't languages auto import everything?" but with a slightly altered premisse: Say we have a language like C++ / python that uses namespaces to ...
35 votes
11 answers
13k views
Why don't programming languages or IDEs support attaching descriptive metadata to variables?
As developers, we often face the challenge of balancing meaningful variable names with code readability. Long, descriptive names can make code harder to read, while short names may lack context. For ...
3 votes
5 answers
1k views
How are strings simultaneously objects and primitive data types in C#?
In C#, strings can be used like objects with methods, properties, and other features of objects. At the same time, strings are treated the same as primitive data types like int or float in numerous ...
1 vote
1 answer
723 views
Tagged pointers vs. fat pointers
I'm writing my own dynamic programming language. So far I've been using a tagged union for all values. Since this boxes primitive types needlessly, I've begun researching tagged pointers which seem to ...
0 votes
1 answer
186 views
Bytecode format and loading in language VMs
I am thinking about how to build a language VM. I have been able to get some of the basic constructs right, including jumps to functions within the chunk of bytecode that is currently loaded. But now ...
0 votes
2 answers
318 views
Advantage of implicit/explicit declaration of global symbols (like functions)
In C and C++ we need to declare a function before its usage, if its definition comes after where it is called. (Well, there is also the "implicit declaration" rule in C, but it is rarely ...
0 votes
2 answers
771 views
Is there a language agnostic interface for programming language interop?
There are many packages for creating bindings of a library that's written in one language to be called from another language. Some programming languages also include such interop in the standard ...
1 vote
5 answers
846 views
Why don't languages auto import everything?
Why is there a such thing as import in programming languages? If a package does not exist, then trying to import it would cause an error anyway. So why don't languages just auto import ALL available ...