Every line of 'python globals()' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your Python code is secure.
18 def test_globals(self): 19 self.assert_ok("""\ 20 global xyz 21 xyz=2106 22 23 def abc(): 24 global xyz 25 xyz+=1 26 print("Midst:",xyz) 27 28 29 print "Pre:",xyz 30 abc() 31 print "Post:",xyz 32 """)
Secure your code as it's written. Use Snyk Code to scan source code in minutes – no build needed – and fix issues immediately. Enable Snyk Code
275 def _locals(): 276 '''(INTERNAL) For C{pycocoa.__main__.py} only' 277 ''' 278 return globals()
62 def globals(self): 63 code = self.get_bytecode() 64 return code.globals()