jacksonhaenc...@gmail.com writes:
> This is not accurate. I just tested this in python3 and using the global
> keyword allowed me to declare a variable inside the function that was
> then visible from the outer scope.
What do you mean by that?
Anything other than what was said here?
> On Tuesday
I defined a global variable in some function like this,
> >
> > def some_function(self):
> >
> > global global_var
> >
> > PyCharm inspection gave me,
> >
> > Global variable is undefined at the module level
> >
> > How to fix this?
>
Daiyue Weng writes:
> Hi, I defined a global variable in some function like this,
>
> def some_function(self):
>
> global global_var
>
> PyCharm inspection gave me,
>
> Global variable is undefined at the module level
>
> How to fix this?
You define the gl
On Tuesday, September 13, 2016 at 6:42:56 AM UTC-4, Daiyue Weng wrote:
> Hi, I defined a global variable in some function like this,
>
> def some_function(self):
>
> global global_var
>
> PyCharm inspection gave me,
>
> Global variable is undefined at the module
Daiyue Weng wrote:
> Hi, I defined a global variable in some function like this,
>
> def some_function(self):
>
> global global_var
>
> PyCharm inspection gave me,
>
> Global variable is undefined at the module level
There is no single way to silence that com
Hi, I defined a global variable in some function like this,
def some_function(self):
global global_var
PyCharm inspection gave me,
Global variable is undefined at the module level
How to fix this?
cheers
--
https://mail.python.org/mailman/listinfo/python-list