summaryrefslogtreecommitdiffstats
path: root/debian/patches/fix-typescript.patch
blob: c7cac74657f324ad9fda10f20ce8e489dd0de0e0 (plain)
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
Description: fix typescript
Author: Yadd <yadd@debian.org>
Forwarded: no
Last-Update: 2022-07-30

--- a/llhttp/bin/build_wasm.ts
+++ b/llhttp/bin/build_wasm.ts
@@ -40,6 +40,7 @@
   // It will work flawessly if uid === gid === 1000
   // there will be some warnings otherwise.
   if (process.platform === 'linux') {
+// @ts-ignore
     cmd += ` --user ${process.getuid()}:${process.getegid()}`;
   }
   cmd += ` --mount type=bind,source=${WASM_SRC}/build,target=/home/node/llhttp/build llhttp_wasm_builder npm run wasm`;
--- a/llparse/src/implementation/c/code/base.ts
+++ b/llparse/src/implementation/c/code/base.ts
@@ -3,7 +3,7 @@
 import { Compilation } from '../compilation';
 
 export abstract class Code<T extends frontend.code.Code> {
-  protected cachedDecl: string | undefined;
+  public cachedDecl: string | undefined;
 
   constructor(public readonly ref: T) {
   }
--- a/llparse/src/implementation/c/node/base.ts
+++ b/llparse/src/implementation/c/node/base.ts
@@ -13,8 +13,8 @@
 }
 
 export abstract class Node<T extends frontend.node.Node> {
-  protected cachedDecl: string | undefined;
-  protected privCompilation: Compilation | undefined;
+  public cachedDecl: string | undefined;
+  public privCompilation: Compilation | undefined;
 
   constructor(public readonly ref: T) {
   }
@@ -39,12 +39,12 @@
     return res;
   }
 
-  protected get compilation(): Compilation {
+  public get compilation(): Compilation {
     assert(this.privCompilation !== undefined);
     return this.privCompilation!;
   }
 
-  protected prologue(out: string[]): void {
+  public prologue(out: string[]): void {
     const ctx = this.compilation;
 
     out.push(`if (${ctx.posArg()} == ${ctx.endPosArg()}) {`);
@@ -56,11 +56,11 @@
     out.push('}');
   }
 
-  protected pause(out: string[]): void {
+  public pause(out: string[]): void {
     out.push(`return ${this.cachedDecl};`);
   }
 
-  protected tailTo(out: string[], edge: INodeEdge): void {
+  public tailTo(out: string[], edge: INodeEdge): void {
     const ctx = this.compilation;
     const target = ctx.unwrapNode(edge.node).build(ctx);
 
--- a/llparse/src/implementation/c/node/error.ts
+++ b/llparse/src/implementation/c/node/error.ts
@@ -5,7 +5,7 @@
 import { Node } from './base';
 
 class ErrorNode<T extends frontend.node.Error> extends Node<T> {
-  protected storeError(out: string[]): void {
+  public storeError(out: string[]): void {
     const ctx = this.compilation;
 
     let hexCode: string;