mirror of
https://github.com/erg-lang/erg.git
synced 2025-08-01 09:22:50 +00:00
Fix private variables to be completely inaccessible
This commit is contained in:
parent
1532496a32
commit
8dcc44b9cb
1 changed files with 2 additions and 2 deletions
|
@ -233,9 +233,9 @@ fn escape_name(ident: Identifier) -> Str {
|
|||
name = name.replace('!', "__erg_proc");
|
||||
name = name.replace('$', "__erg_shared");
|
||||
if vis.is_public() || is_python_global(&name) {
|
||||
Str::rc(&name)
|
||||
Str::from(name)
|
||||
} else {
|
||||
Str::from("__".to_string() + &name)
|
||||
Str::from("::".to_string() + &name)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue