On Sun, Aug 31, 2025 at 7:07 PM Alex <alex.rou...@gmail.com> wrote: > > That gives me "<nil> offset 0 is before the start of string table"
Thanks. That implies that some symbol or section name has a long name with a string table offset of 0. There are several possibilities here. Can you send us the actual PE object file? Thanks. Ian > On Monday, 1 September 2025 at 10:03:37 am UTC+8 Ian Lance Taylor wrote: >> >> On Sun, Aug 31, 2025 at 6:18 PM Alex <alex....@gmail.com> wrote: >> > >> > both of them reports coff >> > ``` >> > _cgo_.o: file format coff-x86-64 >> > architecture: x86_64 >> > start address: 0x0000000000000000 >> > ``` >> >> The error you are getting from cgo means that pe.Open failed on the >> object file generated by clang21. Try running a trivial program like >> (untested) >> >> package main >> >> import ( >> "debug/pe" >> "fmt" >> "os" >> ) >> >> func main() { >> fmt.Println(pe.Open(os.Args[1])) >> } >> >> >> Presumably it will fail if run with the argument being an object >> generated by clang21. The error message may suggest what the problem >> is. >> >> Ian > > -- > You received this message because you are subscribed to the Google Groups > "golang-nuts" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to golang-nuts+unsubscr...@googlegroups.com. > To view this discussion visit > https://groups.google.com/d/msgid/golang-nuts/1c69d907-df43-4e20-a572-9c888581c958n%40googlegroups.com. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/golang-nuts/CAOyqgcUjRBb6A-Kjavj8E5Cx_yppXAH4H0KqJM%3DscYrFBW6t4g%40mail.gmail.com.