Skip to content

WIP: FN, STRUCT, STRUCT*, DEFINER*, method/function SETF, less warnings

Le BigMac requested to merge Le-Brut/definer:master into master

Hi! Could you, please, take a look at this?

Here's the summary:

  1. Converted (name symbol) -> name for methods and functions, so that setf definitions work.
  2. Defined fn alias for function, I think it's good to have something as short, convenient and intuitive for something used so often.
  3. Uncommented struct definition -> makes it easy to convert already existing defstructs.
  4. Renamed structure to struct*, but made an alias to it for compatibility.
  5. Added (declare (ignore prefix-options)) nearly everywhere due to the warnings.
  6. Added :ignore-prefix-options to definer for the reasons of point 5 (this time to avoid warnings also in client code), and definer* for a shorthand to that.
  7. Added FN, STRUCT, STRUCT*, DEFINER* to exports.

As for the structures and them behaving as class definitions. Way I see it, there's no need to choose which behavior to keep (class-like or regular), just have both with different names. Could say that anything unexpected/modified should be easily discernible, e.g. say with a star: struct* or structure*. Ideally, the current class-like 'structure would be called 'structure*, and 'structure would be the regular 'struct. But since it may break people's code, I left it alone.

What do you think of these changes?

Merge request reports