MagicStack/MagicPython

Decorator Syntax Errors

dg-pb opened this issue · 0 comments

dg-pb commented

So decorators have very strict syntax, while in reality, any valid python expression can be used when decorating. See github's highlighting below too.

  • Editor name and version: Sublime Text 4152
  • Platform: MacOSX
  • Color scheme: Custom, but any
  • MagicPython version: v.1.1.1
  • A sreenshot:
  • 5-10 lines of surrounding code:
class A:
    @D[C][prtl]
    def a(self):
        pass

    @a | b | c
    def a(self):
        pass