It is illustrative to compare Block, Internal`InheritedBlock, Module, and With. Both Module and With create unique versions of the variables which are not accessible from the outside (lexical scoping, and not without its issues), e.g.
x = 2 y^2 - 7;
With[{y = 5}, x]
Module[{y = 5}, x]
where both With and Module return -7 + 2 y^2. With has the added ability to bypass Hold attributes, which is very useful sometimes. Because of this, it would be difficult to use them to run arbitrary code passed in by a user. In contrast, Block and Internal`InheritedBlock allow you to temporarily augment/overwrite an existing variable, and guarantee that the changes are reset.
A useful example of augmentation, is automatically resetting changes made to default Options, e.g.
Internal`InheritedBlock[{Plot},
SetOptions[Plot, PlotStyle -> {Red, Blue, Green}];
Options[Plot, PlotStyle]
]
(* {PlotStyle -> {Red, Blue, Green}} *)
vs
Options[Plot, PlotStyle]
(* {PlotStyle -> Automatic} *)
which can be used to generate many plots where the options are uniform, without resorting to crafting a unique theme. A more interesting example is this graphics parser which uses Internal`InheritedBlock to mimic a stack in tracking the state. If you want a more extensive augmentation, though, you still need to Unprotect the symbol. This is where Block comes in as quite often you do not want to just augment the behavior, but overwrite it entirely.
This is the use case for Plot, Table, etc. where the user supplies a symbol/expression that needs to be evaluated without worrying about whether it has *Values. Internal`LocalizedBlock extends this further by localizing things like Subscript[x, 1] which Block cannot handle.
Of course all these can be merged. Consider this answer from Leonid which traces what packages auto-load another package. It uses Module to set up a closure which uses the Villegas-Gayley pattern to augment Needs. Here Block plays the important role of blocking recursive execution.
SetAttributes[x, Protected]; Table[x, {x, 2}]? – Michael E2 Aug 30 '16 at 14:24Block, isn't it? Or is your question whyTableis based onBlock? – Kuba Aug 30 '16 at 14:30OwnValues, check out [Internal`LocalizedBlock](http://mathematica.stackexchange.com/q/71881/52). – rcollyer Aug 30 '16 at 14:55InternalInheritedBlock` perhaps. – Daniel Lichtblau Aug 30 '16 at 15:22*Valuesthat remain. :) – rcollyer Aug 30 '16 at 15:37Blockdoes anything else butold = x; x = new; ... code ...; x = old(ensuring the reset happens even afterThrowandAbort). I don't understand why it removes all definitions and Attributes altogether, instead of just giving a (new) OwnValue. It would also be more efficient to just give a new OwnValue, not bothering with other values, no? – masterxilo Aug 30 '16 at 16:01Block"-constructs, while they are preserved when you give compound expressions.Table[\[FormalX][0], {\[FormalX][0], 1}]gives an error. – masterxilo Aug 30 '16 at 16:03Blockcan't dox = new;ifxisProtected. – Michael E2 Aug 30 '16 at 16:36SetAttributes[x, Protected]; Block[{x = 5}, x]? – rcollyer Aug 30 '16 at 19:03xis notProtectedinsideBlock. IfBlockdid not clear the attribute, the assignment would fail and so wouldBlock[{x}, x = 5](and my first example, too). Or isxprotected when the assignmentBlock[{x = 5}...is made? – Michael E2 Aug 30 '16 at 19:45Blockdid notUnprotectx, and it is clear it must. So, disregard. :) – rcollyer Aug 30 '16 at 19:52