Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • G GLib
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 859
    • Issues 859
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 42
    • Merge requests 42
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GNOMEGNOME
  • GLib
  • Issues
  • #2493
Closed
Open
Issue created Sep 19, 2021 by Philip Chimento@ptomato🚮Developer

gsize is not equivalent to size_t on certain platforms

My understanding is that gsize should be equivalent to size_t everywhere. However, on certain platforms (at least on 32-bit PPC which is quite obsolete, but possibly on other 32-bit platforms), int and long are the same size and size_t is defined to be unsigned long, whereas this logic in GLib's build system will end up defining gsize to be unsigned int, meaning that gsize and size_t will then be incompatible. We received a bug report about this in GJS (gjs!680 (closed)).

I'm not sure what exactly is going wrong. Maybe the issue is that the checks in that build system code are not using -fpermissive, or maybe the checks need to check the reverse as well, that size_t* is convertible to gsize* without error, or maybe the checks need to use C++?

Assignee
Assign to
Time tracking