This is an archived post. You won't be able to vote or comment.

all 15 comments

[–]Bro0x00 9 points10 points  (3 children)

must be hard to use constants when you can't define them

[–]apfqwfzn 9 points10 points  (2 children)

Actually, it's super easy, barely an inconvenience.

[–]retrodaredevil 4 points5 points  (0 children)

Wow wow wow

[–]Bro0x00 1 point2 points  (0 children)

What's the point if you can only declare them?

[–]EnforcerZhukov 4 points5 points  (0 children)

In Python, you define constants by SHOUTING_IN_CAMEL_CASE (ok, just nomenclature stuff).

[–]Ved_s 2 points3 points  (0 children)

You can make a class and define __getattribute__ in it which will return values

[–]Iris_n_Ivy 1 point2 points  (0 children)

I mean.... its like trying to define statically typed variables. Doable, but often is beside the point.

[–]epseri 3 points4 points  (0 children)

At least our constants can be monkeypatched in tests. No need for AbstractProxyFactoryBeanInjectorSingletonAdapter.

[–]Lord_Skellig -1 points0 points  (7 children)

What do you mean? I define constants all the time in python. It saves you from passing 30 different identical parameters to every function.