-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Import of name from bundle that doesn't exist #1283
Comments
I think one way to solve that would be to completely remove aliases for mod a {
pub fn g(){super::b::h()}
pub struct A(pub i32);
}
mod b {
pub fn h(){super::a::g()}
}
fn f(x: a::A) -> i32 {
x.0
} Open this code snippet in the playground Lax-checking still works without the @W95Psp Do you think this would be ok? And how can we identify a name that corresponds to one of these accessors? |
Other thing we should probably not produce aliases for: traits. Example: mod encoder {
trait Encode {
fn encode();
}
pub fn foo(){
super::user::something();
}
}
mod user {
pub fn something() {
super::encoder::foo();
}
} Open this code snippet in the playground |
I think that indeed not producing aliases for field names makes sense. However, for the traits, I think that's a problem in F*: currently, |
This is a regression form #1199, here is a reproducer:
Open this code snippet in the playground
F* laxing fails with:
Definition Playground.Bundle.impl__f___0 cannot be found
.This is because of
include Playground.Bundle {impl__f___0 as impl_A__f___0}
Here we have an alias for the
._0
accessor for the anonymous field inTest
butTest
is defined inside an impl methods which messes with the name.The text was updated successfully, but these errors were encountered: