Skip to content

Commit

Permalink
compiler: fix code generation will not generate string literals with …
Browse files Browse the repository at this point in the history
…literal-special algorithm for structure ostream
  • Loading branch information
mertcandav committed Aug 1, 2024
1 parent 02d3d62 commit 4fc0415
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/julec/obj/cxx/object.jule
Original file line number Diff line number Diff line change
Expand Up @@ -1232,13 +1232,13 @@ impl ObjectCoder {
self.write("(&_Src);\n")
} else {
self.write(`_Stream << "`)
self.writeR(s.Decl.Ident)
self.write(cstrBytes([]byte(s.Decl.Ident)))
self.write("{\";\n")

for (i, mut f) in s.Fields {
self.indent()
self.write(`_Stream << "`)
self.writeR(f.Decl.Ident)
self.write(cstrBytes([]byte(f.Decl.Ident)))
self.write(`:`)

// Skip binded struct kinds.
Expand Down

0 comments on commit 4fc0415

Please sign in to comment.