16 lines
380 B
Plaintext
16 lines
380 B
Plaintext
// Legacy neg_param, now a positive lexical-scope case. The package selector
|
|
// in main uses the file-scope import; the parameter named shadowmod is a
|
|
// closer binding only inside probe. Builds and runs 42 + len("hi") = 44.
|
|
|
|
package main;
|
|
|
|
import shadowmod;
|
|
|
|
fn probe(shadowmod: str) i32 = {
|
|
return shadowmod.len;
|
|
};
|
|
|
|
fn main() i32 = {
|
|
return shadowmod.say() + probe("hi");
|
|
};
|