Skip to content

Commit a6c1ffc

Browse files
committed
sort the annotations alphabetically
1 parent 2cd1d2f commit a6c1ffc

File tree

2 files changed

+21
-21
lines changed

2 files changed

+21
-21
lines changed

docs/codeql/ql-language-reference/annotations.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ For example, to declare a module ``M`` as private, you could use:
1616
}
1717
1818
Note that some annotations act on an entity itself, whilst others act on a particular *name* for the entity:
19-
- Act on an **entity**: ``abstract``, ``cached``, ``external``, ``transient``, ``override``, ``pragma``, ``language``,
20-
and ``bindingset``
21-
- Act on a **name**: ``deprecated``, ``library``, ``private``, ``final``, and ``query``
19+
- Act on an **entity**: ``abstract``, ``bindingset``, ``cached``, ``external``, ``language``,
20+
``override``, ``pragma``, and ``transient``
21+
- Act on a **name**: ``deprecated``, ``final``, ``library``, ``private``, and ``query``
2222

2323
For example, if you annotate an entity with ``private``, then only that particular name is
2424
private. You could still access that entity under a different name (using an :ref:`alias <aliases>`).

docs/codeql/ql-language-reference/ql-language-specification.rst

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -761,17 +761,17 @@ Various kinds of syntax can have *annotations* applied to them. Annotations are
761761
annotation ::= simpleAnnotation | argsAnnotation
762762

763763
simpleAnnotation ::= "abstract"
764+
| "additional"
764765
| "cached"
765-
| "external"
766+
| "deprecated"
766767
| "extensible"
768+
| "external"
767769
| "final"
768-
| "transient"
769770
| "library"
770-
| "private"
771-
| "deprecated"
772771
| "override"
773-
| "additional"
772+
| "private"
774773
| "query"
774+
| "transient"
775775

776776
argsAnnotation ::= "pragma" "[" ("inline" | "inline_late" | "noinline" | "nomagic" | "noopt" | "assume_small_delta") "]"
777777
| "language" "[" "monotonicAggregates" "]"
@@ -791,28 +791,28 @@ The following table summarizes the syntactic constructs which can be marked with
791791
+================+=========+============+===================+=======================+=========+========+=========+=========+============+
792792
| ``abstract`` | yes | | yes | | | | | | |
793793
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
794+
| ``additional`` | yes | | | yes | | | yes | yes | yes |
795+
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
794796
| ``cached`` | yes | yes | yes | yes | | | yes | | |
795797
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
796-
| ``external`` | | | | yes | | | | | |
798+
| ``deprecated`` | yes | | yes | yes | yes | yes | yes | yes | yes |
797799
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
798800
| ``extensible`` | | | | yes | | | | | |
799801
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
800-
| ``final`` | yes | | yes | | | yes | | (yes) | |
802+
| ``external`` | | | | yes | | | | | |
801803
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
802-
| ``transient`` | | | | yes | | | | | |
804+
| ``final`` | yes | | yes | | | yes | | (yes) | |
803805
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
804806
| ``library`` | (yes) | | | | | | | | |
805807
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
806-
| ``private`` | yes | | yes | yes | yes | yes | yes | yes | yes |
807-
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
808-
| ``deprecated`` | yes | | yes | yes | yes | yes | yes | yes | yes |
809-
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
810808
| ``override`` | | | yes | | | yes | | | |
811809
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
812-
| ``additional`` | yes | | | yes | | | yes | yes | yes |
810+
| ``private`` | yes | | yes | yes | yes | yes | yes | yes | yes |
813811
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
814812
| ``query`` | | | | yes | | | | yes | |
815813
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
814+
| ``transient`` | | | | yes | | | | | |
815+
+----------------+---------+------------+-------------------+-----------------------+---------+--------+---------+---------+------------+
816816

817817
The ``library`` annotation is only usable within a QLL file, not a QL file.
818818
The ``final`` annotation is usable on type aliases, but not on module aliases and predicate aliases.
@@ -2292,17 +2292,17 @@ The complete grammar for QL is as follows:
22922292
annotation ::= simpleAnnotation | argsAnnotation
22932293

22942294
simpleAnnotation ::= "abstract"
2295+
| "additional"
22952296
| "cached"
2296-
| "external"
2297+
| "deprecated"
22972298
| "extensible"
2299+
| "external"
22982300
| "final"
2299-
| "transient"
23002301
| "library"
2301-
| "private"
2302-
| "deprecated"
23032302
| "override"
2304-
| "additional"
2303+
| "private"
23052304
| "query"
2305+
| "transient"
23062306

23072307
argsAnnotation ::= "pragma" "[" ("inline" | "inline_late" | "noinline" | "nomagic" | "noopt" | "assume_small_delta") "]"
23082308
| "language" "[" "monotonicAggregates" "]"

0 commit comments

Comments
 (0)