backport: 11.1.0
ci: 11.1.0 (cherry picked from commit 05826d40e5d98fee3c3cabc6c012ed58682521e8) chore: Simpler cross-release version tracking (cherry picked from commit4f612f33e7
) grammar: update to latest langref (cherry picked from commit7b867d4f0b
) chore: ignore signing script file (cherry picked from commita21dddba19
)
This commit is contained in:
parent
5d138e4c27
commit
11c5eb0b85
6 changed files with 40 additions and 17 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -146,3 +146,4 @@ gradle-app.setting
|
|||
|
||||
jbr
|
||||
secrets
|
||||
.idea/runConfigurations/Sign_Plugin.xml
|
|
@ -18,6 +18,13 @@ Changelog structure reference:
|
|||
|
||||
## [Unreleased]
|
||||
|
||||
## [11.1.0]
|
||||
|
||||
### Changed
|
||||
|
||||
- Zig
|
||||
- Updated to latest language grammar (destructuring syntax)
|
||||
|
||||
## [11.0.0]
|
||||
|
||||
### Changed
|
||||
|
|
|
@ -43,6 +43,10 @@ tasks {
|
|||
}
|
||||
}
|
||||
|
||||
fun getPluginVersionFull(): Provider<String> {
|
||||
return properties("pluginVersion").map { it + "-" + properties("pluginSinceBuild").get() }
|
||||
}
|
||||
|
||||
allprojects {
|
||||
apply {
|
||||
plugin("org.jetbrains.grammarkit")
|
||||
|
@ -84,7 +88,7 @@ allprojects {
|
|||
}
|
||||
|
||||
group = properties("pluginGroup").get()
|
||||
version = properties("pluginVersion").get()
|
||||
version = getPluginVersionFull().get()
|
||||
|
||||
tasks {
|
||||
runIde { enabled = false }
|
||||
|
@ -303,7 +307,7 @@ project(":plugin") {
|
|||
}
|
||||
|
||||
patchPluginXml {
|
||||
version = properties("pluginVersion")
|
||||
version = getPluginVersionFull()
|
||||
|
||||
// Extract the <!-- Plugin description --> section from README.md and provide for the plugin's manifest
|
||||
pluginDescription = providers.fileContents(rootProject.layout.projectDirectory.file("README.md")).asText.map {
|
||||
|
|
|
@ -2,7 +2,7 @@ pluginGroup = com.falsepattern.zigbrains
|
|||
pluginName = ZigBrains
|
||||
pluginRepositoryUrl = https://github.com/FalsePattern/ZigBrains
|
||||
# SemVer format -> https://semver.org
|
||||
pluginVersion = 11.0.0-232
|
||||
pluginVersion = 11.1.0
|
||||
|
||||
# Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html
|
||||
pluginSinceBuild = 232
|
||||
|
|
|
@ -35,7 +35,7 @@ public abstract class ZigTopLevelDeclarationLineMarkerContributorBase extends Ru
|
|||
|
||||
int nestingLevel = 0;
|
||||
while (parent != null && !(parent instanceof PsiFile)) {
|
||||
if (PsiUtil.getElementType(parent) == ZigTypes.CONTAINER_DECLARATION) {
|
||||
if (PsiUtil.getElementType(parent) == ZigTypes.CONTAINER_DECLARATIONS) {
|
||||
nestingLevel++;
|
||||
}
|
||||
parent = parent.getParent();
|
||||
|
|
|
@ -168,12 +168,9 @@
|
|||
Root ::= CONTAINER_DOC_COMMENT? ContainerMembers?
|
||||
|
||||
// *** Top level ***
|
||||
private ContainerMembers ::= ContainerDeclaration* (ContainerField COMMA)* (ContainerField | ContainerDeclaration*)?
|
||||
private ContainerMembers ::= ContainerDeclarations (ContainerField COMMA)* (ContainerField | ContainerDeclarations)?
|
||||
|
||||
ContainerDeclaration
|
||||
::= TestDecl
|
||||
| ComptimeDecl
|
||||
| DOC_COMMENT? KEYWORD_PUB? Decl
|
||||
ContainerDeclarations ::= (TestDecl | ComptimeDecl | DOC_COMMENT? KEYWORD_PUB? Decl)*
|
||||
|
||||
|
||||
TestDecl ::= DOC_COMMENT? KEYWORD_TEST (STRING_LITERAL_SINGLE | IDENTIFIER)? Block
|
||||
|
@ -181,13 +178,15 @@ TestDecl ::= DOC_COMMENT? KEYWORD_TEST (STRING_LITERAL_SINGLE | IDENTIFIER)? Blo
|
|||
ComptimeDecl ::= KEYWORD_COMPTIME Block
|
||||
|
||||
Decl
|
||||
::= (KEYWORD_EXPORT | KEYWORD_EXTERN STRING_LITERAL_SINGLE? | (KEYWORD_INLINE | KEYWORD_NOILINE))? FnProto (SEMICOLON | Block)
|
||||
| (KEYWORD_EXPORT | KEYWORD_EXTERN STRING_LITERAL_SINGLE?)? KEYWORD_THREADLOCAL? VarDecl
|
||||
::= (KEYWORD_EXPORT | KEYWORD_EXTERN STRING_LITERAL_SINGLE? | KEYWORD_INLINE | KEYWORD_NOILINE)? FnProto (SEMICOLON | Block)
|
||||
| (KEYWORD_EXPORT | KEYWORD_EXTERN STRING_LITERAL_SINGLE?)? KEYWORD_THREADLOCAL? GlobalVarDecl
|
||||
| KEYWORD_USINGNAMESPACE Expr SEMICOLON
|
||||
|
||||
FnProto ::= KEYWORD_FN IDENTIFIER? LPAREN ParamDeclList RPAREN ByteAlign? AddrSpace? LinkSection? CallConv? EXCLAMATIONMARK? TypeExpr
|
||||
|
||||
VarDecl ::= (KEYWORD_CONST | KEYWORD_VAR) IDENTIFIER (COLON TypeExpr)? ByteAlign? AddrSpace? LinkSection? (EQUAL Expr)? SEMICOLON
|
||||
VarDeclProto ::= (KEYWORD_CONST | KEYWORD_VAR) IDENTIFIER (COLON TypeExpr)? ByteAlign? AddrSpace? LinkSection?
|
||||
|
||||
GlobalVarDecl ::= VarDeclProto (EQUAL Expr)? SEMICOLON
|
||||
|
||||
ContainerField
|
||||
::= DOC_COMMENT? KEYWORD_COMPTIME? IDENTIFIER (COLON (KEYWORD_ANYTYPE | TypeExpr) ByteAlign?)? (EQUAL Expr)?
|
||||
|
@ -195,15 +194,18 @@ ContainerField
|
|||
|
||||
// *** Block Level ***
|
||||
Statement
|
||||
::= KEYWORD_COMPTIME? VarDecl
|
||||
| KEYWORD_COMPTIME BlockExprStatement
|
||||
::= KEYWORD_COMPTIME? ComptimeStatement
|
||||
| KEYWORD_NOSUSPEND BlockExprStatement
|
||||
| KEYWORD_DEFER BlockExprStatement
|
||||
| KEYWORD_ERRDEFER Payload? BlockExprStatement
|
||||
| IfStatement
|
||||
| LabeledStatement
|
||||
| SwitchExpr
|
||||
| AssignExpr SEMICOLON
|
||||
| VarDeclExprStatement
|
||||
|
||||
ComptimeStatement
|
||||
::= BlockExpr
|
||||
| VarDeclExprStatement
|
||||
|
||||
IfStatement
|
||||
::= IfPrefix BlockExpr ( KEYWORD_ELSE Payload? Statement )?
|
||||
|
@ -227,8 +229,17 @@ BlockExprStatement
|
|||
|
||||
BlockExpr ::= BlockLabel? Block
|
||||
|
||||
//An expression, assignment, or any destructure, as a statement.
|
||||
VarDeclExprStatement
|
||||
::= VarDeclProto (COMMA (VarDeclProto | Expr))* EQUAL Expr SEMICOLON
|
||||
| Expr (AssignOp Expr | (COMMA (VarDeclProto | Expr))+ EQUAL Expr)? SEMICOLON
|
||||
|
||||
// *** Expression Level ***
|
||||
AssignExpr ::= Expr (AssignOp Expr)?
|
||||
|
||||
// An assignment or a destructure whose LHS are all lvalue expressions.
|
||||
AssignExpr ::= Expr (AssignOp Expr | (COMMA Expr)+ EQUAL Expr)?
|
||||
|
||||
SingleAssignExpr ::= Expr (AssignOp Expr)?
|
||||
|
||||
Expr ::= BoolOrExpr
|
||||
|
||||
|
@ -382,7 +393,7 @@ PtrPayload ::= PIPE ASTERISK? IDENTIFIER PIPE
|
|||
PtrIndexPayload ::= PIPE (ASTERISK? IDENTIFIER COMMA)* (ASTERISK? IDENTIFIER) PIPE
|
||||
|
||||
// Switch specific
|
||||
SwitchProng ::= KEYWORD_INLINE? SwitchCase EQUALRARROW PtrIndexPayload? AssignExpr
|
||||
SwitchProng ::= KEYWORD_INLINE? SwitchCase EQUALRARROW PtrIndexPayload? SingleAssignExpr
|
||||
|
||||
SwitchCase
|
||||
::= SwitchItem (COMMA SwitchItem)* COMMA?
|
||||
|
|
Loading…
Add table
Reference in a new issue