Skip to content

Commit c4e0054

Browse files
committed
workaround: hide malformed error message for now: hopefully fix for milestone 5
1 parent 5610592 commit c4e0054

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

internal/wasmdebug/dwarf_indexing.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,12 @@ func IndexDwarfData(d *dwarf.Data) (ret PCRecord, err error) {
137137
for _, record := range offset2function {
138138
// TODO: are these all the cases when an entry is invalid?
139139
if record == nil || isTombstoneAddr(record.LowPC) || isTombstoneAddr(record.HighPC) || record.Name == "" {
140-
fmt.Fprintf(os.Stderr, "Malformed function entry %s %s:%d\n", record.Name, record.FileName, record.Line)
140+
// TODO: too many cases, spamming the stderr: maybe fix this logic, or something else?
141+
// try to detect when is this really invalid, when it's ok to ignore, when important to log
142+
// and when to do something else
143+
// for Stylus Milestone 5: a more finished version
144+
// for now hide
145+
// fmt.Fprintf(os.Stderr, "Malformed function entry %s %s:%d\n", record.Name, record.FileName, record.Line)
141146
continue
142147
}
143148

0 commit comments

Comments
 (0)