1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185
|
# Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## unreleased
## 1.6.4 - 2023-03-11
### Fixed
- Fix the `DOWNLOAD_EXTRACT_TIMESTAMP` CMake warning ([issue #15](https://github.com/Hirrolot/datatype99/issues/15)).
## 1.6.3 - 2022-05-15
### Fixed
- Generation of binding variables when compiling on C++ ([issue #14](https://github.com/Hirrolot/datatype99/issues/14)).
## 1.6.2 - 2022-01-02
### Fixed
- Initialise `.data.dummy` to `'\0'` for empty variants. Previously, it was uninitialised.
## 1.6.1 - 2021-12-09
### Fixed
- Specify `C` as the project language in `CMakeLists.txt`. Previously, CMake detected C++ and required a C++ compiler to compile the project.
- Require CMake v3.11.4.
## 1.6.0 - 2021-12-01
### Added
- Add the root `CMakeLists.txt` to be able to use CMake with [`FetchContent`] or [`add_subdirectory`].
[`FetchContent`]: https://cmake.org/cmake/help/latest/module/FetchContent.html
[`add_subdirectory`]: https://cmake.org/cmake/help/latest/command/add_subdirectory.html
## 1.5.2 - 2021-11-09
### Fixed
- The `derive` attribute was made into a macro (see [issue #12](https://github.com/Hirrolot/datatype99/issues/12)).
## 1.5.1 - 2021-10-06
### Fixed
- Previously, shortcuts referring to functional macros were object-like. To avoid nasty compilation errors, now they are function-like too:
- `datatype(...)`
- `record(...)`
- `match(val)`
- `MATCHES(val, tag)`
- `matches(val, tag)`
- `ifLet(val, tag, ...)`
- `of(...)`
## 1.5.0 - 2021-08-27
### Added
- `DATATYPE99_VERSION_COMPATIBLE` to check for a SemVer-compatible version.
- `DATATYPE99_VERSION_EQ` to check for an exact version.
## 1.4.0 - 2021-08-13
### Added
- `MATCHES`/`MATCHES99` to know where is a macro and where is a function.
### Deprecated
- `matches`/`matches99`; use `MATCHES`/`MATCHES99` instead.
## 1.3.0 - 2021-07-27
### Added
- An empty record -- `record(Foo)`.
## 1.2.0 - 2021-06-06
### Added
- `record`, `DATATYPE99_record`, `DATATYPE99_RECORD_DERIVE_` to generate a record type.
- The `dummy` deriver for record types.
### Fixed
- Add the missing arity specifier for `DATATYPE99_datatype`.
- Make Datatype99 work on TCC (see [issue #10](https://github.com/Hirrolot/datatype99/issues/10)).
## 1.1.0 - 2021-04-24
### Added
- A mechanism for deriving: `datatype` now can be specified with `derive(...)`.
- Manipulation of attributes:
- `DATATYPE99_attrIsPresent`/`DATATYPE99_ATTR_IS_PRESENT` to check the presence of an attribute.
- `DATATYPE99_attrValue`/`DATATYPE99_ATTR_VALUE` to extract an attribute's value.
- `DATATYPE99_assertAttrIsPresent` to assert a mandatory attribute.
- A deriver `dummy` which generates nothing.
- Metalang99-compliant counterparts: `DATATYPE99_of`, `DATATYPE99_ifLet`.
### Changed
- Do **not** suppress `-Wmisleading-indentation` (GCC) automatically in `match`.
### Fixed
- `#pragma GCC diagnostic` inside functions error on GCC older than 4.6 ([issue #8](https://github.com/Hirrolot/datatype99/issues/8)).
- Inconsistent suppression of `-Wreturn-type` ([issue #9](https://github.com/Hirrolot/datatype99/issues/9)).
- Suppress Clang's `-Wcast-qual` in `ifLet`.
## 1.0.0 - 2021-03-28
### Added
- `DATATYPE99_MAJOR`, `DATATYPE99_MINOR`, `DATATYPE99_PATCH`.
### Changed
- `Unit` => `UnitT`, `unit` => `unit_v` (less likely to conflict with user-defined identifiers).
### Fixed
- Suppress Clang's `-Wcast-qual` in `match`.
## 0.4.0 - 2021-03-27
### Added
- `ifLet` to match only a single variant.
### Changed
- `<datatype-name>Data` => `<datatype-name>Variants` (less likely to conflict with user-defined types).
### Fixed
- Avoid using `METALANG99_semicolon` because it turned out to be [dangerous](https://github.com/Hirrolot/metalang99/commit/f17f06adf1a747a8897bbc90c598b2be21c945c8).
- Clang's `-Wused-but-marked-unused` in `of`.
- The specification now requires an lvalue for `match`.
## 0.3.1 - 2021-02-28
### Added
- Generate `<datatype-name>Tag` and `<datatype-name>Data`.
### Fixed
- Suppress `-Wmisleading-indentation` only when `__GNUC__ >= 6`.
- Suppress `-Wreturn-type` for Clang too.
- Make it work on C++11.
## 0.3.0 - 2021-02-26
### Changed
- Force users to download Metalang99 as well, i.e. don't use it as a Git submodule.
- Annotate value constructors with `__attribute__((warn_unused_result))` and `__attribute__((const))` if supported.
### Added
- Generate `typedef struct <datatype-name> <datatype-name>;` beforehand so `<datatype-name> *` can be used instead of `struct <datatype-name> *` inside variants.
- The reserved `_` identifier for `of`.
- Error reporting about an unparenthesised variant like `Bar(int)`.
- `Unit` and `unit`.
## 0.2.0 - 2021-02-05
### Changed
- Replace `Epilepsy` with `Metalang99` (more neutral).
## 0.1.0 - 2021-02-04
### Added
- This excellent project.
|