Skip to content

Commit 92f363a

Browse files
committed
Bump ClangSharp to 20.1.2.1
1 parent 2ecbb6a commit 92f363a

File tree

3 files changed

+14
-8
lines changed

3 files changed

+14
-8
lines changed

src/CppAst/CppAst.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<None Include="../../img/cppast.png" Pack="true" PackagePath="/logo.png" />
2727
<None Include="../../readme.md" Pack="true" PackagePath="/" />
2828

29-
<PackageReference Include="ClangSharp" Version="18.1.0.4" />
29+
<PackageReference Include="ClangSharp" Version="20.1.2.1" />
3030
</ItemGroup>
3131

3232
<ItemGroup>

src/CppAst/CppExpressionKind.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (c) Alexandre Mutel. All rights reserved.
1+
// Copyright (c) Alexandre Mutel. All rights reserved.
22
// Licensed under the BSD-Clause 2 license.
33
// See license.txt file in the project root for full license information.
44

@@ -53,7 +53,7 @@ public enum CppExpressionKind
5353
Lambda,
5454
ObjCBoolLiteral,
5555
ObjCSelf,
56-
OMPArraySection,
56+
OMP,
5757
ObjCAvailabilityCheck,
5858
FixedPointLiteral,
5959
}

src/CppAst/CppModelBuilder.cs

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1442,10 +1442,6 @@ private CppExpression VisitExpression(CXCursor cursor, void* data)
14421442
expr = new CppRawExpression(CppExpressionKind.ObjCSelf);
14431443
AppendTokensToExpression(cursor, expr);
14441444
break;
1445-
case CXCursorKind.CXCursor_OMPArraySectionExpr:
1446-
expr = new CppRawExpression(CppExpressionKind.OMPArraySection);
1447-
AppendTokensToExpression(cursor, expr);
1448-
break;
14491445
case CXCursorKind.CXCursor_ObjCAvailabilityCheckExpr:
14501446
expr = new CppRawExpression(CppExpressionKind.ObjCAvailabilityCheck);
14511447
AppendTokensToExpression(cursor, expr);
@@ -1454,7 +1450,17 @@ private CppExpression VisitExpression(CXCursor cursor, void* data)
14541450
expr = new CppLiteralExpression(CppExpressionKind.FixedPointLiteral, GetCursorAsText(cursor));
14551451
break;
14561452
default:
1457-
return null;
1453+
if (cursor.Kind.ToString().StartsWith("CXCursor_OMP"))
1454+
{
1455+
expr = new CppRawExpression(CppExpressionKind.OMP);
1456+
AppendTokensToExpression(cursor, expr);
1457+
}
1458+
else
1459+
{
1460+
return null;
1461+
}
1462+
1463+
break;
14581464
}
14591465

14601466
AssignSourceSpan(cursor, expr);

0 commit comments

Comments
 (0)