mirror of
https://github.com/konsoletyper/teavm.git
synced 2024-11-27 01:30:35 +08:00
wasm: change language in DWARF from Java to C++
This is due to weird issue in lldb (from which Chrome dev tools are derived), which does not parse DWARF functions if there's no support for language "type system"
This commit is contained in:
parent
e576a985dd
commit
fed6a2d0ef
@ -54,6 +54,7 @@ public final class DwarfConstants {
|
||||
public static final int DW_ATE_UTF = 0x10;
|
||||
|
||||
public static final int DW_LANG_JAVA = 0x0b;
|
||||
public static final int DW_LANG_C_PLUS_PLUS = 0x04;
|
||||
|
||||
public static final int DW_CHILDREN_YES = 1;
|
||||
public static final int DW_CHILDREN_NO = 0;
|
||||
|
@ -26,7 +26,7 @@ import static org.teavm.backend.wasm.dwarf.DwarfConstants.DW_FORM_ADDR;
|
||||
import static org.teavm.backend.wasm.dwarf.DwarfConstants.DW_FORM_DATA2;
|
||||
import static org.teavm.backend.wasm.dwarf.DwarfConstants.DW_FORM_SEC_OFFSET;
|
||||
import static org.teavm.backend.wasm.dwarf.DwarfConstants.DW_FORM_STRP;
|
||||
import static org.teavm.backend.wasm.dwarf.DwarfConstants.DW_LANG_JAVA;
|
||||
import static org.teavm.backend.wasm.dwarf.DwarfConstants.DW_LANG_C_PLUS_PLUS;
|
||||
import static org.teavm.backend.wasm.dwarf.DwarfConstants.DW_TAG_COMPILE_UNIT;
|
||||
import static org.teavm.backend.wasm.dwarf.DwarfConstants.DW_UT_COMPILE;
|
||||
import java.util.ArrayList;
|
||||
@ -82,7 +82,7 @@ public class DwarfGenerator {
|
||||
data.writeLEB(DW_AT_HIGH_PC).writeLEB(DW_FORM_ADDR);
|
||||
}));
|
||||
infoWriter.writeInt(strings.stringRef("TeaVM"));
|
||||
infoWriter.writeShort(DW_LANG_JAVA);
|
||||
infoWriter.writeShort(DW_LANG_C_PLUS_PLUS);
|
||||
infoWriter.writeInt(strings.stringRef("classes.wasm"));
|
||||
infoWriter.writeInt(0);
|
||||
infoWriter.writeInt(0);
|
||||
|
Loading…
Reference in New Issue
Block a user