View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0000189 | Gameplay + OpenGL | [All Projects] Bug | public | 2017-02-05 06:49 | 2017-02-05 15:25 |
Reporter | Edward-san | ||||
Assigned To | Graf Zahl | ||||
Priority | normal | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Summary | 0000189: GCC 6 compile error - ParseDrawTextureTags | ||||
Description | It happens only with GCC version 6.
| ||||
Tags | No tags attached. | ||||
Will it work if tags will be passed by value, like in this commit? This fixes compilation errors with GCC 6.3 but because of unrelated problems I cannot test it at runtime. |
|
I seriously have to wonder here: What were those idiots smoking when they made va_list an array? This breaks so much code it's almost unbelievable. Is there any sane way to pass this to a function without some compiler getting the hiccups? As it stands, some systems need a pass by reference, others need a pass by value so what to do? |
|
Pass by value works in Clang too. I didn't try in MSVC yet but it should work everywhere. | |
It originally was pass by value until you changed it. | |
No, it was in mixed form but va_list value could not be bound to a reference. | |
Yeah, that seems to work with GCC 6. | |
I think I was wrong when changed tags param of this function to reference type. Most likely all other usages of va_list should be changed to values instead. This need some testing though. |
|
Right, sorry, I didn't check that actually it fails at linking time. | |
Anyway it's impossible to use values everywhere because bunch of functions modifies their parameter. Googling the problem revealed that only a pointer to va_list is portable way to do this. |
|
Edward-san, could you please try this commit with GCC 6? | |
By now I believe that the only safe way is to put the va_list into a struct and pass references to that around. | |
If you can confirm that my last commit works, feel free to close this report. | |
Yeah, it works now. | |
Date Modified | Username | Field | Change |
---|---|---|---|
2017-02-05 06:49 | Edward-san | New Issue | |
2017-02-05 07:31 | _mental_ | Note Added: 0000384 | |
2017-02-05 07:49 | _mental_ | Note Edited: 0000384 | View Revisions |
2017-02-05 10:04 | Graf Zahl | Note Added: 0000385 | |
2017-02-05 10:04 | Graf Zahl | Assigned To | => Edward-san |
2017-02-05 10:04 | Graf Zahl | Status | new => assigned |
2017-02-05 11:09 | _mental_ | Note Added: 0000388 | |
2017-02-05 11:26 | Graf Zahl | Note Added: 0000391 | |
2017-02-05 11:30 | _mental_ | Note Added: 0000392 | |
2017-02-05 11:40 | Edward-san | Note Added: 0000393 | |
2017-02-05 11:48 | _mental_ | Note Added: 0000394 | |
2017-02-05 11:48 | _mental_ | Note Edited: 0000394 | View Revisions |
2017-02-05 11:51 | Edward-san | Note Added: 0000395 | |
2017-02-05 13:47 | _mental_ | Note Added: 0000397 | |
2017-02-05 14:42 | _mental_ | Note Added: 0000399 | |
2017-02-05 14:45 | Graf Zahl | Note Added: 0000401 | |
2017-02-05 14:54 | Graf Zahl | Note Added: 0000402 | |
2017-02-05 15:24 | Edward-san | Status | assigned => resolved |
2017-02-05 15:24 | Edward-san | Resolution | open => fixed |
2017-02-05 15:24 | Edward-san | Note Added: 0000403 | |
2017-02-05 15:25 | Edward-san | Assigned To | Edward-san => Graf Zahl |