Questions tagged [abstraction]

Use this tag in reference to either hardware abstraction, such as how Windows can use the same APIs even on different hardware, or any other method where the reality is separated from the user-level programs by software. This should not be used for emulation.

Use this tag in reference to either hardware abstraction, such as how Windows can use the same APIs even on different hardware, or any other method where the reality is separated from the user-level programs by software. This should not be used for emulation. Unless it is describing the method of emulation itself, not just the use of it.

217 questions
89
votes
28 answers

Why is cleverness considered harmful in programming by some people?

I've noticed a lot of questions lately relating to different abstraction techniques, and answers saying basically that the techniques in question are "too clever." I would think that part of our jobs as programmers is to determine the best solutions…
46
votes
5 answers

How to determine the levels of abstraction

I was reading a book today called "Clean code" and I came across a paragraph were the author was talking about the levels of abstraction per a function, he classified some code as low/intermediate/high level of abstraction. My question is what is…
OKAN
  • 745
7
votes
9 answers

Why isn't software abstract on a grander scale?

Consider the following example: The user wants a program to calculate a few fibonacci numbers. Sounds easy enough. pseudocode: stdout.write("How many fibonacci numbers do you want to calculate? ") int count = int(stdin.readline()) while count>0: …
Aran-Fey
  • 245
3
votes
2 answers

Limiting your call stack can guide you to use less abstraction?

I've been watching an presentation from Jonathan Blow on Software Quality. He as a point that adding more and more layers of abstraction gives you not only more difficulty to manage your code, but also we are using too much resources and the…
microo8
  • 147
  • 5
2
votes
1 answer

Is it a good idea to wrap Material-UI Typography components in

,

components etc?

I love the Material-UI library, but some things that I've found annoying: I find Typography too long to write out, especially when I'm having to specify things like gutterBottom, align, etc. Whereas

is much shorter, and I can always do manual…

dwjohnston
  • 2,553

1
vote
2 answers

Are there any rules how the number of indirection layers should be limited?

Just like the two opposing mirrors are enough for infinity, most of design patterns can be applied repeatedly producing any amount of LOC desired. We can always create a factory for any factory or wrap a delegating layer around any class that…
h22
  • 927
1
vote
3 answers

Resistance to abstraction

I am on an ASP.NET MVC project where we use Razor to define pages. One thing I like to do is to use Razor's @helper to DRY up pretty much any duplication in HTML (i.e. formalize even small UI patterns). To give an example. At the top of the page…
user93422
  • 121
-1
votes
1 answer

variables as abstractions for the memory cells

How are variables abstractions for the memory cells of the machine? Is it because you can change the value stored in the memory cell by assigning a different value to the variable associated with the said memory cell?
blah
  • 21