Skip to content
Commit 77c00208 authored by Kjell Ahlstedt's avatar Kjell Ahlstedt
Browse files

gmmproc, _WRAP_ENUM: Generate enum class; enums can be inside classes

Two modifications of _WRAP_ENUM:
  1. It is expanded to an enum class instead of a plain enum. It means that
  it can't be implicitly converted to an int, and that enumerator names are
  local to the enum.

  2. It can be located in a class, with some restrictions.
  When located in a class, and a Value specialization shall be generated
  (NO_GTYPE is not specified) or it's a Flags type (i.e. bitwise operators
  shall be generated), then the following requirements must be met:
  2.1. _WRAP_ENUM must be located in the public part of the class.
  2.2. The class must contain a class macro (_CLASS_GENERIC, _CLASS_GOBJECT,
       _CLASS_GTKOBJECT, etc.) before _WRAP_ENUM.

Two new elements can be included in docs_override.xml files:
substitute_type_name and substitute_enumerator_name. They improve the
translation of C names to C++ names in documentation. See examples in
glibmm and in gtkmm.

Bug 86864
parent 442a4292
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment