Community
    • Login

    list functions issue with python

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    1 Posts 1 Posters 1.4k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Richard WethR
      Richard Weth
      last edited by

      This is a minimal recreate :

      import re
      class foo (object):
      def init(self):
      self.zing = “joemama”
      def bar(self):
      print “bar”

      When I list the function of this class it does not work. However if I add a space to the beginning of the class definition … list functions performs as desired. Sadly adding a space before class breaks the code, so there is no harmony here.
      Why would this happen … my eol == LF (unix) encoding is utf, and this operates on a windows system with python 2.7.9

      Kinda mystified here. Esp since the only workaround is this (this works)
      #<begin code>
      import re
      class foo (object):
      def init(self):
      self.zing = “joemama”
      def bar(self):
      #<end code>
      print “bar”

      1 Reply Last reply Reply Quote 0
      • First post
        Last post
      The Community of users of the Notepad++ text editor.
      Powered by NodeBB | Contributors