| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
GTK-Doc description fields for tags can contain multiple lines and
even multiple paragraphs. Whitespace cannot be preserved in XML
attributes, so we move the "deprecated" description text into
a "<doc-deprecated />" element right next to where we already have
the "<doc />" element. Keep the "deprecated" attribute around for
backwards compatibility though, but set its value to "1" (analogous
to the "writable", "contruct", etc attributes) if the annotated
symbol is marked as deprecated.
While at it, add <doc-version /> and <doc-stability /> which
was not yet available in the .gir files...
This takes care of the "Since:", "Stability:" and "Deprecated:"
GTK-Doc tags. Nothing needs to be done for the "Returns:" tag as
as we already write a "<doc />" child element on "<return-value />".
|
|
|
|
|
|
| |
so we can later use them to re-write source files containing
broken GTK-Doc comment blocks where /** is preceded by and/or
*/ is followed by code...
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
- annotations on the identifier (formerly g-i specific tags) have
never been validated before, so fix this
- removes duplicate validation code from GtkDocTag and GtkDocParameter
- remove repeated validation code doing the same thing as
annotationparser from maintransformer...
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
After discussing a different issue with the GTK-Doc maintainers,
we learned that our g-i specific top level tags should never have
existed in the first place. The prefered notation for annotations
that apply to the identifier should be written on the identifier
line, for example like what we already do with (skip).
As a result, this patch deprecates g-i specific top level tags and
implements them as annotations on the identifier instead but still
keeps support for malformed comment blocks using g-i specific top
level tags.
This means that all annotated code "out there" will continue to work
just fine with this version of g-i, but when a developer decides to
fix deprecation warnings in his/her comment blocks, the dependency
on g-i needs to be raised to a version that contains at least this
patch. #676133
https://bugzilla.gnome.org/show_bug.cgi?id=676133
|
|
|
|
|
|
|
|
|
|
| |
- remove annotations regex, restore proper parens parsing
- drop weird DocOption() storage class and use lists/dicts
as appropriate
- make GtkDocAnnotations a simple OrderedDict subclass instead
of a weird hybrid dict/list storage class
- Deprecate Attribute: tag, replace with (attributes) annotation
on the identifier
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Write them in alphabetical order and explain what
they are used for a bit more clearly.
|
| |
|
|
|
|
|
|
| |
No need to track what type of identifier we've found as we don't
use that information later on. Continue searching for an identifier
if it's not found on the first line like gtkdoc-mkdb does.
|
|
|
|
| |
and move it below DocOption for easier reading
|
|
|
|
|
| |
and move it downwards after DocOption and DocAnnotations
for easier reading
|
|
|
|
|
| |
and move it downwards after DocTag, DocOptions etc for
easier reading
|
|
|
|
|
| |
Accepted by old version of annotationparser.py and actually
encountered in the wild. Internaly normalize to 'Returns:'.
|
|
|
|
|
|
|
|
| |
Turns out gtkdoc-mkdb has always accepted identifier parts
with and without a delimiter after the identifier_name field,
so it is safe to only require it when annotations are present or
in other words, when there are actually multiple fields to be
seperated...
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It's not yet being used but will be in the future by
annotationparser.py to signal the difference between
message.WARNING:
something is wrong but the comment block can still
be parsed and serialized back into a comment block
without information being lost
message.ERROR:
something is wrong and the comment block can *not*
be parsed and serialized back into a comment block
without information being lost
Different tools can then act accordingly. Nothing will
change for g-ir-scanner but this will be important for
the GTK-Doc comment block rewriting tool to prevent
extremely broken input leading to even more broken
output...
|
|
|
|
| |
It's never used...
|
|
|
|
|
| |
...when complaining about multiple comment blocks
documenting the same identifier.
|
|
|
|
|
|
|
|
|
|
| |
Normalize deprecated @Varargs [1] and named __VA_ARGS__ [2]
notations in as single location, add tests. Remove special
casing in maintransformer as it is no longer a special case
(tests/warn/unknown-parameter.h passes).
[1] https://git.gnome.org/browse/gtk-doc/commit/gtkdoc-mkdb.in?id=4c9d4db0e264d403b301dad9be1c290134846d03
[1] https://git.gnome.org/browse/gtk-doc/commit/gtkdoc-mkdb.in?id=55c78181d6ae1606bdf7885e9caed70a484127ec
|
|
|
|
|
|
| |
For example, when creating Gtk-3.0.gir, thousands of instances
of these classes get created. This makes us waste less space
for these instances by not having their __dict__ being created.
|
|
|
|
|
| |
should prevent us from running into locale specific issues
wrt what's whitespace, alpha, numeric, etc.
|
|
|
|
|
| |
The original idea was to only match non breaking space, but
there's really no reason to do things differently than gtkdoc-mkdb.
|
|
|
|
|
| |
Makes it consistent with the parse_comment_blocks() and
_parse_comment_block() methods.
|
|
|
|
|
|
| |
We already have a parse_comment_block() method parsing a single
GTK-Doc comment block so it only seems natural to have a plural
parse_comment_blocks() to go along with that.
|
|
|
|
|
|
| |
Clarify the purpose of what up until now was know as the
AnnotationParser() class, as it does more than just extracting
annotations, it parses the complete GTK-Doc comment block.
|
|
|
|
| |
Simply because they are called description fields on GTK-Doc parts...
|
|
|
|
|
|
|
| |
It serves as a GTK-Doc "field" separator, so delimiter seems
like a better name. This also makes the distinction between the
colon used in property/signal names (which is not a "field"
separator) and the GTK-Doc "field" separator a bit more clear.
|
|
|
|
|
|
|
| |
Makes it easier to understand the difference between
an annotation and an option, which are written as
"(annotation option1=value1 option2=value2 ...)" in
GTK-Doc comment blocks.
|
| |
|
|
|
|
|
|
| |
It's been impossible to have a TAG_RETURNS in GTK-Doc comment
block parameters for a long while now as we transform those
into valid tags in parse_comment_block()...
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Last call sites where removed in 36aa515f1036978ced8d4ffb808260844f7229e0
about 3 years ago.
|
|
|
|
|
| |
Updated from:
https://raw.github.com/jcrocholl/pep8/1.4.6/pep8.py
|
|
|
|
|
| |
This reverts commit ebffefb27ed81b095106056698dd8db9a21fb6f9.
Pushed by mistake
|
|
|
|
|
| |
They should be treated the same as regular volatile specifiers,
not like __attribute__() or __asm__().
|
|
|
|
|
|
|
|
|
| |
Checking for 'cl' in the whole compiler string trips up people who do
CC='gcc --command-with-cl-in-the-name'. We should (probably) only
look at the first argument, although this will break for people doing
CC='ccache cl', but would someone do that?
See: https://bugzilla.gnome.org/show_bug.cgi?id=698090
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The scanner has some logic to compare the filenames specified
on the command line against files it will parse. For the latter,
it uses g_realpath(). With this patch, we also use g_realpath()
on the command line arguments.
This fixes g-i when used inside jhbuild in a gnome-ostree VM,
which has a symbolic link /home -> /sysroot/home. This caused
a realpath mismatch, and then we'd ignore the input source files.
It'd be best to get out of the realpath business entirely...but
a patch to do that seems more likely to break.
https://bugzilla.gnome.org/show_bug.cgi?id=704864
|
| |
|
|
|
|
|
|
|
|
|
| |
This is a very basic sections file generator, and isn't too smart.
It's simply intended to be a base to build docs on, and will be used
if the user doesn't provide a sections file when calling g-ir-doc-tool,
for convenience purposes.
https://bugzilla.gnome.org/show_bug.cgi?id=699856
|
|
|
|
| |
We don't want to emit a warning if there are actually no parameters.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Version in our tree is a wee bit outdated. For example,
later work will introduce an utf8 encoded python source
file which our old pep8.py does not yet understand (yeah,
it really was *that* ancient)...
Updated from:
https://raw.github.com/jcrocholl/pep8/1.4.5/pep8.py
Takes 552c1f1525e37a30376790151c1ba437776682c5,
f941537d1c0a40f0906490ed160db6c79af572d3,
5a4afe2a77d0ff7d9fea13dd93c3304a6ca993de and
a17f157e19bd6792c00321c8020dca5e5a281f45 into account...
https://bugzilla.gnome.org/show_bug.cgi?id=699535
|
|
|
|
|
|
|
| |
instead of silently ignoring parameter names on signals when the
number of parameters doesn't match our expectations.
https://bugzilla.gnome.org/show_bug.cgi?id=697623
|