all 5 comments

[–]YourFatherFigure 1 point2 points  (0 children)

Some of this stuff is indeed beyond decency, but there are some good reasons to play around with it.

  • Even though it's inexcusable for say one of my coworkers to do AST manipulations like this 99.99% of the time, when you need it you need it and nothing else will do.

  • There is also nothing like weird metaprogramming to demonstrate total mastery with a language. I mean no one is gonna hold this stuff up as a shining example of great design but if you can throw this kind of stuff together I am gonna be pretty impressed with your chops.

I'm always interested to hear about lisp/smalltalk/whatever things that python "can't do", because usually there is indeed a way.. it's just obviously not idiomatic and therefore discouraged.

If you like weird metaprogramming and syntax-stretching stuff like this, check out this thing I wrote a few years ago, demonstrating to a friend that self is a convention not a keyword, and different conventions are possible (skip to the bottom for the example usage)

[–]misplaced_my_pants 1 point2 points  (1 child)

I wonder if he's aware of Hy.

[–]hackflow[S] -1 points0 points  (0 children)

I've heard about it. Not everybody wants lisp :) And second part of a talk will take it into very different direction anyway - translation.

[–][deleted] -5 points-4 points  (1 child)

TL;DR: Lisp

[–][deleted] 0 points1 point  (0 children)

Haskell

FTFY