Skip to content

Commit f6a9f96

Browse files
committed
Fix a /permissive- error: make type name PNode explicit.
Found while investigating #1942
1 parent 9bcbdd9 commit f6a9f96

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/Parser/ParseTreeComparer.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ namespace Js
1616
template <class SubClass, class Allocator>
1717
class ParseTreeComparer : public TreeComparerBase<SubClass, ParseNode>
1818
{
19+
public:
20+
using PNode = TreeComparerBase<SubClass, ParseNode>::PNode; // make the type explicit for /permissive-
21+
1922
private:
2023
static const int TOKENLIST_MAXDIFF_SHIFT = 3; // Used to detect lists of significantly different lengths
2124

@@ -205,6 +208,8 @@ namespace Js
205208
class FunctionTreeComparer : public ParseTreeComparer<FunctionTreeComparer<Allocator>, Allocator>
206209
{
207210
public:
211+
using PNode = ParseTreeComparer<FunctionTreeComparer<Allocator>, Allocator>::PNode;
212+
208213
FunctionTreeComparer(Allocator* alloc) : ParseTreeComparer(alloc) {}
209214
FunctionTreeComparer(const FunctionTreeComparer& other) : ParseTreeComparer(other) {}
210215

0 commit comments

Comments
 (0)