-
Notifications
You must be signed in to change notification settings - Fork 5.4k
Open
Labels
bugSomething isn't workingSomething isn't workingcompilerGeneral compiler. Should eventually become more specific as the issue is triagedGeneral compiler. Should eventually become more specific as the issue is triagedcompiler: irIRgen and sway-ir including optimization passesIRgen and sway-ir including optimization passesteam:compilerCompiler TeamCompiler Team
Description
Steps to reproduce: create a script project with these two files:
// module.sw
library;
struct S {}
impl S {
fn function() {
panic "This is an error message.";
}
}
fn function() {
panic "This is an error message.";
}
pub fn module_main() {
function();
S::function();
}
script;
mod module;
struct S {}
impl S {
fn function() {
panic "This is an error message.";
}
}
fn function() {
panic "This is an error message.";
}
fn main() {
function();
S::function();
module::module_main();
}
When compiling the script, only one error code will be created, for the first function
that gets compiled.
"errorCodes": {
"0": {
"pos": {
"function": "same_fn_issue::function",
"pkg": "same_fn_issue",
"file": "src/main.sw",
"line": 14,
"column": 5
},
"logId": null,
"msg": "This is an error message."
}
},
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingcompilerGeneral compiler. Should eventually become more specific as the issue is triagedGeneral compiler. Should eventually become more specific as the issue is triagedcompiler: irIRgen and sway-ir including optimization passesIRgen and sway-ir including optimization passesteam:compilerCompiler TeamCompiler Team