Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Redefinition in a view reported unresolved with two exposes and a metadata usage

Đã đóng
#649 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
55/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
go
Lĩnh vực
compilers

Hướng nghiên cứu

Reproduce the example with sysml -validate using the issue's redef.sysml case and confirm that removing any one of the three triggering elements avoids the error. Trace the name-resolution path for view redefinitions, two expose statements, private imports, and metadata usage. Done means the supplied file validates without an unresolved kind reference and regression coverage preserves that behavior.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

sysml -validate (v0.9.0, and develop with #638 applied) reports a valid redefinition as unresolved:

package Lib {
    private import ScalarValues::*;
    metadata def Tag;
    view def Dia { attribute kind : String; }
}
package P1 { private import Lib::*; }
package P2 { private import Lib::*; }
package App {
    private import Lib::*;
    view v : Dia {
        expose P1::*;
        expose P2::*;
        @Tag;
        attribute :>> kind = "grid";
    }
}
redef.sysml:14:23: error: unresolved reference: kind — did you mean Lib::Dia::kind?

It validates cleanly if you remove any one of:

  • the second expose
  • @Tag;
  • the private import Lib::*; in P1 and P2

Expected: no error. v inherits kind from Dia (OwnedRedefinition, SysML-textual-bnf :482). SysIDE accepts the file.

Ngôn ngữ chính
Go
Star
24
Fork
5
Merge trung bình
10 giờ 11 phút
Pull request đã merge (30 ngày)
572

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của Open-MBEE/OpenSysML

Tất cả issue của Open-MBEE/OpenSysML

Issue tương tự

Thêm issue về Go

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.