| OLD | NEW |
| (Empty) | |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. |
| 4 // |
| 5 // This file has been automatically generated. Please do not edit it manually. |
| 6 // To regenerate the file, use the script "pkg/analyzer/tool/generate_files". |
| 7 |
| 8 |
| 9 /** |
| 10 * Enum used to indicate the kind of a name in index. |
| 11 */ |
| 12 enum IndexNameKind : byte { |
| 13 /** |
| 14 * A top-level element. |
| 15 */ |
| 16 topLevel, |
| 17 |
| 18 /** |
| 19 * A class member. |
| 20 */ |
| 21 classMember |
| 22 } |
| 23 |
| 24 /** |
| 25 * Enum used to indicate the kind of an index relation. |
| 26 */ |
| 27 enum IndexRelationKind : byte { |
| 28 /** |
| 29 * Left: class. |
| 30 * Is ancestor of (is extended or implemented, directly or indirectly). |
| 31 * Right: other class declaration. |
| 32 */ |
| 33 IS_ANCESTOR_OF, |
| 34 |
| 35 /** |
| 36 * Left: class. |
| 37 * Is extended by. |
| 38 * Right: other class declaration. |
| 39 */ |
| 40 IS_EXTENDED_BY, |
| 41 |
| 42 /** |
| 43 * Left: class. |
| 44 * Is implemented by. |
| 45 * Right: other class declaration. |
| 46 */ |
| 47 IS_IMPLEMENTED_BY, |
| 48 |
| 49 /** |
| 50 * Left: class. |
| 51 * Is mixed into. |
| 52 * Right: other class declaration. |
| 53 */ |
| 54 IS_MIXED_IN_BY, |
| 55 |
| 56 /** |
| 57 * Left: method, property accessor, function, variable. |
| 58 * Is invoked at. |
| 59 * Right: location. |
| 60 */ |
| 61 IS_INVOKED_BY, |
| 62 |
| 63 /** |
| 64 * Left: any element. |
| 65 * Is referenced (and not invoked, read/written) at. |
| 66 * Right: location. |
| 67 */ |
| 68 IS_REFERENCED_BY, |
| 69 |
| 70 /** |
| 71 * Left: unresolved member name. |
| 72 * Is read at. |
| 73 * Right: location. |
| 74 */ |
| 75 IS_READ_BY, |
| 76 |
| 77 /** |
| 78 * Left: unresolved member name. |
| 79 * Is both read and written at. |
| 80 * Right: location. |
| 81 */ |
| 82 IS_READ_WRITTEN_BY, |
| 83 |
| 84 /** |
| 85 * Left: unresolved member name. |
| 86 * Is written at. |
| 87 * Right: location. |
| 88 */ |
| 89 IS_WRITTEN_BY |
| 90 } |
| 91 |
| 92 /** |
| 93 * When we need to reference a synthetic element in [PackageIndex] we use a |
| 94 * value of this enum to specify which kind of the synthetic element we |
| 95 * actually reference. |
| 96 */ |
| 97 enum IndexSyntheticElementKind : byte { |
| 98 /** |
| 99 * Not a synthetic element. |
| 100 */ |
| 101 notSynthetic, |
| 102 |
| 103 /** |
| 104 * The unnamed synthetic constructor a class element. |
| 105 */ |
| 106 constructor, |
| 107 |
| 108 /** |
| 109 * The synthetic field element. |
| 110 */ |
| 111 field, |
| 112 |
| 113 /** |
| 114 * The synthetic getter of a property introducing element. |
| 115 */ |
| 116 getter, |
| 117 |
| 118 /** |
| 119 * The synthetic setter of a property introducing element. |
| 120 */ |
| 121 setter, |
| 122 |
| 123 /** |
| 124 * The synthetic top-level variable element. |
| 125 */ |
| 126 topLevelVariable, |
| 127 |
| 128 /** |
| 129 * The synthetic `loadLibrary` element. |
| 130 */ |
| 131 loadLibrary, |
| 132 |
| 133 /** |
| 134 * The synthetic `index` getter of an enum. |
| 135 */ |
| 136 enumIndex, |
| 137 |
| 138 /** |
| 139 * The synthetic `values` getter of an enum. |
| 140 */ |
| 141 enumValues, |
| 142 |
| 143 /** |
| 144 * The containing unit itself. |
| 145 */ |
| 146 unit |
| 147 } |
| 148 |
| 149 /** |
| 150 * Enum used to indicate the kind of entity referred to by a |
| 151 * [LinkedReference]. |
| 152 */ |
| 153 enum ReferenceKind : byte { |
| 154 /** |
| 155 * The entity is a class or enum. |
| 156 */ |
| 157 classOrEnum, |
| 158 |
| 159 /** |
| 160 * The entity is a constructor. |
| 161 */ |
| 162 constructor, |
| 163 |
| 164 /** |
| 165 * The entity is a getter or setter inside a class. Note: this is used in |
| 166 * the case where a constant refers to a static const declared inside a |
| 167 * class. |
| 168 */ |
| 169 propertyAccessor, |
| 170 |
| 171 /** |
| 172 * The entity is a method. |
| 173 */ |
| 174 method, |
| 175 |
| 176 /** |
| 177 * The entity is a typedef. |
| 178 */ |
| 179 typedef, |
| 180 |
| 181 /** |
| 182 * The entity is a local function. |
| 183 */ |
| 184 function, |
| 185 |
| 186 /** |
| 187 * The entity is a local variable. |
| 188 */ |
| 189 variable, |
| 190 |
| 191 /** |
| 192 * The entity is a top level function. |
| 193 */ |
| 194 topLevelFunction, |
| 195 |
| 196 /** |
| 197 * The entity is a top level getter or setter. |
| 198 */ |
| 199 topLevelPropertyAccessor, |
| 200 |
| 201 /** |
| 202 * The entity is a prefix. |
| 203 */ |
| 204 prefix, |
| 205 |
| 206 /** |
| 207 * The entity being referred to does not exist. |
| 208 */ |
| 209 unresolved |
| 210 } |
| 211 |
| 212 /** |
| 213 * Enum representing the various kinds of operations which may be performed to |
| 214 * produce a constant value. These options are assumed to execute in the |
| 215 * context of a stack which is initially empty. |
| 216 */ |
| 217 enum UnlinkedConstOperation : byte { |
| 218 /** |
| 219 * Push the next value from [UnlinkedConst.ints] (a 32-bit unsigned integer) |
| 220 * onto the stack. |
| 221 * |
| 222 * Note that Dart supports integers larger than 32 bits; these are |
| 223 * represented by composing 32-bit values using the [pushLongInt] operation. |
| 224 */ |
| 225 pushInt, |
| 226 |
| 227 /** |
| 228 * Get the number of components from [UnlinkedConst.ints], then do this number |
| 229 * of times the following operations: multiple the current value by 2^32, "or" |
| 230 * it with the next value in [UnlinkedConst.ints]. The initial value is zero. |
| 231 * Push the result into the stack. |
| 232 */ |
| 233 pushLongInt, |
| 234 |
| 235 /** |
| 236 * Push the next value from [UnlinkedConst.doubles] (a double precision |
| 237 * floating point value) onto the stack. |
| 238 */ |
| 239 pushDouble, |
| 240 |
| 241 /** |
| 242 * Push the constant `true` onto the stack. |
| 243 */ |
| 244 pushTrue, |
| 245 |
| 246 /** |
| 247 * Push the constant `false` onto the stack. |
| 248 */ |
| 249 pushFalse, |
| 250 |
| 251 /** |
| 252 * Push the next value from [UnlinkedConst.strings] onto the stack. |
| 253 */ |
| 254 pushString, |
| 255 |
| 256 /** |
| 257 * Pop the top n values from the stack (where n is obtained from |
| 258 * [UnlinkedConst.ints]), convert them to strings (if they aren't already), |
| 259 * concatenate them into a single string, and push it back onto the stack. |
| 260 * |
| 261 * This operation is used to represent constants whose value is a literal |
| 262 * string containing string interpolations. |
| 263 */ |
| 264 concatenate, |
| 265 |
| 266 /** |
| 267 * Get the next value from [UnlinkedConst.strings], convert it to a symbol, |
| 268 * and push it onto the stack. |
| 269 */ |
| 270 makeSymbol, |
| 271 |
| 272 /** |
| 273 * Push the constant `null` onto the stack. |
| 274 */ |
| 275 pushNull, |
| 276 |
| 277 /** |
| 278 * Push the value of the function parameter with the name obtained from |
| 279 * [UnlinkedConst.strings]. |
| 280 */ |
| 281 pushParameter, |
| 282 |
| 283 /** |
| 284 * Evaluate a (potentially qualified) identifier expression and push the |
| 285 * resulting value onto the stack. The identifier to be evaluated is |
| 286 * obtained from [UnlinkedConst.references]. |
| 287 * |
| 288 * This operation is used to represent the following kinds of constants |
| 289 * (which are indistinguishable from an unresolved AST alone): |
| 290 * |
| 291 * - A qualified reference to a static constant variable (e.g. `C.v`, where |
| 292 * C is a class and `v` is a constant static variable in `C`). |
| 293 * - An identifier expression referring to a constant variable. |
| 294 * - A simple or qualified identifier denoting a class or type alias. |
| 295 * - A simple or qualified identifier denoting a top-level function or a |
| 296 * static method. |
| 297 */ |
| 298 pushReference, |
| 299 |
| 300 /** |
| 301 * Pop the top value from the stack, extract the value of the property with |
| 302 * the name obtained from [UnlinkedConst.strings], and push the result back |
| 303 * onto the stack. |
| 304 */ |
| 305 extractProperty, |
| 306 |
| 307 /** |
| 308 * Pop the top `n` values from the stack (where `n` is obtained from |
| 309 * [UnlinkedConst.ints]) into a list (filled from the end) and take the next |
| 310 * `n` values from [UnlinkedConst.strings] and use the lists of names and |
| 311 * values to create named arguments. Then pop the top `m` values from the |
| 312 * stack (where `m` is obtained from [UnlinkedConst.ints]) into a list (filled |
| 313 * from the end) and use them as positional arguments. Use the lists of |
| 314 * positional and names arguments to invoke a constant constructor obtained |
| 315 * from [UnlinkedConst.references], and push the resulting value back onto the |
| 316 * stack. |
| 317 * |
| 318 * Note that for an invocation of the form `const a.b(...)` (where no type |
| 319 * arguments are specified), it is impossible to tell from the unresolved AST |
| 320 * alone whether `a` is a class name and `b` is a constructor name, or `a` is |
| 321 * a prefix name and `b` is a class name. For consistency between AST based |
| 322 * and elements based summaries, references to default constructors are always |
| 323 * recorded as references to corresponding classes. |
| 324 */ |
| 325 invokeConstructor, |
| 326 |
| 327 /** |
| 328 * Pop the top n values from the stack (where n is obtained from |
| 329 * [UnlinkedConst.ints]), place them in a [List], and push the result back |
| 330 * onto the stack. The type parameter for the [List] is implicitly `dynamic`. |
| 331 */ |
| 332 makeUntypedList, |
| 333 |
| 334 /** |
| 335 * Pop the top 2*n values from the stack (where n is obtained from |
| 336 * [UnlinkedConst.ints]), interpret them as key/value pairs, place them in a |
| 337 * [Map], and push the result back onto the stack. The two type parameters |
| 338 * for the [Map] are implicitly `dynamic`. |
| 339 */ |
| 340 makeUntypedMap, |
| 341 |
| 342 /** |
| 343 * Pop the top n values from the stack (where n is obtained from |
| 344 * [UnlinkedConst.ints]), place them in a [List], and push the result back |
| 345 * onto the stack. The type parameter for the [List] is obtained from |
| 346 * [UnlinkedConst.references]. |
| 347 */ |
| 348 makeTypedList, |
| 349 |
| 350 /** |
| 351 * Pop the top 2*n values from the stack (where n is obtained from |
| 352 * [UnlinkedConst.ints]), interpret them as key/value pairs, place them in a |
| 353 * [Map], and push the result back onto the stack. The two type parameters fo
r |
| 354 * the [Map] are obtained from [UnlinkedConst.references]. |
| 355 */ |
| 356 makeTypedMap, |
| 357 |
| 358 /** |
| 359 * Pop the top 2 values from the stack, evaluate `v1 == v2`, and push the |
| 360 * result back onto the stack. |
| 361 */ |
| 362 equal, |
| 363 |
| 364 /** |
| 365 * Pop the top 2 values from the stack, evaluate `v1 != v2`, and push the |
| 366 * result back onto the stack. |
| 367 */ |
| 368 notEqual, |
| 369 |
| 370 /** |
| 371 * Pop the top value from the stack, compute its boolean negation, and push |
| 372 * the result back onto the stack. |
| 373 */ |
| 374 not, |
| 375 |
| 376 /** |
| 377 * Pop the top 2 values from the stack, compute `v1 && v2`, and push the |
| 378 * result back onto the stack. |
| 379 */ |
| 380 and, |
| 381 |
| 382 /** |
| 383 * Pop the top 2 values from the stack, compute `v1 || v2`, and push the |
| 384 * result back onto the stack. |
| 385 */ |
| 386 or, |
| 387 |
| 388 /** |
| 389 * Pop the top value from the stack, compute its integer complement, and push |
| 390 * the result back onto the stack. |
| 391 */ |
| 392 complement, |
| 393 |
| 394 /** |
| 395 * Pop the top 2 values from the stack, compute `v1 ^ v2`, and push the |
| 396 * result back onto the stack. |
| 397 */ |
| 398 bitXor, |
| 399 |
| 400 /** |
| 401 * Pop the top 2 values from the stack, compute `v1 & v2`, and push the |
| 402 * result back onto the stack. |
| 403 */ |
| 404 bitAnd, |
| 405 |
| 406 /** |
| 407 * Pop the top 2 values from the stack, compute `v1 | v2`, and push the |
| 408 * result back onto the stack. |
| 409 */ |
| 410 bitOr, |
| 411 |
| 412 /** |
| 413 * Pop the top 2 values from the stack, compute `v1 >> v2`, and push the |
| 414 * result back onto the stack. |
| 415 */ |
| 416 bitShiftRight, |
| 417 |
| 418 /** |
| 419 * Pop the top 2 values from the stack, compute `v1 << v2`, and push the |
| 420 * result back onto the stack. |
| 421 */ |
| 422 bitShiftLeft, |
| 423 |
| 424 /** |
| 425 * Pop the top 2 values from the stack, compute `v1 + v2`, and push the |
| 426 * result back onto the stack. |
| 427 */ |
| 428 add, |
| 429 |
| 430 /** |
| 431 * Pop the top value from the stack, compute its integer negation, and push |
| 432 * the result back onto the stack. |
| 433 */ |
| 434 negate, |
| 435 |
| 436 /** |
| 437 * Pop the top 2 values from the stack, compute `v1 - v2`, and push the |
| 438 * result back onto the stack. |
| 439 */ |
| 440 subtract, |
| 441 |
| 442 /** |
| 443 * Pop the top 2 values from the stack, compute `v1 * v2`, and push the |
| 444 * result back onto the stack. |
| 445 */ |
| 446 multiply, |
| 447 |
| 448 /** |
| 449 * Pop the top 2 values from the stack, compute `v1 / v2`, and push the |
| 450 * result back onto the stack. |
| 451 */ |
| 452 divide, |
| 453 |
| 454 /** |
| 455 * Pop the top 2 values from the stack, compute `v1 ~/ v2`, and push the |
| 456 * result back onto the stack. |
| 457 */ |
| 458 floorDivide, |
| 459 |
| 460 /** |
| 461 * Pop the top 2 values from the stack, compute `v1 > v2`, and push the |
| 462 * result back onto the stack. |
| 463 */ |
| 464 greater, |
| 465 |
| 466 /** |
| 467 * Pop the top 2 values from the stack, compute `v1 < v2`, and push the |
| 468 * result back onto the stack. |
| 469 */ |
| 470 less, |
| 471 |
| 472 /** |
| 473 * Pop the top 2 values from the stack, compute `v1 >= v2`, and push the |
| 474 * result back onto the stack. |
| 475 */ |
| 476 greaterEqual, |
| 477 |
| 478 /** |
| 479 * Pop the top 2 values from the stack, compute `v1 <= v2`, and push the |
| 480 * result back onto the stack. |
| 481 */ |
| 482 lessEqual, |
| 483 |
| 484 /** |
| 485 * Pop the top 2 values from the stack, compute `v1 % v2`, and push the |
| 486 * result back onto the stack. |
| 487 */ |
| 488 modulo, |
| 489 |
| 490 /** |
| 491 * Pop the top 3 values from the stack, compute `v1 ? v2 : v3`, and push the |
| 492 * result back onto the stack. |
| 493 */ |
| 494 conditional, |
| 495 |
| 496 /** |
| 497 * Pop from the stack `value` and get the next `target` reference from |
| 498 * [UnlinkedConst.references] - a top-level variable (prefixed or not), an |
| 499 * assignable field of a class (prefixed or not), or a sequence of getters |
| 500 * ending with an assignable property `a.b.b.c.d.e`. In general `a.b` cannot |
| 501 * not be distinguished between: `a` is a prefix and `b` is a top-level |
| 502 * variable; or `a` is an object and `b` is the name of a property. Perform |
| 503 * `reference op= value` where `op` is the next assignment operator from |
| 504 * [UnlinkedConst.assignmentOperators]. Push `value` back into the stack. |
| 505 * |
| 506 * If the assignment operator is a prefix/postfix increment/decrement, then |
| 507 * `value` is not present in the stack, so it should not be popped and the |
| 508 * corresponding value of the `target` after/before update is pushed into the |
| 509 * stack instead. |
| 510 */ |
| 511 assignToRef, |
| 512 |
| 513 /** |
| 514 * Pop from the stack `target` and `value`. Get the name of the property from |
| 515 * `UnlinkedConst.strings` and assign the `value` to the named property of the |
| 516 * `target`. This operation is used when we know that the `target` is an |
| 517 * object reference expression, e.g. `new Foo().a.b.c` or `a.b[0].c.d`. |
| 518 * Perform `target.property op= value` where `op` is the next assignment |
| 519 * operator from [UnlinkedConst.assignmentOperators]. Push `value` back into |
| 520 * the stack. |
| 521 * |
| 522 * If the assignment operator is a prefix/postfix increment/decrement, then |
| 523 * `value` is not present in the stack, so it should not be popped and the |
| 524 * corresponding value of the `target` after/before update is pushed into the |
| 525 * stack instead. |
| 526 */ |
| 527 assignToProperty, |
| 528 |
| 529 /** |
| 530 * Pop from the stack `index`, `target` and `value`. Perform |
| 531 * `target[index] op= value` where `op` is the next assignment operator from |
| 532 * [UnlinkedConst.assignmentOperators]. Push `value` back into the stack. |
| 533 * |
| 534 * If the assignment operator is a prefix/postfix increment/decrement, then |
| 535 * `value` is not present in the stack, so it should not be popped and the |
| 536 * corresponding value of the `target` after/before update is pushed into the |
| 537 * stack instead. |
| 538 */ |
| 539 assignToIndex, |
| 540 |
| 541 /** |
| 542 * Pop from the stack `index` and `target`. Push into the stack the result |
| 543 * of evaluation of `target[index]`. |
| 544 */ |
| 545 extractIndex, |
| 546 |
| 547 /** |
| 548 * Pop the top `n` values from the stack (where `n` is obtained from |
| 549 * [UnlinkedConst.ints]) into a list (filled from the end) and take the next |
| 550 * `n` values from [UnlinkedConst.strings] and use the lists of names and |
| 551 * values to create named arguments. Then pop the top `m` values from the |
| 552 * stack (where `m` is obtained from [UnlinkedConst.ints]) into a list (filled |
| 553 * from the end) and use them as positional arguments. Use the lists of |
| 554 * positional and names arguments to invoke a method (or a function) with |
| 555 * the reference from [UnlinkedConst.references]. If `k` is nonzero (where |
| 556 * `k` is obtained from [UnlinkedConst.ints]), obtain `k` type arguments from |
| 557 * [UnlinkedConst.references] and use them as generic type arguments for the |
| 558 * aforementioned method or function. Push the result of the invocation onto |
| 559 * the stack. |
| 560 * |
| 561 * In general `a.b` cannot not be distinguished between: `a` is a prefix and |
| 562 * `b` is a top-level function; or `a` is an object and `b` is the name of a |
| 563 * method. This operation should be used for a sequence of identifiers |
| 564 * `a.b.b.c.d.e` ending with an invokable result. |
| 565 */ |
| 566 invokeMethodRef, |
| 567 |
| 568 /** |
| 569 * Pop the top `n` values from the stack (where `n` is obtained from |
| 570 * [UnlinkedConst.ints]) into a list (filled from the end) and take the next |
| 571 * `n` values from [UnlinkedConst.strings] and use the lists of names and |
| 572 * values to create named arguments. Then pop the top `m` values from the |
| 573 * stack (where `m` is obtained from [UnlinkedConst.ints]) into a list (filled |
| 574 * from the end) and use them as positional arguments. Use the lists of |
| 575 * positional and names arguments to invoke the method with the name from |
| 576 * [UnlinkedConst.strings] of the target popped from the stack. If `k` is |
| 577 * nonzero (where `k` is obtained from [UnlinkedConst.ints]), obtain `k` type |
| 578 * arguments from [UnlinkedConst.references] and use them as generic type |
| 579 * arguments for the aforementioned method. Push the result of the |
| 580 * invocation onto the stack. |
| 581 * |
| 582 * This operation should be used for invocation of a method invocation |
| 583 * where `target` is known to be an object instance. |
| 584 */ |
| 585 invokeMethod, |
| 586 |
| 587 /** |
| 588 * Begin a new cascade section. Duplicate the top value of the stack. |
| 589 */ |
| 590 cascadeSectionBegin, |
| 591 |
| 592 /** |
| 593 * End a new cascade section. Pop the top value from the stack and throw it |
| 594 * away. |
| 595 */ |
| 596 cascadeSectionEnd, |
| 597 |
| 598 /** |
| 599 * Pop the top value from the stack and cast it to the type with reference |
| 600 * from [UnlinkedConst.references], push the result into the stack. |
| 601 */ |
| 602 typeCast, |
| 603 |
| 604 /** |
| 605 * Pop the top value from the stack and check whether it is a subclass of the |
| 606 * type with reference from [UnlinkedConst.references], push the result into |
| 607 * the stack. |
| 608 */ |
| 609 typeCheck, |
| 610 |
| 611 /** |
| 612 * Pop the top value from the stack and raise an exception with this value. |
| 613 */ |
| 614 throwException, |
| 615 |
| 616 /** |
| 617 * Obtain two values `n` and `m` from [UnlinkedConst.ints]. Then, starting at |
| 618 * the executable element for the expression being evaluated, if n > 0, pop to |
| 619 * the nth enclosing function element. Then, push the mth local function of |
| 620 * that element onto the stack. |
| 621 */ |
| 622 pushLocalFunctionReference |
| 623 } |
| 624 |
| 625 /** |
| 626 * Enum used to indicate the kind of an constructor initializer. |
| 627 */ |
| 628 enum UnlinkedConstructorInitializerKind : byte { |
| 629 /** |
| 630 * Initialization of a field. |
| 631 */ |
| 632 field, |
| 633 |
| 634 /** |
| 635 * Invocation of a constructor in the same class. |
| 636 */ |
| 637 thisInvocation, |
| 638 |
| 639 /** |
| 640 * Invocation of a superclass' constructor. |
| 641 */ |
| 642 superInvocation |
| 643 } |
| 644 |
| 645 /** |
| 646 * Enum used to indicate the kind of an executable. |
| 647 */ |
| 648 enum UnlinkedExecutableKind : byte { |
| 649 /** |
| 650 * Executable is a function or method. |
| 651 */ |
| 652 functionOrMethod, |
| 653 |
| 654 /** |
| 655 * Executable is a getter. |
| 656 */ |
| 657 getter, |
| 658 |
| 659 /** |
| 660 * Executable is a setter. |
| 661 */ |
| 662 setter, |
| 663 |
| 664 /** |
| 665 * Executable is a constructor. |
| 666 */ |
| 667 constructor |
| 668 } |
| 669 |
| 670 /** |
| 671 * Enum representing the various kinds of assignment operations combined |
| 672 * with: |
| 673 * [UnlinkedConstOperation.assignToRef], |
| 674 * [UnlinkedConstOperation.assignToProperty], |
| 675 * [UnlinkedConstOperation.assignToIndex]. |
| 676 */ |
| 677 enum UnlinkedExprAssignOperator : byte { |
| 678 /** |
| 679 * Perform simple assignment `target = operand`. |
| 680 */ |
| 681 assign, |
| 682 |
| 683 /** |
| 684 * Perform `target ??= operand`. |
| 685 */ |
| 686 ifNull, |
| 687 |
| 688 /** |
| 689 * Perform `target *= operand`. |
| 690 */ |
| 691 multiply, |
| 692 |
| 693 /** |
| 694 * Perform `target /= operand`. |
| 695 */ |
| 696 divide, |
| 697 |
| 698 /** |
| 699 * Perform `target ~/= operand`. |
| 700 */ |
| 701 floorDivide, |
| 702 |
| 703 /** |
| 704 * Perform `target %= operand`. |
| 705 */ |
| 706 modulo, |
| 707 |
| 708 /** |
| 709 * Perform `target += operand`. |
| 710 */ |
| 711 plus, |
| 712 |
| 713 /** |
| 714 * Perform `target -= operand`. |
| 715 */ |
| 716 minus, |
| 717 |
| 718 /** |
| 719 * Perform `target <<= operand`. |
| 720 */ |
| 721 shiftLeft, |
| 722 |
| 723 /** |
| 724 * Perform `target >>= operand`. |
| 725 */ |
| 726 shiftRight, |
| 727 |
| 728 /** |
| 729 * Perform `target &= operand`. |
| 730 */ |
| 731 bitAnd, |
| 732 |
| 733 /** |
| 734 * Perform `target ^= operand`. |
| 735 */ |
| 736 bitXor, |
| 737 |
| 738 /** |
| 739 * Perform `target |= operand`. |
| 740 */ |
| 741 bitOr, |
| 742 |
| 743 /** |
| 744 * Perform `++target`. |
| 745 */ |
| 746 prefixIncrement, |
| 747 |
| 748 /** |
| 749 * Perform `--target`. |
| 750 */ |
| 751 prefixDecrement, |
| 752 |
| 753 /** |
| 754 * Perform `target++`. |
| 755 */ |
| 756 postfixIncrement, |
| 757 |
| 758 /** |
| 759 * Perform `target++`. |
| 760 */ |
| 761 postfixDecrement |
| 762 } |
| 763 |
| 764 /** |
| 765 * Enum used to indicate the kind of a parameter. |
| 766 */ |
| 767 enum UnlinkedParamKind : byte { |
| 768 /** |
| 769 * Parameter is required. |
| 770 */ |
| 771 required, |
| 772 |
| 773 /** |
| 774 * Parameter is positional optional (enclosed in `[]`) |
| 775 */ |
| 776 positional, |
| 777 |
| 778 /** |
| 779 * Parameter is named optional (enclosed in `{}`) |
| 780 */ |
| 781 named |
| 782 } |
| 783 |
| 784 /** |
| 785 * Information about an element code range. |
| 786 */ |
| 787 table CodeRange { |
| 788 /** |
| 789 * Length of the element code. |
| 790 */ |
| 791 length:uint (id: 1); |
| 792 |
| 793 /** |
| 794 * Offset of the element code relative to the beginning of the file. |
| 795 */ |
| 796 offset:uint (id: 0); |
| 797 } |
| 798 |
| 799 /** |
| 800 * Summary information about a reference to a an entity such as a type, top |
| 801 * level executable, or executable within a class. |
| 802 */ |
| 803 table EntityRef { |
| 804 /** |
| 805 * If this is a reference to a function type implicitly defined by a |
| 806 * function-typed parameter, a list of zero-based indices indicating the path |
| 807 * from the entity referred to by [reference] to the appropriate type |
| 808 * parameter. Otherwise the empty list. |
| 809 * |
| 810 * If there are N indices in this list, then the entity being referred to is |
| 811 * the function type implicitly defined by a function-typed parameter of a |
| 812 * function-typed parameter, to N levels of nesting. The first index in the |
| 813 * list refers to the outermost level of nesting; for example if [reference] |
| 814 * refers to the entity defined by: |
| 815 * |
| 816 * void f(x, void g(y, z, int h(String w))) { ... } |
| 817 * |
| 818 * Then to refer to the function type implicitly defined by parameter `h` |
| 819 * (which is parameter 2 of parameter 1 of `f`), then |
| 820 * [implicitFunctionTypeIndices] should be [1, 2]. |
| 821 * |
| 822 * Note that if the entity being referred to is a generic method inside a |
| 823 * generic class, then the type arguments in [typeArguments] are applied |
| 824 * first to the class and then to the method. |
| 825 */ |
| 826 implicitFunctionTypeIndices:[uint] (id: 4); |
| 827 |
| 828 /** |
| 829 * If this is a reference to a type parameter, one-based index into the list |
| 830 * of [UnlinkedTypeParam]s currently in effect. Indexing is done using De |
| 831 * Bruijn index conventions; that is, innermost parameters come first, and |
| 832 * if a class or method has multiple parameters, they are indexed from right |
| 833 * to left. So for instance, if the enclosing declaration is |
| 834 * |
| 835 * class C<T,U> { |
| 836 * m<V,W> { |
| 837 * ... |
| 838 * } |
| 839 * } |
| 840 * |
| 841 * Then [paramReference] values of 1, 2, 3, and 4 represent W, V, U, and T, |
| 842 * respectively. |
| 843 * |
| 844 * If the type being referred to is not a type parameter, [paramReference] is |
| 845 * zero. |
| 846 */ |
| 847 paramReference:uint (id: 3); |
| 848 |
| 849 /** |
| 850 * Index into [UnlinkedUnit.references] for the entity being referred to, or |
| 851 * zero if this is a reference to a type parameter. |
| 852 */ |
| 853 reference:uint (id: 0); |
| 854 |
| 855 /** |
| 856 * If this [EntityRef] is contained within [LinkedUnit.types], slot id (which |
| 857 * is unique within the compilation unit) identifying the target of type |
| 858 * propagation or type inference with which this [EntityRef] is associated. |
| 859 * |
| 860 * Otherwise zero. |
| 861 */ |
| 862 slot:uint (id: 2); |
| 863 |
| 864 /** |
| 865 * If this [EntityRef] is a reference to a function type whose |
| 866 * [FunctionElement] is not in any library (e.g. a function type that was |
| 867 * synthesized by a LUB computation), the function parameters. Otherwise |
| 868 * empty. |
| 869 */ |
| 870 syntheticParams:[UnlinkedParam] (id: 6); |
| 871 |
| 872 /** |
| 873 * If this [EntityRef] is a reference to a function type whose |
| 874 * [FunctionElement] is not in any library (e.g. a function type that was |
| 875 * synthesized by a LUB computation), the return type of the function. |
| 876 * Otherwise `null`. |
| 877 */ |
| 878 syntheticReturnType:EntityRef (id: 5); |
| 879 |
| 880 /** |
| 881 * If this is an instantiation of a generic type or generic executable, the |
| 882 * type arguments used to instantiate it (if any). |
| 883 */ |
| 884 typeArguments:[EntityRef] (id: 1); |
| 885 } |
| 886 |
| 887 /** |
| 888 * Information about a dependency that exists between one library and another |
| 889 * due to an "import" declaration. |
| 890 */ |
| 891 table LinkedDependency { |
| 892 /** |
| 893 * URI for the compilation units listed in the library's `part` declarations. |
| 894 * These URIs are relative to the importing library. |
| 895 */ |
| 896 parts:[string] (id: 1); |
| 897 |
| 898 /** |
| 899 * The relative URI of the dependent library. This URI is relative to the |
| 900 * importing library, even if there are intervening `export` declarations. |
| 901 * So, for example, if `a.dart` imports `b/c.dart` and `b/c.dart` exports |
| 902 * `d/e.dart`, the URI listed for `a.dart`'s dependency on `e.dart` will be |
| 903 * `b/d/e.dart`. |
| 904 */ |
| 905 uri:string (id: 0); |
| 906 } |
| 907 |
| 908 /** |
| 909 * Information about a single name in the export namespace of the library that |
| 910 * is not in the public namespace. |
| 911 */ |
| 912 table LinkedExportName { |
| 913 /** |
| 914 * Index into [LinkedLibrary.dependencies] for the library in which the |
| 915 * entity is defined. |
| 916 */ |
| 917 dependency:uint (id: 0); |
| 918 |
| 919 /** |
| 920 * The kind of the entity being referred to. |
| 921 */ |
| 922 kind:ReferenceKind (id: 3); |
| 923 |
| 924 /** |
| 925 * Name of the exported entity. For an exported setter, this name includes |
| 926 * the trailing '='. |
| 927 */ |
| 928 name:string (id: 1); |
| 929 |
| 930 /** |
| 931 * Integer index indicating which unit in the exported library contains the |
| 932 * definition of the entity. As with indices into [LinkedLibrary.units], |
| 933 * zero represents the defining compilation unit, and nonzero values |
| 934 * represent parts in the order of the corresponding `part` declarations. |
| 935 */ |
| 936 unit:uint (id: 2); |
| 937 } |
| 938 |
| 939 /** |
| 940 * Linked summary of a library. |
| 941 */ |
| 942 table LinkedLibrary { |
| 943 /** |
| 944 * The libraries that this library depends on (either via an explicit import |
| 945 * statement or via the implicit dependencies on `dart:core` and |
| 946 * `dart:async`). The first element of this array is a pseudo-dependency |
| 947 * representing the library itself (it is also used for `dynamic` and |
| 948 * `void`). This is followed by elements representing "prelinked" |
| 949 * dependencies (direct imports and the transitive closure of exports). |
| 950 * After the prelinked dependencies are elements representing "linked" |
| 951 * dependencies. |
| 952 * |
| 953 * A library is only included as a "linked" dependency if it is a true |
| 954 * dependency (e.g. a propagated or inferred type or constant value |
| 955 * implicitly refers to an element declared in the library) or |
| 956 * anti-dependency (e.g. the result of type propagation or type inference |
| 957 * depends on the lack of a certain declaration in the library). |
| 958 */ |
| 959 dependencies:[LinkedDependency] (id: 0); |
| 960 |
| 961 /** |
| 962 * For each export in [UnlinkedUnit.exports], an index into [dependencies] |
| 963 * of the library being exported. |
| 964 */ |
| 965 exportDependencies:[uint] (id: 6); |
| 966 |
| 967 /** |
| 968 * Information about entities in the export namespace of the library that are |
| 969 * not in the public namespace of the library (that is, entities that are |
| 970 * brought into the namespace via `export` directives). |
| 971 * |
| 972 * Sorted by name. |
| 973 */ |
| 974 exportNames:[LinkedExportName] (id: 4); |
| 975 |
| 976 /** |
| 977 * Indicates whether this library was summarized in "fallback mode". If |
| 978 * true, all other fields in the data structure have their default values. |
| 979 */ |
| 980 fallbackMode:bool (id: 5); |
| 981 |
| 982 /** |
| 983 * For each import in [UnlinkedUnit.imports], an index into [dependencies] |
| 984 * of the library being imported. |
| 985 */ |
| 986 importDependencies:[uint] (id: 1); |
| 987 |
| 988 /** |
| 989 * The number of elements in [dependencies] which are not "linked" |
| 990 * dependencies (that is, the number of libraries in the direct imports plus |
| 991 * the transitive closure of exports, plus the library itself). |
| 992 */ |
| 993 numPrelinkedDependencies:uint (id: 2); |
| 994 |
| 995 /** |
| 996 * The linked summary of all the compilation units constituting the |
| 997 * library. The summary of the defining compilation unit is listed first, |
| 998 * followed by the summary of each part, in the order of the `part` |
| 999 * declarations in the defining compilation unit. |
| 1000 */ |
| 1001 units:[LinkedUnit] (id: 3); |
| 1002 } |
| 1003 |
| 1004 /** |
| 1005 * Information about the resolution of an [UnlinkedReference]. |
| 1006 */ |
| 1007 table LinkedReference { |
| 1008 /** |
| 1009 * If this [LinkedReference] doesn't have an associated [UnlinkedReference], |
| 1010 * and the entity being referred to is contained within another entity, index |
| 1011 * of the containing entity. This behaves similarly to |
| 1012 * [UnlinkedReference.prefixReference], however it is only used for class |
| 1013 * members, not for prefixed imports. |
| 1014 * |
| 1015 * Containing references must always point backward; that is, for all i, if |
| 1016 * LinkedUnit.references[i].containingReference != 0, then |
| 1017 * LinkedUnit.references[i].containingReference < i. |
| 1018 */ |
| 1019 containingReference:uint (id: 5); |
| 1020 |
| 1021 /** |
| 1022 * Index into [LinkedLibrary.dependencies] indicating which imported library |
| 1023 * declares the entity being referred to. |
| 1024 * |
| 1025 * Zero if this entity is contained within another entity (e.g. a class |
| 1026 * member), or if [kind] is [ReferenceKind.prefix]. |
| 1027 */ |
| 1028 dependency:uint (id: 1); |
| 1029 |
| 1030 /** |
| 1031 * The kind of the entity being referred to. For the pseudo-types `dynamic` |
| 1032 * and `void`, the kind is [ReferenceKind.classOrEnum]. |
| 1033 */ |
| 1034 kind:ReferenceKind (id: 2); |
| 1035 |
| 1036 /** |
| 1037 * If [kind] is [ReferenceKind.function] (that is, the entity being referred |
| 1038 * to is a local function), the index of the function within |
| 1039 * [UnlinkedExecutable.localFunctions]. If [kind] is |
| 1040 * [ReferenceKind.variable], the index of the variable within |
| 1041 * [UnlinkedExecutable.localVariables]. Otherwise zero. |
| 1042 */ |
| 1043 localIndex:uint (id: 6); |
| 1044 |
| 1045 /** |
| 1046 * If this [LinkedReference] doesn't have an associated [UnlinkedReference], |
| 1047 * name of the entity being referred to. For the pseudo-type `dynamic`, the |
| 1048 * string is "dynamic". For the pseudo-type `void`, the string is "void". |
| 1049 */ |
| 1050 name:string (id: 3); |
| 1051 |
| 1052 /** |
| 1053 * If the entity being referred to is generic, the number of type parameters |
| 1054 * it declares (does not include type parameters of enclosing entities). |
| 1055 * Otherwise zero. |
| 1056 */ |
| 1057 numTypeParameters:uint (id: 4); |
| 1058 |
| 1059 /** |
| 1060 * Integer index indicating which unit in the imported library contains the |
| 1061 * definition of the entity. As with indices into [LinkedLibrary.units], |
| 1062 * zero represents the defining compilation unit, and nonzero values |
| 1063 * represent parts in the order of the corresponding `part` declarations. |
| 1064 * |
| 1065 * Zero if this entity is contained within another entity (e.g. a class |
| 1066 * member). |
| 1067 */ |
| 1068 unit:uint (id: 0); |
| 1069 } |
| 1070 |
| 1071 /** |
| 1072 * Linked summary of a compilation unit. |
| 1073 */ |
| 1074 table LinkedUnit { |
| 1075 /** |
| 1076 * List of slot ids (referring to [UnlinkedExecutable.constCycleSlot]) |
| 1077 * corresponding to const constructors that are part of cycles. |
| 1078 */ |
| 1079 constCycles:[uint] (id: 2); |
| 1080 |
| 1081 /** |
| 1082 * List of slot ids (referring to [UnlinkedParam.inheritsCovariantSlot]) |
| 1083 * corresponding to parameters that inherit `@covariant` behavior from a base |
| 1084 * class. |
| 1085 */ |
| 1086 parametersInheritingCovariant:[uint] (id: 3); |
| 1087 |
| 1088 /** |
| 1089 * Information about the resolution of references within the compilation |
| 1090 * unit. Each element of [UnlinkedUnit.references] has a corresponding |
| 1091 * element in this list (at the same index). If this list has additional |
| 1092 * elements beyond the number of elements in [UnlinkedUnit.references], those |
| 1093 * additional elements are references that are only referred to implicitly |
| 1094 * (e.g. elements involved in inferred or propagated types). |
| 1095 */ |
| 1096 references:[LinkedReference] (id: 0); |
| 1097 |
| 1098 /** |
| 1099 * List associating slot ids found inside the unlinked summary for the |
| 1100 * compilation unit with propagated and inferred types. |
| 1101 */ |
| 1102 types:[EntityRef] (id: 1); |
| 1103 } |
| 1104 |
| 1105 /** |
| 1106 * Summary information about a package. |
| 1107 */ |
| 1108 table PackageBundle { |
| 1109 /** |
| 1110 * MD5 hash of the non-informative fields of the [PackageBundle] (not |
| 1111 * including this one). This can be used to identify when the API of a |
| 1112 * package may have changed. |
| 1113 */ |
| 1114 apiSignature:string (id: 7); |
| 1115 |
| 1116 /** |
| 1117 * Information about the packages this package depends on, if known. |
| 1118 */ |
| 1119 dependencies:[PackageDependencyInfo] (id: 8); |
| 1120 |
| 1121 /** |
| 1122 * Linked libraries. |
| 1123 */ |
| 1124 linkedLibraries:[LinkedLibrary] (id: 0); |
| 1125 |
| 1126 /** |
| 1127 * The list of URIs of items in [linkedLibraries], e.g. `dart:core` or |
| 1128 * `package:foo/bar.dart`. |
| 1129 */ |
| 1130 linkedLibraryUris:[string] (id: 1); |
| 1131 |
| 1132 /** |
| 1133 * Major version of the summary format. See |
| 1134 * [PackageBundleAssembler.currentMajorVersion]. |
| 1135 */ |
| 1136 majorVersion:uint (id: 5); |
| 1137 |
| 1138 /** |
| 1139 * Minor version of the summary format. See |
| 1140 * [PackageBundleAssembler.currentMinorVersion]. |
| 1141 */ |
| 1142 minorVersion:uint (id: 6); |
| 1143 |
| 1144 /** |
| 1145 * List of MD5 hashes of the files listed in [unlinkedUnitUris]. Each hash |
| 1146 * is encoded as a hexadecimal string using lower case letters. |
| 1147 */ |
| 1148 unlinkedUnitHashes:[string] (id: 4); |
| 1149 |
| 1150 /** |
| 1151 * Unlinked information for the compilation units constituting the package. |
| 1152 */ |
| 1153 unlinkedUnits:[UnlinkedUnit] (id: 2); |
| 1154 |
| 1155 /** |
| 1156 * The list of URIs of items in [unlinkedUnits], e.g. `dart:core/bool.dart`. |
| 1157 */ |
| 1158 unlinkedUnitUris:[string] (id: 3); |
| 1159 } |
| 1160 |
| 1161 /** |
| 1162 * Information about a single dependency of a summary package. |
| 1163 */ |
| 1164 table PackageDependencyInfo { |
| 1165 /** |
| 1166 * API signature of this dependency. |
| 1167 */ |
| 1168 apiSignature:string (id: 0); |
| 1169 |
| 1170 /** |
| 1171 * If this dependency summarizes any files whose URI takes the form |
| 1172 * "package:<package_name>/...", a list of all such package names, sorted |
| 1173 * lexicographically. Otherwise empty. |
| 1174 */ |
| 1175 includedPackageNames:[string] (id: 2); |
| 1176 |
| 1177 /** |
| 1178 * Indicates whether this dependency summarizes any files whose URI takes the |
| 1179 * form "dart:...". |
| 1180 */ |
| 1181 includesDartUris:bool (id: 4); |
| 1182 |
| 1183 /** |
| 1184 * Indicates whether this dependency summarizes any files whose URI takes the |
| 1185 * form "file:...". |
| 1186 */ |
| 1187 includesFileUris:bool (id: 3); |
| 1188 |
| 1189 /** |
| 1190 * Relative path to the summary file for this dependency. This is intended as |
| 1191 * a hint to help the analysis server locate summaries of dependencies. We |
| 1192 * don't specify precisely what this path is relative to, but we expect it to |
| 1193 * be relative to a directory the analysis server can find (e.g. for projects |
| 1194 * built using Bazel, it would be relative to the "bazel-bin" directory). |
| 1195 * |
| 1196 * Absent if the path is not known. |
| 1197 */ |
| 1198 summaryPath:string (id: 1); |
| 1199 } |
| 1200 |
| 1201 /** |
| 1202 * Index information about a package. |
| 1203 */ |
| 1204 table PackageIndex { |
| 1205 /** |
| 1206 * Each item of this list corresponds to a unique referenced element. It is |
| 1207 * the kind of the synthetic element. |
| 1208 */ |
| 1209 elementKinds:[IndexSyntheticElementKind] (id: 5); |
| 1210 |
| 1211 /** |
| 1212 * Each item of this list corresponds to a unique referenced element. It is |
| 1213 * the identifier of the class member element name, or `null` if the element i
s |
| 1214 * a top-level element. The list is sorted in ascending order, so that the |
| 1215 * client can quickly check whether an element is referenced in this |
| 1216 * [PackageIndex]. |
| 1217 */ |
| 1218 elementNameClassMemberIds:[uint] (id: 7); |
| 1219 |
| 1220 /** |
| 1221 * Each item of this list corresponds to a unique referenced element. It is |
| 1222 * the identifier of the named parameter name, or `null` if the element is not |
| 1223 * a named parameter. The list is sorted in ascending order, so that the |
| 1224 * client can quickly check whether an element is referenced in this |
| 1225 * [PackageIndex]. |
| 1226 */ |
| 1227 elementNameParameterIds:[uint] (id: 8); |
| 1228 |
| 1229 /** |
| 1230 * Each item of this list corresponds to a unique referenced element. It is |
| 1231 * the identifier of the top-level element name, or `null` if the element is |
| 1232 * the unit. The list is sorted in ascending order, so that the client can |
| 1233 * quickly check whether an element is referenced in this [PackageIndex]. |
| 1234 */ |
| 1235 elementNameUnitMemberIds:[uint] (id: 1); |
| 1236 |
| 1237 /** |
| 1238 * Each item of this list corresponds to a unique referenced element. It is |
| 1239 * the index into [unitLibraryUris] and [unitUnitUris] for the library |
| 1240 * specific unit where the element is declared. |
| 1241 */ |
| 1242 elementUnits:[uint] (id: 0); |
| 1243 |
| 1244 /** |
| 1245 * List of unique element strings used in this [PackageIndex]. The list is |
| 1246 * sorted in ascending order, so that the client can quickly check the |
| 1247 * presence of a string in this [PackageIndex]. |
| 1248 */ |
| 1249 strings:[string] (id: 6); |
| 1250 |
| 1251 /** |
| 1252 * Each item of this list corresponds to the library URI of a unique library |
| 1253 * specific unit referenced in the [PackageIndex]. It is an index into |
| 1254 * [strings] list. |
| 1255 */ |
| 1256 unitLibraryUris:[uint] (id: 2); |
| 1257 |
| 1258 /** |
| 1259 * List of indexes of each unit in this [PackageIndex]. |
| 1260 */ |
| 1261 units:[UnitIndex] (id: 4); |
| 1262 |
| 1263 /** |
| 1264 * Each item of this list corresponds to the unit URI of a unique library |
| 1265 * specific unit referenced in the [PackageIndex]. It is an index into |
| 1266 * [strings] list. |
| 1267 */ |
| 1268 unitUnitUris:[uint] (id: 3); |
| 1269 } |
| 1270 |
| 1271 /** |
| 1272 * Index information about a unit in a [PackageIndex]. |
| 1273 */ |
| 1274 table UnitIndex { |
| 1275 /** |
| 1276 * Each item of this list is the kind of an element defined in this unit. |
| 1277 */ |
| 1278 definedNameKinds:[IndexNameKind] (id: 6); |
| 1279 |
| 1280 /** |
| 1281 * Each item of this list is the name offset of an element defined in this |
| 1282 * unit relative to the beginning of the file. |
| 1283 */ |
| 1284 definedNameOffsets:[uint] (id: 7); |
| 1285 |
| 1286 /** |
| 1287 * Each item of this list corresponds to an element defined in this unit. It |
| 1288 * is an index into [PackageIndex.strings] list. The list is sorted in |
| 1289 * ascending order, so that the client can quickly find name definitions in |
| 1290 * this [UnitIndex]. |
| 1291 */ |
| 1292 definedNames:[uint] (id: 5); |
| 1293 |
| 1294 /** |
| 1295 * Index into [PackageIndex.unitLibraryUris] and [PackageIndex.unitUnitUris] |
| 1296 * for the library specific unit that corresponds to this [UnitIndex]. |
| 1297 */ |
| 1298 unit:uint (id: 0); |
| 1299 |
| 1300 /** |
| 1301 * Each item of this list is the `true` if the corresponding element usage |
| 1302 * is qualified with some prefix. |
| 1303 */ |
| 1304 usedElementIsQualifiedFlags:[ubyte] (id: 11); |
| 1305 |
| 1306 /** |
| 1307 * Each item of this list is the kind of the element usage. |
| 1308 */ |
| 1309 usedElementKinds:[IndexRelationKind] (id: 4); |
| 1310 |
| 1311 /** |
| 1312 * Each item of this list is the length of the element usage. |
| 1313 */ |
| 1314 usedElementLengths:[uint] (id: 1); |
| 1315 |
| 1316 /** |
| 1317 * Each item of this list is the offset of the element usage relative to the |
| 1318 * beginning of the file. |
| 1319 */ |
| 1320 usedElementOffsets:[uint] (id: 2); |
| 1321 |
| 1322 /** |
| 1323 * Each item of this list is the index into [PackageIndex.elementUnits] and |
| 1324 * [PackageIndex.elementOffsets]. The list is sorted in ascending order, so |
| 1325 * that the client can quickly find element references in this [UnitIndex]. |
| 1326 */ |
| 1327 usedElements:[uint] (id: 3); |
| 1328 |
| 1329 /** |
| 1330 * Each item of this list is the `true` if the corresponding name usage |
| 1331 * is qualified with some prefix. |
| 1332 */ |
| 1333 usedNameIsQualifiedFlags:[ubyte] (id: 12); |
| 1334 |
| 1335 /** |
| 1336 * Each item of this list is the kind of the name usage. |
| 1337 */ |
| 1338 usedNameKinds:[IndexRelationKind] (id: 10); |
| 1339 |
| 1340 /** |
| 1341 * Each item of this list is the offset of the name usage relative to the |
| 1342 * beginning of the file. |
| 1343 */ |
| 1344 usedNameOffsets:[uint] (id: 9); |
| 1345 |
| 1346 /** |
| 1347 * Each item of this list is the index into [PackageIndex.strings] for a |
| 1348 * used name. The list is sorted in ascending order, so that the client can |
| 1349 * quickly find name uses in this [UnitIndex]. |
| 1350 */ |
| 1351 usedNames:[uint] (id: 8); |
| 1352 } |
| 1353 |
| 1354 /** |
| 1355 * Unlinked summary information about a class declaration. |
| 1356 */ |
| 1357 table UnlinkedClass { |
| 1358 /** |
| 1359 * Annotations for this class. |
| 1360 */ |
| 1361 annotations:[UnlinkedConst] (id: 5); |
| 1362 |
| 1363 /** |
| 1364 * Code range of the class. |
| 1365 */ |
| 1366 codeRange:CodeRange (id: 13); |
| 1367 |
| 1368 /** |
| 1369 * Documentation comment for the class, or `null` if there is no |
| 1370 * documentation comment. |
| 1371 */ |
| 1372 documentationComment:UnlinkedDocumentationComment (id: 6); |
| 1373 |
| 1374 /** |
| 1375 * Executable objects (methods, getters, and setters) contained in the class. |
| 1376 */ |
| 1377 executables:[UnlinkedExecutable] (id: 2); |
| 1378 |
| 1379 /** |
| 1380 * Field declarations contained in the class. |
| 1381 */ |
| 1382 fields:[UnlinkedVariable] (id: 4); |
| 1383 |
| 1384 /** |
| 1385 * Indicates whether this class is the core "Object" class (and hence has no |
| 1386 * supertype) |
| 1387 */ |
| 1388 hasNoSupertype:bool (id: 12); |
| 1389 |
| 1390 /** |
| 1391 * Interfaces appearing in an `implements` clause, if any. |
| 1392 */ |
| 1393 interfaces:[EntityRef] (id: 7); |
| 1394 |
| 1395 /** |
| 1396 * Indicates whether the class is declared with the `abstract` keyword. |
| 1397 */ |
| 1398 isAbstract:bool (id: 8); |
| 1399 |
| 1400 /** |
| 1401 * Indicates whether the class is declared using mixin application syntax. |
| 1402 */ |
| 1403 isMixinApplication:bool (id: 11); |
| 1404 |
| 1405 /** |
| 1406 * Mixins appearing in a `with` clause, if any. |
| 1407 */ |
| 1408 mixins:[EntityRef] (id: 10); |
| 1409 |
| 1410 /** |
| 1411 * Name of the class. |
| 1412 */ |
| 1413 name:string (id: 0); |
| 1414 |
| 1415 /** |
| 1416 * Offset of the class name relative to the beginning of the file. |
| 1417 */ |
| 1418 nameOffset:uint (id: 1); |
| 1419 |
| 1420 /** |
| 1421 * Supertype of the class, or `null` if either (a) the class doesn't |
| 1422 * explicitly declare a supertype (and hence has supertype `Object`), or (b) |
| 1423 * the class *is* `Object` (and hence has no supertype). |
| 1424 */ |
| 1425 supertype:EntityRef (id: 3); |
| 1426 |
| 1427 /** |
| 1428 * Type parameters of the class, if any. |
| 1429 */ |
| 1430 typeParameters:[UnlinkedTypeParam] (id: 9); |
| 1431 } |
| 1432 |
| 1433 /** |
| 1434 * Unlinked summary information about a `show` or `hide` combinator in an |
| 1435 * import or export declaration. |
| 1436 */ |
| 1437 table UnlinkedCombinator { |
| 1438 /** |
| 1439 * If this is a `show` combinator, offset of the end of the list of shown |
| 1440 * names. Otherwise zero. |
| 1441 */ |
| 1442 end:uint (id: 3); |
| 1443 |
| 1444 /** |
| 1445 * List of names which are hidden. Empty if this is a `show` combinator. |
| 1446 */ |
| 1447 hides:[string] (id: 1); |
| 1448 |
| 1449 /** |
| 1450 * If this is a `show` combinator, offset of the `show` keyword. Otherwise |
| 1451 * zero. |
| 1452 */ |
| 1453 offset:uint (id: 2); |
| 1454 |
| 1455 /** |
| 1456 * List of names which are shown. Empty if this is a `hide` combinator. |
| 1457 */ |
| 1458 shows:[string] (id: 0); |
| 1459 } |
| 1460 |
| 1461 /** |
| 1462 * Unlinked summary information about a single import or export configuration. |
| 1463 */ |
| 1464 table UnlinkedConfiguration { |
| 1465 /** |
| 1466 * The name of the declared variable whose value is being used in the |
| 1467 * condition. |
| 1468 */ |
| 1469 name:string (id: 0); |
| 1470 |
| 1471 /** |
| 1472 * The URI of the implementation library to be used if the condition is true. |
| 1473 */ |
| 1474 uri:string (id: 2); |
| 1475 |
| 1476 /** |
| 1477 * The value to which the value of the declared variable will be compared, |
| 1478 * or `true` if the condition does not include an equality test. |
| 1479 */ |
| 1480 value:string (id: 1); |
| 1481 } |
| 1482 |
| 1483 /** |
| 1484 * Unlinked summary information about a compile-time constant expression, or a |
| 1485 * potentially constant expression. |
| 1486 * |
| 1487 * Constant expressions are represented using a simple stack-based language |
| 1488 * where [operations] is a sequence of operations to execute starting with an |
| 1489 * empty stack. Once all operations have been executed, the stack should |
| 1490 * contain a single value which is the value of the constant. Note that some |
| 1491 * operations consume additional data from the other fields of this class. |
| 1492 */ |
| 1493 table UnlinkedConst { |
| 1494 /** |
| 1495 * Sequence of operators used by assignment operations. |
| 1496 */ |
| 1497 assignmentOperators:[UnlinkedExprAssignOperator] (id: 6); |
| 1498 |
| 1499 /** |
| 1500 * Sequence of 64-bit doubles consumed by the operation `pushDouble`. |
| 1501 */ |
| 1502 doubles:[double] (id: 4); |
| 1503 |
| 1504 /** |
| 1505 * Sequence of unsigned 32-bit integers consumed by the operations |
| 1506 * `pushArgument`, `pushInt`, `shiftOr`, `concatenate`, `invokeConstructor`, |
| 1507 * `makeList`, and `makeMap`. |
| 1508 */ |
| 1509 ints:[uint] (id: 1); |
| 1510 |
| 1511 /** |
| 1512 * Indicates whether the expression is a valid potentially constant |
| 1513 * expression. |
| 1514 */ |
| 1515 isValidConst:bool (id: 5); |
| 1516 |
| 1517 /** |
| 1518 * Sequence of operations to execute (starting with an empty stack) to form |
| 1519 * the constant value. |
| 1520 */ |
| 1521 operations:[UnlinkedConstOperation] (id: 0); |
| 1522 |
| 1523 /** |
| 1524 * Sequence of language constructs consumed by the operations |
| 1525 * `pushReference`, `invokeConstructor`, `makeList`, and `makeMap`. Note |
| 1526 * that in the case of `pushReference` (and sometimes `invokeConstructor` the |
| 1527 * actual entity being referred to may be something other than a type. |
| 1528 */ |
| 1529 references:[EntityRef] (id: 2); |
| 1530 |
| 1531 /** |
| 1532 * Sequence of strings consumed by the operations `pushString` and |
| 1533 * `invokeConstructor`. |
| 1534 */ |
| 1535 strings:[string] (id: 3); |
| 1536 } |
| 1537 |
| 1538 /** |
| 1539 * Unlinked summary information about a constructor initializer. |
| 1540 */ |
| 1541 table UnlinkedConstructorInitializer { |
| 1542 /** |
| 1543 * If there are `m` [arguments] and `n` [argumentNames], then each argument |
| 1544 * from [arguments] with index `i` such that `n + i - m >= 0`, should be used |
| 1545 * with the name at `n + i - m`. |
| 1546 */ |
| 1547 argumentNames:[string] (id: 4); |
| 1548 |
| 1549 /** |
| 1550 * If [kind] is `thisInvocation` or `superInvocation`, the arguments of the |
| 1551 * invocation. Otherwise empty. |
| 1552 */ |
| 1553 arguments:[UnlinkedConst] (id: 3); |
| 1554 |
| 1555 /** |
| 1556 * If [kind] is `field`, the expression of the field initializer. |
| 1557 * Otherwise `null`. |
| 1558 */ |
| 1559 expression:UnlinkedConst (id: 1); |
| 1560 |
| 1561 /** |
| 1562 * The kind of the constructor initializer (field, redirect, super). |
| 1563 */ |
| 1564 kind:UnlinkedConstructorInitializerKind (id: 2); |
| 1565 |
| 1566 /** |
| 1567 * If [kind] is `field`, the name of the field declared in the class. If |
| 1568 * [kind] is `thisInvocation`, the name of the constructor, declared in this |
| 1569 * class, to redirect to. If [kind] is `superInvocation`, the name of the |
| 1570 * constructor, declared in the superclass, to invoke. |
| 1571 */ |
| 1572 name:string (id: 0); |
| 1573 } |
| 1574 |
| 1575 /** |
| 1576 * Unlinked summary information about a documentation comment. |
| 1577 */ |
| 1578 table UnlinkedDocumentationComment { |
| 1579 /** |
| 1580 * Length of the documentation comment (prior to replacing '\r\n' with '\n'). |
| 1581 */ |
| 1582 length:uint (id: 0, deprecated); |
| 1583 |
| 1584 /** |
| 1585 * Offset of the beginning of the documentation comment relative to the |
| 1586 * beginning of the file. |
| 1587 */ |
| 1588 offset:uint (id: 2, deprecated); |
| 1589 |
| 1590 /** |
| 1591 * Text of the documentation comment, with '\r\n' replaced by '\n'. |
| 1592 * |
| 1593 * References appearing within the doc comment in square brackets are not |
| 1594 * specially encoded. |
| 1595 */ |
| 1596 text:string (id: 1); |
| 1597 } |
| 1598 |
| 1599 /** |
| 1600 * Unlinked summary information about an enum declaration. |
| 1601 */ |
| 1602 table UnlinkedEnum { |
| 1603 /** |
| 1604 * Annotations for this enum. |
| 1605 */ |
| 1606 annotations:[UnlinkedConst] (id: 4); |
| 1607 |
| 1608 /** |
| 1609 * Code range of the enum. |
| 1610 */ |
| 1611 codeRange:CodeRange (id: 5); |
| 1612 |
| 1613 /** |
| 1614 * Documentation comment for the enum, or `null` if there is no documentation |
| 1615 * comment. |
| 1616 */ |
| 1617 documentationComment:UnlinkedDocumentationComment (id: 3); |
| 1618 |
| 1619 /** |
| 1620 * Name of the enum type. |
| 1621 */ |
| 1622 name:string (id: 0); |
| 1623 |
| 1624 /** |
| 1625 * Offset of the enum name relative to the beginning of the file. |
| 1626 */ |
| 1627 nameOffset:uint (id: 1); |
| 1628 |
| 1629 /** |
| 1630 * Values listed in the enum declaration, in declaration order. |
| 1631 */ |
| 1632 values:[UnlinkedEnumValue] (id: 2); |
| 1633 } |
| 1634 |
| 1635 /** |
| 1636 * Unlinked summary information about a single enumerated value in an enum |
| 1637 * declaration. |
| 1638 */ |
| 1639 table UnlinkedEnumValue { |
| 1640 /** |
| 1641 * Documentation comment for the enum value, or `null` if there is no |
| 1642 * documentation comment. |
| 1643 */ |
| 1644 documentationComment:UnlinkedDocumentationComment (id: 2); |
| 1645 |
| 1646 /** |
| 1647 * Name of the enumerated value. |
| 1648 */ |
| 1649 name:string (id: 0); |
| 1650 |
| 1651 /** |
| 1652 * Offset of the enum value name relative to the beginning of the file. |
| 1653 */ |
| 1654 nameOffset:uint (id: 1); |
| 1655 } |
| 1656 |
| 1657 /** |
| 1658 * Unlinked summary information about a function, method, getter, or setter |
| 1659 * declaration. |
| 1660 */ |
| 1661 table UnlinkedExecutable { |
| 1662 /** |
| 1663 * Annotations for this executable. |
| 1664 */ |
| 1665 annotations:[UnlinkedConst] (id: 6); |
| 1666 |
| 1667 /** |
| 1668 * If this executable's function body is declared using `=>`, the expression |
| 1669 * to the right of the `=>`. May be omitted if neither type inference nor |
| 1670 * constant evaluation depends on the function body. |
| 1671 */ |
| 1672 bodyExpr:UnlinkedConst (id: 29); |
| 1673 |
| 1674 /** |
| 1675 * Code range of the executable. |
| 1676 */ |
| 1677 codeRange:CodeRange (id: 26); |
| 1678 |
| 1679 /** |
| 1680 * If a constant [UnlinkedExecutableKind.constructor], the constructor |
| 1681 * initializers. Otherwise empty. |
| 1682 */ |
| 1683 constantInitializers:[UnlinkedConstructorInitializer] (id: 14); |
| 1684 |
| 1685 /** |
| 1686 * If [kind] is [UnlinkedExecutableKind.constructor] and [isConst] is `true`, |
| 1687 * a nonzero slot id which is unique within this compilation unit. If this id |
| 1688 * is found in [LinkedUnit.constCycles], then this constructor is part of a |
| 1689 * cycle. |
| 1690 * |
| 1691 * Otherwise, zero. |
| 1692 */ |
| 1693 constCycleSlot:uint (id: 25); |
| 1694 |
| 1695 /** |
| 1696 * Documentation comment for the executable, or `null` if there is no |
| 1697 * documentation comment. |
| 1698 */ |
| 1699 documentationComment:UnlinkedDocumentationComment (id: 7); |
| 1700 |
| 1701 /** |
| 1702 * If this executable's return type is inferable, nonzero slot id |
| 1703 * identifying which entry in [LinkedUnit.types] contains the inferred |
| 1704 * return type. If there is no matching entry in [LinkedUnit.types], then |
| 1705 * no return type was inferred for this variable, so its static type is |
| 1706 * `dynamic`. |
| 1707 */ |
| 1708 inferredReturnTypeSlot:uint (id: 5); |
| 1709 |
| 1710 /** |
| 1711 * Indicates whether the executable is declared using the `abstract` keyword. |
| 1712 */ |
| 1713 isAbstract:bool (id: 10); |
| 1714 |
| 1715 /** |
| 1716 * Indicates whether the executable has body marked as being asynchronous. |
| 1717 */ |
| 1718 isAsynchronous:bool (id: 27); |
| 1719 |
| 1720 /** |
| 1721 * Indicates whether the executable is declared using the `const` keyword. |
| 1722 */ |
| 1723 isConst:bool (id: 12); |
| 1724 |
| 1725 /** |
| 1726 * Indicates whether the executable is declared using the `external` keyword. |
| 1727 */ |
| 1728 isExternal:bool (id: 11); |
| 1729 |
| 1730 /** |
| 1731 * Indicates whether the executable is declared using the `factory` keyword. |
| 1732 */ |
| 1733 isFactory:bool (id: 8); |
| 1734 |
| 1735 /** |
| 1736 * Indicates whether the executable has body marked as being a generator. |
| 1737 */ |
| 1738 isGenerator:bool (id: 28); |
| 1739 |
| 1740 /** |
| 1741 * Indicates whether the executable is a redirected constructor. |
| 1742 */ |
| 1743 isRedirectedConstructor:bool (id: 13); |
| 1744 |
| 1745 /** |
| 1746 * Indicates whether the executable is declared using the `static` keyword. |
| 1747 * |
| 1748 * Note that for top level executables, this flag is false, since they are |
| 1749 * not declared using the `static` keyword (even though they are considered |
| 1750 * static for semantic purposes). |
| 1751 */ |
| 1752 isStatic:bool (id: 9); |
| 1753 |
| 1754 /** |
| 1755 * The kind of the executable (function/method, getter, setter, or |
| 1756 * constructor). |
| 1757 */ |
| 1758 kind:UnlinkedExecutableKind (id: 4); |
| 1759 |
| 1760 /** |
| 1761 * The list of local functions. |
| 1762 */ |
| 1763 localFunctions:[UnlinkedExecutable] (id: 18); |
| 1764 |
| 1765 /** |
| 1766 * The list of local labels. |
| 1767 */ |
| 1768 localLabels:[UnlinkedLabel] (id: 22); |
| 1769 |
| 1770 /** |
| 1771 * The list of local variables. |
| 1772 */ |
| 1773 localVariables:[UnlinkedVariable] (id: 19); |
| 1774 |
| 1775 /** |
| 1776 * Name of the executable. For setters, this includes the trailing "=". For |
| 1777 * named constructors, this excludes the class name and excludes the ".". |
| 1778 * For unnamed constructors, this is the empty string. |
| 1779 */ |
| 1780 name:string (id: 1); |
| 1781 |
| 1782 /** |
| 1783 * If [kind] is [UnlinkedExecutableKind.constructor] and [name] is not empty, |
| 1784 * the offset of the end of the constructor name. Otherwise zero. |
| 1785 */ |
| 1786 nameEnd:uint (id: 23); |
| 1787 |
| 1788 /** |
| 1789 * Offset of the executable name relative to the beginning of the file. For |
| 1790 * named constructors, this excludes the class name and excludes the ".". |
| 1791 * For unnamed constructors, this is the offset of the class name (i.e. the |
| 1792 * offset of the second "C" in "class C { C(); }"). |
| 1793 */ |
| 1794 nameOffset:uint (id: 0); |
| 1795 |
| 1796 /** |
| 1797 * Parameters of the executable, if any. Note that getters have no |
| 1798 * parameters (hence this will be the empty list), and setters have a single |
| 1799 * parameter. |
| 1800 */ |
| 1801 parameters:[UnlinkedParam] (id: 2); |
| 1802 |
| 1803 /** |
| 1804 * If [kind] is [UnlinkedExecutableKind.constructor] and [name] is not empty, |
| 1805 * the offset of the period before the constructor name. Otherwise zero. |
| 1806 */ |
| 1807 periodOffset:uint (id: 24); |
| 1808 |
| 1809 /** |
| 1810 * If [isRedirectedConstructor] and [isFactory] are both `true`, the |
| 1811 * constructor to which this constructor redirects; otherwise empty. |
| 1812 */ |
| 1813 redirectedConstructor:EntityRef (id: 15); |
| 1814 |
| 1815 /** |
| 1816 * If [isRedirectedConstructor] is `true` and [isFactory] is `false`, the |
| 1817 * name of the constructor that this constructor redirects to; otherwise |
| 1818 * empty. |
| 1819 */ |
| 1820 redirectedConstructorName:string (id: 17); |
| 1821 |
| 1822 /** |
| 1823 * Declared return type of the executable. Absent if the executable is a |
| 1824 * constructor or the return type is implicit. Absent for executables |
| 1825 * associated with variable initializers and closures, since these |
| 1826 * executables may have return types that are not accessible via direct |
| 1827 * imports. |
| 1828 */ |
| 1829 returnType:EntityRef (id: 3); |
| 1830 |
| 1831 /** |
| 1832 * Type parameters of the executable, if any. Empty if support for generic |
| 1833 * method syntax is disabled. |
| 1834 */ |
| 1835 typeParameters:[UnlinkedTypeParam] (id: 16); |
| 1836 |
| 1837 /** |
| 1838 * If a local function, the length of the visible range; zero otherwise. |
| 1839 */ |
| 1840 visibleLength:uint (id: 20); |
| 1841 |
| 1842 /** |
| 1843 * If a local function, the beginning of the visible range; zero otherwise. |
| 1844 */ |
| 1845 visibleOffset:uint (id: 21); |
| 1846 } |
| 1847 |
| 1848 /** |
| 1849 * Unlinked summary information about an export declaration (stored outside |
| 1850 * [UnlinkedPublicNamespace]). |
| 1851 */ |
| 1852 table UnlinkedExportNonPublic { |
| 1853 /** |
| 1854 * Annotations for this export directive. |
| 1855 */ |
| 1856 annotations:[UnlinkedConst] (id: 3); |
| 1857 |
| 1858 /** |
| 1859 * Offset of the "export" keyword. |
| 1860 */ |
| 1861 offset:uint (id: 0); |
| 1862 |
| 1863 /** |
| 1864 * End of the URI string (including quotes) relative to the beginning of the |
| 1865 * file. |
| 1866 */ |
| 1867 uriEnd:uint (id: 1); |
| 1868 |
| 1869 /** |
| 1870 * Offset of the URI string (including quotes) relative to the beginning of |
| 1871 * the file. |
| 1872 */ |
| 1873 uriOffset:uint (id: 2); |
| 1874 } |
| 1875 |
| 1876 /** |
| 1877 * Unlinked summary information about an export declaration (stored inside |
| 1878 * [UnlinkedPublicNamespace]). |
| 1879 */ |
| 1880 table UnlinkedExportPublic { |
| 1881 /** |
| 1882 * Combinators contained in this export declaration. |
| 1883 */ |
| 1884 combinators:[UnlinkedCombinator] (id: 1); |
| 1885 |
| 1886 /** |
| 1887 * Configurations used to control which library will actually be loaded at |
| 1888 * run-time. |
| 1889 */ |
| 1890 configurations:[UnlinkedConfiguration] (id: 2); |
| 1891 |
| 1892 /** |
| 1893 * URI used in the source code to reference the exported library. |
| 1894 */ |
| 1895 uri:string (id: 0); |
| 1896 } |
| 1897 |
| 1898 /** |
| 1899 * Unlinked summary information about an import declaration. |
| 1900 */ |
| 1901 table UnlinkedImport { |
| 1902 /** |
| 1903 * Annotations for this import declaration. |
| 1904 */ |
| 1905 annotations:[UnlinkedConst] (id: 8); |
| 1906 |
| 1907 /** |
| 1908 * Combinators contained in this import declaration. |
| 1909 */ |
| 1910 combinators:[UnlinkedCombinator] (id: 4); |
| 1911 |
| 1912 /** |
| 1913 * Configurations used to control which library will actually be loaded at |
| 1914 * run-time. |
| 1915 */ |
| 1916 configurations:[UnlinkedConfiguration] (id: 10); |
| 1917 |
| 1918 /** |
| 1919 * Indicates whether the import declaration uses the `deferred` keyword. |
| 1920 */ |
| 1921 isDeferred:bool (id: 9); |
| 1922 |
| 1923 /** |
| 1924 * Indicates whether the import declaration is implicit. |
| 1925 */ |
| 1926 isImplicit:bool (id: 5); |
| 1927 |
| 1928 /** |
| 1929 * If [isImplicit] is false, offset of the "import" keyword. If [isImplicit] |
| 1930 * is true, zero. |
| 1931 */ |
| 1932 offset:uint (id: 0); |
| 1933 |
| 1934 /** |
| 1935 * Offset of the prefix name relative to the beginning of the file, or zero |
| 1936 * if there is no prefix. |
| 1937 */ |
| 1938 prefixOffset:uint (id: 6); |
| 1939 |
| 1940 /** |
| 1941 * Index into [UnlinkedUnit.references] of the prefix declared by this |
| 1942 * import declaration, or zero if this import declaration declares no prefix. |
| 1943 * |
| 1944 * Note that multiple imports can declare the same prefix. |
| 1945 */ |
| 1946 prefixReference:uint (id: 7); |
| 1947 |
| 1948 /** |
| 1949 * URI used in the source code to reference the imported library. |
| 1950 */ |
| 1951 uri:string (id: 1); |
| 1952 |
| 1953 /** |
| 1954 * End of the URI string (including quotes) relative to the beginning of the |
| 1955 * file. If [isImplicit] is true, zero. |
| 1956 */ |
| 1957 uriEnd:uint (id: 2); |
| 1958 |
| 1959 /** |
| 1960 * Offset of the URI string (including quotes) relative to the beginning of |
| 1961 * the file. If [isImplicit] is true, zero. |
| 1962 */ |
| 1963 uriOffset:uint (id: 3); |
| 1964 } |
| 1965 |
| 1966 /** |
| 1967 * Unlinked summary information about a label. |
| 1968 */ |
| 1969 table UnlinkedLabel { |
| 1970 /** |
| 1971 * Return `true` if this label is associated with a `switch` member (`case` or |
| 1972 * `default`). |
| 1973 */ |
| 1974 isOnSwitchMember:bool (id: 2); |
| 1975 |
| 1976 /** |
| 1977 * Return `true` if this label is associated with a `switch` statement. |
| 1978 */ |
| 1979 isOnSwitchStatement:bool (id: 3); |
| 1980 |
| 1981 /** |
| 1982 * Name of the label. |
| 1983 */ |
| 1984 name:string (id: 0); |
| 1985 |
| 1986 /** |
| 1987 * Offset of the label relative to the beginning of the file. |
| 1988 */ |
| 1989 nameOffset:uint (id: 1); |
| 1990 } |
| 1991 |
| 1992 /** |
| 1993 * Unlinked summary information about a function parameter. |
| 1994 */ |
| 1995 table UnlinkedParam { |
| 1996 /** |
| 1997 * Annotations for this parameter. |
| 1998 */ |
| 1999 annotations:[UnlinkedConst] (id: 9); |
| 2000 |
| 2001 /** |
| 2002 * Code range of the parameter. |
| 2003 */ |
| 2004 codeRange:CodeRange (id: 7); |
| 2005 |
| 2006 /** |
| 2007 * If the parameter has a default value, the source text of the constant |
| 2008 * expression in the default value. Otherwise the empty string. |
| 2009 */ |
| 2010 defaultValueCode:string (id: 13); |
| 2011 |
| 2012 /** |
| 2013 * If this parameter's type is inferable, nonzero slot id identifying which |
| 2014 * entry in [LinkedLibrary.types] contains the inferred type. If there is no |
| 2015 * matching entry in [LinkedLibrary.types], then no type was inferred for |
| 2016 * this variable, so its static type is `dynamic`. |
| 2017 * |
| 2018 * Note that although strong mode considers initializing formals to be |
| 2019 * inferable, they are not marked as such in the summary; if their type is |
| 2020 * not specified, they always inherit the static type of the corresponding |
| 2021 * field. |
| 2022 */ |
| 2023 inferredTypeSlot:uint (id: 2); |
| 2024 |
| 2025 /** |
| 2026 * If this is a parameter of an instance method, a nonzero slot id which is |
| 2027 * unique within this compilation unit. If this id is found in |
| 2028 * [LinkedUnit.parametersInheritingCovariant], then this parameter inherits |
| 2029 * `@covariant` behavior from a base class. |
| 2030 * |
| 2031 * Otherwise, zero. |
| 2032 */ |
| 2033 inheritsCovariantSlot:uint (id: 14); |
| 2034 |
| 2035 /** |
| 2036 * The synthetic initializer function of the parameter. Absent if the variabl
e |
| 2037 * does not have an initializer. |
| 2038 */ |
| 2039 initializer:UnlinkedExecutable (id: 12); |
| 2040 |
| 2041 /** |
| 2042 * Indicates whether this is a function-typed parameter. |
| 2043 */ |
| 2044 isFunctionTyped:bool (id: 5); |
| 2045 |
| 2046 /** |
| 2047 * Indicates whether this is an initializing formal parameter (i.e. it is |
| 2048 * declared using `this.` syntax). |
| 2049 */ |
| 2050 isInitializingFormal:bool (id: 6); |
| 2051 |
| 2052 /** |
| 2053 * Kind of the parameter. |
| 2054 */ |
| 2055 kind:UnlinkedParamKind (id: 4); |
| 2056 |
| 2057 /** |
| 2058 * Name of the parameter. |
| 2059 */ |
| 2060 name:string (id: 0); |
| 2061 |
| 2062 /** |
| 2063 * Offset of the parameter name relative to the beginning of the file. |
| 2064 */ |
| 2065 nameOffset:uint (id: 1); |
| 2066 |
| 2067 /** |
| 2068 * If [isFunctionTyped] is `true`, the parameters of the function type. |
| 2069 */ |
| 2070 parameters:[UnlinkedParam] (id: 8); |
| 2071 |
| 2072 /** |
| 2073 * If [isFunctionTyped] is `true`, the declared return type. If |
| 2074 * [isFunctionTyped] is `false`, the declared type. Absent if the type is |
| 2075 * implicit. |
| 2076 */ |
| 2077 type:EntityRef (id: 3); |
| 2078 |
| 2079 /** |
| 2080 * The length of the visible range. |
| 2081 */ |
| 2082 visibleLength:uint (id: 10); |
| 2083 |
| 2084 /** |
| 2085 * The beginning of the visible range. |
| 2086 */ |
| 2087 visibleOffset:uint (id: 11); |
| 2088 } |
| 2089 |
| 2090 /** |
| 2091 * Unlinked summary information about a part declaration. |
| 2092 */ |
| 2093 table UnlinkedPart { |
| 2094 /** |
| 2095 * Annotations for this part declaration. |
| 2096 */ |
| 2097 annotations:[UnlinkedConst] (id: 2); |
| 2098 |
| 2099 /** |
| 2100 * End of the URI string (including quotes) relative to the beginning of the |
| 2101 * file. |
| 2102 */ |
| 2103 uriEnd:uint (id: 0); |
| 2104 |
| 2105 /** |
| 2106 * Offset of the URI string (including quotes) relative to the beginning of |
| 2107 * the file. |
| 2108 */ |
| 2109 uriOffset:uint (id: 1); |
| 2110 } |
| 2111 |
| 2112 /** |
| 2113 * Unlinked summary information about a specific name contributed by a |
| 2114 * compilation unit to a library's public namespace. |
| 2115 * |
| 2116 * TODO(paulberry): some of this information is redundant with information |
| 2117 * elsewhere in the summary. Consider reducing the redundancy to reduce |
| 2118 * summary size. |
| 2119 */ |
| 2120 table UnlinkedPublicName { |
| 2121 /** |
| 2122 * The kind of object referred to by the name. |
| 2123 */ |
| 2124 kind:ReferenceKind (id: 1); |
| 2125 |
| 2126 /** |
| 2127 * If this [UnlinkedPublicName] is a class, the list of members which can be |
| 2128 * referenced statically - static fields, static methods, and constructors. |
| 2129 * Otherwise empty. |
| 2130 * |
| 2131 * Unnamed constructors are not included since they do not constitute a |
| 2132 * separate name added to any namespace. |
| 2133 */ |
| 2134 members:[UnlinkedPublicName] (id: 2); |
| 2135 |
| 2136 /** |
| 2137 * The name itself. |
| 2138 */ |
| 2139 name:string (id: 0); |
| 2140 |
| 2141 /** |
| 2142 * If the entity being referred to is generic, the number of type parameters |
| 2143 * it accepts. Otherwise zero. |
| 2144 */ |
| 2145 numTypeParameters:uint (id: 3); |
| 2146 } |
| 2147 |
| 2148 /** |
| 2149 * Unlinked summary information about what a compilation unit contributes to a |
| 2150 * library's public namespace. This is the subset of [UnlinkedUnit] that is |
| 2151 * required from dependent libraries in order to perform prelinking. |
| 2152 */ |
| 2153 table UnlinkedPublicNamespace { |
| 2154 /** |
| 2155 * Export declarations in the compilation unit. |
| 2156 */ |
| 2157 exports:[UnlinkedExportPublic] (id: 2); |
| 2158 |
| 2159 /** |
| 2160 * Public names defined in the compilation unit. |
| 2161 * |
| 2162 * TODO(paulberry): consider sorting these names to reduce unnecessary |
| 2163 * relinking. |
| 2164 */ |
| 2165 names:[UnlinkedPublicName] (id: 0); |
| 2166 |
| 2167 /** |
| 2168 * URIs referenced by part declarations in the compilation unit. |
| 2169 */ |
| 2170 parts:[string] (id: 1); |
| 2171 } |
| 2172 |
| 2173 /** |
| 2174 * Unlinked summary information about a name referred to in one library that |
| 2175 * might be defined in another. |
| 2176 */ |
| 2177 table UnlinkedReference { |
| 2178 /** |
| 2179 * Name of the entity being referred to. For the pseudo-type `dynamic`, the |
| 2180 * string is "dynamic". For the pseudo-type `void`, the string is "void". |
| 2181 * For the pseudo-type `bottom`, the string is "*bottom*". |
| 2182 */ |
| 2183 name:string (id: 0); |
| 2184 |
| 2185 /** |
| 2186 * Prefix used to refer to the entity, or zero if no prefix is used. This is |
| 2187 * an index into [UnlinkedUnit.references]. |
| 2188 * |
| 2189 * Prefix references must always point backward; that is, for all i, if |
| 2190 * UnlinkedUnit.references[i].prefixReference != 0, then |
| 2191 * UnlinkedUnit.references[i].prefixReference < i. |
| 2192 */ |
| 2193 prefixReference:uint (id: 1); |
| 2194 } |
| 2195 |
| 2196 /** |
| 2197 * Unlinked summary information about a typedef declaration. |
| 2198 */ |
| 2199 table UnlinkedTypedef { |
| 2200 /** |
| 2201 * Annotations for this typedef. |
| 2202 */ |
| 2203 annotations:[UnlinkedConst] (id: 4); |
| 2204 |
| 2205 /** |
| 2206 * Code range of the typedef. |
| 2207 */ |
| 2208 codeRange:CodeRange (id: 7); |
| 2209 |
| 2210 /** |
| 2211 * Documentation comment for the typedef, or `null` if there is no |
| 2212 * documentation comment. |
| 2213 */ |
| 2214 documentationComment:UnlinkedDocumentationComment (id: 6); |
| 2215 |
| 2216 /** |
| 2217 * Name of the typedef. |
| 2218 */ |
| 2219 name:string (id: 0); |
| 2220 |
| 2221 /** |
| 2222 * Offset of the typedef name relative to the beginning of the file. |
| 2223 */ |
| 2224 nameOffset:uint (id: 1); |
| 2225 |
| 2226 /** |
| 2227 * Parameters of the executable, if any. |
| 2228 */ |
| 2229 parameters:[UnlinkedParam] (id: 3); |
| 2230 |
| 2231 /** |
| 2232 * Return type of the typedef. |
| 2233 */ |
| 2234 returnType:EntityRef (id: 2); |
| 2235 |
| 2236 /** |
| 2237 * Type parameters of the typedef, if any. |
| 2238 */ |
| 2239 typeParameters:[UnlinkedTypeParam] (id: 5); |
| 2240 } |
| 2241 |
| 2242 /** |
| 2243 * Unlinked summary information about a type parameter declaration. |
| 2244 */ |
| 2245 table UnlinkedTypeParam { |
| 2246 /** |
| 2247 * Annotations for this type parameter. |
| 2248 */ |
| 2249 annotations:[UnlinkedConst] (id: 3); |
| 2250 |
| 2251 /** |
| 2252 * Bound of the type parameter, if a bound is explicitly declared. Otherwise |
| 2253 * null. |
| 2254 */ |
| 2255 bound:EntityRef (id: 2); |
| 2256 |
| 2257 /** |
| 2258 * Code range of the type parameter. |
| 2259 */ |
| 2260 codeRange:CodeRange (id: 4); |
| 2261 |
| 2262 /** |
| 2263 * Name of the type parameter. |
| 2264 */ |
| 2265 name:string (id: 0); |
| 2266 |
| 2267 /** |
| 2268 * Offset of the type parameter name relative to the beginning of the file. |
| 2269 */ |
| 2270 nameOffset:uint (id: 1); |
| 2271 } |
| 2272 |
| 2273 /** |
| 2274 * Unlinked summary information about a compilation unit ("part file"). |
| 2275 */ |
| 2276 table UnlinkedUnit { |
| 2277 /** |
| 2278 * Classes declared in the compilation unit. |
| 2279 */ |
| 2280 classes:[UnlinkedClass] (id: 2); |
| 2281 |
| 2282 /** |
| 2283 * Code range of the unit. |
| 2284 */ |
| 2285 codeRange:CodeRange (id: 15); |
| 2286 |
| 2287 /** |
| 2288 * Enums declared in the compilation unit. |
| 2289 */ |
| 2290 enums:[UnlinkedEnum] (id: 12); |
| 2291 |
| 2292 /** |
| 2293 * Top level executable objects (functions, getters, and setters) declared in |
| 2294 * the compilation unit. |
| 2295 */ |
| 2296 executables:[UnlinkedExecutable] (id: 4); |
| 2297 |
| 2298 /** |
| 2299 * Export declarations in the compilation unit. |
| 2300 */ |
| 2301 exports:[UnlinkedExportNonPublic] (id: 13); |
| 2302 |
| 2303 /** |
| 2304 * If this compilation unit was summarized in fallback mode, the path where |
| 2305 * the compilation unit may be found on disk. Otherwise empty. |
| 2306 * |
| 2307 * When this field is non-empty, all other fields in the data structure have |
| 2308 * their default values. |
| 2309 */ |
| 2310 fallbackModePath:string (id: 16); |
| 2311 |
| 2312 /** |
| 2313 * Import declarations in the compilation unit. |
| 2314 */ |
| 2315 imports:[UnlinkedImport] (id: 5); |
| 2316 |
| 2317 /** |
| 2318 * Annotations for the library declaration, or the empty list if there is no |
| 2319 * library declaration. |
| 2320 */ |
| 2321 libraryAnnotations:[UnlinkedConst] (id: 14); |
| 2322 |
| 2323 /** |
| 2324 * Documentation comment for the library, or `null` if there is no |
| 2325 * documentation comment. |
| 2326 */ |
| 2327 libraryDocumentationComment:UnlinkedDocumentationComment (id: 9); |
| 2328 |
| 2329 /** |
| 2330 * Name of the library (from a "library" declaration, if present). |
| 2331 */ |
| 2332 libraryName:string (id: 6); |
| 2333 |
| 2334 /** |
| 2335 * Length of the library name as it appears in the source code (or 0 if the |
| 2336 * library has no name). |
| 2337 */ |
| 2338 libraryNameLength:uint (id: 7); |
| 2339 |
| 2340 /** |
| 2341 * Offset of the library name relative to the beginning of the file (or 0 if |
| 2342 * the library has no name). |
| 2343 */ |
| 2344 libraryNameOffset:uint (id: 8); |
| 2345 |
| 2346 /** |
| 2347 * Offsets of the first character of each line in the source code. |
| 2348 */ |
| 2349 lineStarts:[uint] (id: 17); |
| 2350 |
| 2351 /** |
| 2352 * Part declarations in the compilation unit. |
| 2353 */ |
| 2354 parts:[UnlinkedPart] (id: 11); |
| 2355 |
| 2356 /** |
| 2357 * Unlinked public namespace of this compilation unit. |
| 2358 */ |
| 2359 publicNamespace:UnlinkedPublicNamespace (id: 0); |
| 2360 |
| 2361 /** |
| 2362 * Top level and prefixed names referred to by this compilation unit. The |
| 2363 * zeroth element of this array is always populated and is used to represent |
| 2364 * the absence of a reference in places where a reference is optional (for |
| 2365 * example [UnlinkedReference.prefixReference or |
| 2366 * UnlinkedImport.prefixReference]). |
| 2367 */ |
| 2368 references:[UnlinkedReference] (id: 1); |
| 2369 |
| 2370 /** |
| 2371 * Typedefs declared in the compilation unit. |
| 2372 */ |
| 2373 typedefs:[UnlinkedTypedef] (id: 10); |
| 2374 |
| 2375 /** |
| 2376 * Top level variables declared in the compilation unit. |
| 2377 */ |
| 2378 variables:[UnlinkedVariable] (id: 3); |
| 2379 } |
| 2380 |
| 2381 /** |
| 2382 * Unlinked summary information about a top level variable, local variable, or |
| 2383 * a field. |
| 2384 */ |
| 2385 table UnlinkedVariable { |
| 2386 /** |
| 2387 * Annotations for this variable. |
| 2388 */ |
| 2389 annotations:[UnlinkedConst] (id: 8); |
| 2390 |
| 2391 /** |
| 2392 * Code range of the variable. |
| 2393 */ |
| 2394 codeRange:CodeRange (id: 5); |
| 2395 |
| 2396 /** |
| 2397 * Documentation comment for the variable, or `null` if there is no |
| 2398 * documentation comment. |
| 2399 */ |
| 2400 documentationComment:UnlinkedDocumentationComment (id: 10); |
| 2401 |
| 2402 /** |
| 2403 * If this variable is inferable, nonzero slot id identifying which entry in |
| 2404 * [LinkedLibrary.types] contains the inferred type for this variable. If |
| 2405 * there is no matching entry in [LinkedLibrary.types], then no type was |
| 2406 * inferred for this variable, so its static type is `dynamic`. |
| 2407 */ |
| 2408 inferredTypeSlot:uint (id: 9); |
| 2409 |
| 2410 /** |
| 2411 * The synthetic initializer function of the variable. Absent if the variable |
| 2412 * does not have an initializer. |
| 2413 */ |
| 2414 initializer:UnlinkedExecutable (id: 13); |
| 2415 |
| 2416 /** |
| 2417 * Indicates whether the variable is declared using the `const` keyword. |
| 2418 */ |
| 2419 isConst:bool (id: 6); |
| 2420 |
| 2421 /** |
| 2422 * Indicates whether the variable is declared using the `final` keyword. |
| 2423 */ |
| 2424 isFinal:bool (id: 7); |
| 2425 |
| 2426 /** |
| 2427 * Indicates whether the variable is declared using the `static` keyword. |
| 2428 * |
| 2429 * Note that for top level variables, this flag is false, since they are not |
| 2430 * declared using the `static` keyword (even though they are considered |
| 2431 * static for semantic purposes). |
| 2432 */ |
| 2433 isStatic:bool (id: 4); |
| 2434 |
| 2435 /** |
| 2436 * Name of the variable. |
| 2437 */ |
| 2438 name:string (id: 0); |
| 2439 |
| 2440 /** |
| 2441 * Offset of the variable name relative to the beginning of the file. |
| 2442 */ |
| 2443 nameOffset:uint (id: 1); |
| 2444 |
| 2445 /** |
| 2446 * If this variable is propagable, nonzero slot id identifying which entry in |
| 2447 * [LinkedLibrary.types] contains the propagated type for this variable. If |
| 2448 * there is no matching entry in [LinkedLibrary.types], then this variable's |
| 2449 * propagated type is the same as its declared type. |
| 2450 * |
| 2451 * Non-propagable variables have a [propagatedTypeSlot] of zero. |
| 2452 */ |
| 2453 propagatedTypeSlot:uint (id: 2); |
| 2454 |
| 2455 /** |
| 2456 * Declared type of the variable. Absent if the type is implicit. |
| 2457 */ |
| 2458 type:EntityRef (id: 3); |
| 2459 |
| 2460 /** |
| 2461 * If a local variable, the length of the visible range; zero otherwise. |
| 2462 */ |
| 2463 visibleLength:uint (id: 11); |
| 2464 |
| 2465 /** |
| 2466 * If a local variable, the beginning of the visible range; zero otherwise. |
| 2467 */ |
| 2468 visibleOffset:uint (id: 12); |
| 2469 } |
| 2470 |
| 2471 root_type PackageBundle; |
| 2472 |
| 2473 file_identifier "PBdl"; |
| OLD | NEW |