Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
gobject-introspection
gobject-introspection
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 227
    • Issues 227
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 18
    • Merge Requests 18
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • GNOME
  • gobject-introspectiongobject-introspection
  • Issues
  • #372

Closed
Open
Opened Jan 08, 2021 by Emmanuele Bassi@ebassi👣Maintainer

Add annotation for removing default constructor

Not all concrete types can, or should be available for construction:

  1. ancillary types that are managed by other types
  2. singleton types with a specific "static" function returning an instance

Various bindings will allow creating an instance of any non-abstract public type just by invoking g_object_new(), which leads to interesting bugs.

A simple annotation for a class type like no-default-constructor would allow bindings to warn/error when trying to instantiate a class.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: GNOME/gobject-introspection#372