All files / TRANSPILE/1-Analyze/types IIncludeContext.ts

0% Statements 0/0
0% Branches 0/0
0% Functions 0/0
0% Lines 0/0

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35                                                                     
import type EFileType from "../../../PARSE/1-Discover/types/EFileType";
 
/**
 * ADR-010 facts about the file under analysis: 1.1 Discover's answers, read
 * rather than re-derived (#1672).
 *
 * Every map is keyed by `IncludeDirectiveText.join`. #1322 and #1435
 * handed this pass discovery's INPUTS instead -- the search path, the
 * quoted-include directory and a file-exists oracle -- and it made its own
 * decision with them, along its own branch between the two forms. That
 * decision missed an absolute angle include discovery resolves, and asked the
 * file system a second time, so the two could answer differently.
 */
interface IIncludeContext {
  /** The file each directive resolved to, or null: E0506's question. */
  readonly resolutions: ReadonlyMap<string, string | null>;
 
  /**
   * For each include of a header whose C-Next source the same form of include
   * would find, that source's spelling: E0504's question. An include with no
   * entry has none.
   */
  readonly cnextAlternatives: ReadonlyMap<string, string>;
 
  /**
   * The kind of file each directive's spelling names (#1444, owner ruling 1):
   * E0503's question and half of E0506's. 2.1 kept its own extension list for
   * E0503 and asked discovery's classifier for E0506; the list had already
   * diverged from discovery on `.c++` (#1840).
   */
  readonly kinds: ReadonlyMap<string, EFileType>;
}
 
export default IIncludeContext;