0

As a little experiment I'm trying to add a builtin into python, which could be done via auto importing with a pre processor or something. I don't know, whats the best way to go around this?

**EDIT: ** Thank you @wjandrea for telling me I would have to recompile python to acomplish my 'little experiment' lol. Fixed Gramar and Made Question clearer

RhinoCodes
  • 71
  • 7

1 Answers1

1

To add a builtin, you'd need to recompile Python.

As the Zen of Python says, "Explicit is better than implicit". So the recommended route is just to import the module/function wherever you need it. To make that simpler when writing scripts, you could add a snippet in your IDE/code editor.

wjandrea
  • 28,235
  • 9
  • 60
  • 81