Skip to content

Commit 5d6d8ed

Browse files
committed
Take changes from new headers
1 parent f5c1dbd commit 5d6d8ed

File tree

3 files changed

+65
-16
lines changed

3 files changed

+65
-16
lines changed

lib/include/Documentation.h.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -433,22 +433,22 @@ export const clang_HTMLTagComment_getAsString = {
433433
*
434434
* @li "word-returns" for the "Returns" word in \\returns paragraph.
435435
*
436-
* Function argument documentation is rendered as a list with arguments
436+
* Function argument documentation is rendered as a \<dl\> list with arguments
437437
* sorted in function prototype order. CSS classes used:
438438
*
439-
* @li "param-name-index-NUMBER" for parameter name ();
439+
* @li "param-name-index-NUMBER" for parameter name (\<dt\>);
440440
*
441-
* @li "param-descr-index-NUMBER" for parameter description ();
441+
* @li "param-descr-index-NUMBER" for parameter description (\<dd\>);
442442
*
443443
* @li "param-name-index-invalid" and "param-descr-index-invalid" are used if
444444
* parameter index is invalid.
445445
*
446-
* Template parameter documentation is rendered as a list with
446+
* Template parameter documentation is rendered as a \<dl\> list with
447447
* parameters sorted in template parameter list order. CSS classes used:
448448
*
449-
* @li "tparam-name-index-NUMBER" for parameter name ();
449+
* @li "tparam-name-index-NUMBER" for parameter name (\<dt\>);
450450
*
451-
* @li "tparam-descr-index-NUMBER" for parameter description ();
451+
* @li "tparam-descr-index-NUMBER" for parameter description (\<dd\>);
452452
*
453453
* @li "tparam-name-index-other" and "tparam-descr-index-other" are used for
454454
* names inside template template parameters;

lib/include/Index.h.ts

Lines changed: 54 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ export const clang_getTranslationUnitSpelling = {
352352
* '-c'
353353
* '-emit-ast'
354354
* '-fsyntax-only'
355-
* '-o <output file>' (both '-o' and '<output file>' are ignored)
355+
* '-o \<output file>' (both '-o' and '\<output file>' are ignored)
356356
*
357357
* @param CIdx The index object with which the translation unit will be
358358
* associated.
@@ -364,7 +364,7 @@ export const clang_getTranslationUnitSpelling = {
364364
* passed to the `clang` executable if it were being invoked out-of-process.
365365
* These command-line options will be parsed and will affect how the translation
366366
* unit is parsed. Note that the following options are ignored: '-c',
367-
* '-emit-ast', '-fsyntax-only' (which is the default), and '-o <output file>'.
367+
* '-emit-ast', '-fsyntax-only' (which is the default), and '-o \<output file>'.
368368
* @param num_unsaved_files the number of unsaved file entries in `unsaved_files.`
369369
* @param unsaved_files the files that have not yet been saved to disk
370370
* but may be required for code completion, including the contents of
@@ -467,7 +467,7 @@ export const clang_parseTranslationUnit = {
467467
* passed to the `clang` executable if it were being invoked out-of-process.
468468
* These command-line options will be parsed and will affect how the translation
469469
* unit is parsed. Note that the following options are ignored: '-c',
470-
* '-emit-ast', '-fsyntax-only' (which is the default), and '-o <output file>'.
470+
* '-emit-ast', '-fsyntax-only' (which is the default), and '-o \<output file>'.
471471
* @param num_command_line_args The number of command-line arguments in
472472
* `command_line_args.`
473473
* @param unsaved_files the files that have not yet been saved to disk
@@ -3114,6 +3114,57 @@ const clang_CXXMethod_isMoveAssignmentOperator = {
31143114
result: unsignedInt,
31153115
} as const;
31163116

3117+
/**
3118+
* Determines if a C++ constructor or conversion function was declared
3119+
* explicit, returning 1 if such is the case and 0 otherwise.
3120+
*
3121+
* Constructors or conversion functions are declared explicit through
3122+
* the use of the explicit specifier.
3123+
*
3124+
* For example, the following constructor and conversion function are
3125+
* not explicit as they lack the explicit specifier:
3126+
*
3127+
* class Foo {
3128+
* Foo();
3129+
* operator int();
3130+
* };
3131+
*
3132+
* While the following constructor and conversion function are
3133+
* explicit as they are declared with the explicit specifier.
3134+
*
3135+
* class Foo {
3136+
* explicit Foo();
3137+
* explicit operator int();
3138+
* };
3139+
*
3140+
* This function will return 0 when given a cursor pointing to one of
3141+
* the former declarations and it will return 1 for a cursor pointing
3142+
* to the latter declarations.
3143+
*
3144+
* The explicit specifier allows the user to specify a
3145+
* conditional compile-time expression whose value decides
3146+
* whether the marked element is explicit or not.
3147+
*
3148+
* For example:
3149+
*
3150+
* constexpr bool foo(int i) { return i % 2 == 0; }
3151+
*
3152+
* class Foo {
3153+
* explicit(foo(1)) Foo();
3154+
* explicit(foo(2)) operator int();
3155+
* }
3156+
*
3157+
* This function will return 0 for the constructor and 1 for
3158+
* the conversion function.
3159+
*/
3160+
// deno-lint-ignore no-unused-vars
3161+
const clang_CXXMethod_isExplicit = {
3162+
parameters: [
3163+
CXCursorT, // C
3164+
],
3165+
result: unsignedInt,
3166+
} as const;
3167+
31173168
/**
31183169
* Determine if a C++ record is abstract, i.e. whether a class or struct
31193170
* has a pure virtual member function.

lib/include/typeDefinitions.ts

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,8 @@ export const double = "f64" as const;
3333
/**
3434
* Error codes returned by libclang routines.
3535
*
36-
* Zero (`CXError_Success`) is the only error code indicating success.
37-
* Other error codes, including not yet assigned non-zero values, indicate
38-
* errors.
36+
* Zero (`CXError_Success`) is the only error code indicating success. Other
37+
* error codes, including not yet assigned non-zero values, indicate errors.
3938
*/
4039
export const enum CXErrorCode {
4140
/**
@@ -66,9 +65,8 @@ export const enum CXErrorCode {
6665
/**
6766
* Error codes returned by libclang routines.
6867
*
69-
* Zero (`CXError_Success`) is the only error code indicating success.
70-
* Other error codes, including not yet assigned non-zero values, indicate
71-
* errors.
68+
* Zero (`CXError_Success`) is the only error code indicating success. Other
69+
* error codes, including not yet assigned non-zero values, indicate errors.
7270
*/
7371
export const CXErrorCodeT = unsignedInt;
7472

@@ -2223,7 +2221,7 @@ export const enum CXNameRefFlags {
22232221
*/
22242222
CXNameRange_WantQualifier = 1,
22252223
/**
2226-
* Include the explicit template arguments, e.g. <int> in x.f<int>,
2224+
* Include the explicit template arguments, e.g. \<int> in x.f<int>,
22272225
* in the range.
22282226
*/
22292227
CXNameRange_WantTemplateArgs = 2,

0 commit comments

Comments
 (0)