zstd/contrib/gen_html
2017-02-22 00:57:50 -08:00
..
.gitignore gen_html: comments of type /*= and /**= can be longer than a single line 2016-12-07 11:13:20 +01:00
gen_html.cpp zstd Manual updated to 1.1.2 2016-12-07 11:18:40 +01:00
gen-zstd-manual.sh added gen-zstd-manual.sh 2016-10-31 10:51:58 +01:00
Makefile added manual target to contrib/gen_html/Makefile 2017-02-22 00:57:50 -08:00
README.md added doc\zstd_manual.html 2016-10-24 16:07:53 +02:00

gen_html - a program for automatic generation of zstd manual

Introduction

This simple C++ program generates a single-page HTML manual from zstd.h.

The format of recognized comment blocks is following:

  • comments of type /*! mean: this is a function declaration; switch comments with declarations
  • comments of type /** and /*- mean: this is a comment; use a <H2> header for the first line
  • comments of type /*= and /**= mean: use a <H3> header and show also all functions until first empty line
  • comments of type /*X where X is different from above-mentioned are ignored

Moreover:

  • ZSTDLIB_API is removed to improve readability
  • typedef are detected and included even if uncommented
  • comments of type /**< and /*!< are detected and only function declaration is highlighted (bold)

Usage

The program requires 3 parameters:

gen_html [zstd_version] [input_file] [output_html]

To compile program and generate zstd manual we have used:

make
./gen_html.exe 1.1.1 ../../lib/zstd.h zstd_manual.html