Reputation
15,775
Top tag
Next privilege 20,000 Rep.
Access 'trusted user' tools
Badges
1 39 63
Newest
 Good Answer
Impact
~215k people reached

Jan
20
comment The most human language like programming language
People are using it on pet projects to prove a point, to be challenged, or just for the heck of it. Nobody uses it because it's a good choice of programming language. Except perhaps people who are literally crazy, but we shouldn't base our choice of technology on that ;-) Also, both of these languages are kinda cheating: They're not actually imitating English, they're defined such that one can write code that's also English. A Shakespeare compiler only recognized a few keywords and otherwise just does arithmetic with character codes.
Jan
20
comment The most human language like programming language
Note that both are esoteric language. In other words: Jokes, created only for fun or challenge rather than because someone thought programming like that is a good idea.
Jan
20
awarded  Nice Answer
Jan
19
comment Is function overloading in general considered Evil?
By "GOO", do you mean Go?
Jan
19
comment Is there something like a polymorphic Singleton?
Why would it have to be a singleton? Non-singleton objects can have state just fine.
Jan
18
revised What are the challenges related to typing in writing a compiler for a dynamically typed language?
added 190 characters in body
Jan
18
comment Replacement for instanceof Java?
@Gangus I don't think of this as an "attack", I mean no offense. But whatever. No, the question isn't "what else can be used", it's "is there a better way to do this". Unless you want to argue getClass is a better way to do it, it has no business taking up most of an answer ;-)
Jan
18
comment Replacement for instanceof Java?
I'm complaining about you ignoring Polymorphism, as it's often a better choice. I'm pretty sure the use case in the question can be done with polymorphism, so I don't see the need to use either. (Apart from that, just reproducing someone else's answer isn't nice.)
Jan
18
comment Replacement for instanceof Java?
getClass and instanceof share downsides. Polymorphism is better than both when it fits, and I don't see it not fitting OP's use case.
Jan
17
comment Programming languages classification / taxonomy
But are there formal definitions which can be used to objectively decide whether a language exemplifies X? I don't think so. And then there's the problem of hybrids and such.
Jan
15
comment What features should be tested via automated UI testing?
Apart from every feature of the UI, I presume?
Jan
15
comment Can multiple CPU's / cores access the same RAM simutaneously?
@JimmyHoffa But RAM bandwidth restrictions are precisely what he's talking about (as the assumption is that the task is memory-bound).
Jan
15
comment Is the use of security conditionals in a view a violation of MVC?
What would be the alternative?
Jan
13
comment How to protect my php code running on a client server?
@Songo client as in "the guys paying me for the code", I presume.
Jan
9
comment Possible to implement OOP without using extensive heap operations?
Well, the question of location applies when you look at the implementation. And most implementations allocated practically everything dynamically (though the downsides are offset by tuning the way that memory is allocated). However, PyPy sometimes removes dynamic allocations completely (if the JIT compiler can prove they don't escape), and sometimes optimizes them (delays them, doing some work without touching the heap before allocating).
Jan
9
comment Is it possible to use python as a shell replacement?
Looking just at "just python" (which I presume is core language + stdlib to you) is useless IMHO, in that it doesn't match how the language is actually used.
Jan
9
comment What are the challenges related to typing in writing a compiler for a dynamically typed language?
@SK-logic The only thing that's an implementation detail for me is changes to return value of locals() persisting across calls to locals. What's documented and definitely not an implementation detail is that not even locals or globals can change in which scope each variable is looked up in. For every single use of a variable, the scope to which is refers is statically determined. Which makes it decidedly lexically scoped. (And btw, eval and exec are definitely not implementation details either - look at my answer!)
Jan
9
comment What are the challenges related to typing in writing a compiler for a dynamically typed language?
@SK-logic One can't even change the values of existing variables with locals(), let alone introduce new ones. Well, apparently locals()['foo'] = ...; locals()['foo'] does work in CPython, but this is not documented anywhere (read: is an implementation detail), and doesn't affect the meaning of the identifier foo anywhere -- if it's global according to static analysis, meddling with locals doesn't change that. globals is more powerful, but it just allows you to add/remove attributes of the module, which is no different from adding/removing attributes to any other object.
Jan
8
comment What are the challenges related to typing in writing a compiler for a dynamically typed language?
@SK-logic You can dynamically create code and execute it, but that code also runs lexically scoped. For every single variable in a Python program, you can easily determine which scope a variable belongs to just by inspecting the AST. You may be thinking of the exec statement, which is gone since 3.0 and hence outside my consideration (and probably Guido's, as the talk is from 2012). Could you give an example? And your definition of "dynamic scoping", if it's [different from mine](en.wikipedia.org/wiki/Dynamic_scoping).
Jan
8
answered What are the challenges related to typing in writing a compiler for a dynamically typed language?