[vtk-developers] New module system preview

Ben Boeckel ben.boeckel at kitware.com
Mon Oct 29 17:42:11 EDT 2018


On Mon, Oct 29, 2018 at 22:31:38 +0100, Elvis Stansvik wrote:
> Let me just jump in and say that while it sounds neat to embed it
> comments, it might make it slightly harder to make an updated version
> of Utilities/Maintenance/WhatModulesVTK.py script (which I love!).

Thanks for the reminder that this file needs updated.

CMake supports long-form comments now, so I'd think it'd be in blocks
like this:

```cmake
#[==[vtk.kit
...
#]==]
#[==[vtk.module
...
#]==]
```

with a limit of one `vtk.module` per file. Easy to slice out with a
simple `sed` call. Not so easy in CMake, but also not ridiculous.

This is similar to the way the new module system is documented:

```cmake
#[==[.md
...
#]==]
```

which will make it possible to extract out these blocks and feed them to
Doxygen and get the module system API docs on the web with the rest of
VTK.

There's also `#[==[.md INTERNAL` for internal function documentation as
well.

--Ben


More information about the vtk-developers mailing list