Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • SWIFTsim SWIFTsim
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 53
    • Issues 53
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 21
    • Merge requests 21
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • SWIFT
  • SWIFTsimSWIFTsim
  • Merge requests
  • !1504

Comment out field designators when initializing lightcone map types

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged John Helly requested to merge lightcone_gcc_bug into master Mar 04, 2022
  • Overview 12
  • Commits 5
  • Changes 9

This is a workaround for this gcc bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55227

Using a struct initializer with a field name for a char * field prevents the code from compiling as C++ with current versions of gcc. This merger request comments out the field names, since relying on the ordering appears to be allowed in C and C++. I've also added casts on a couple of calloc() calls where they were missing.

Not tested yet because it needs a few more fixes in the cooling, feedback and extra_io modules to compile as C++.

Edited Mar 21, 2022 by Peter W. Draper
Assignee
Assign to
Reviewer
Request review from
Time tracking
Source branch: lightcone_gcc_bug