• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Camelcade / Perl5-IDEA / #525521592

24 Jun 2025 06:27AM UTC coverage: 82.368% (+0.02%) from 82.347%
#525521592

push

github

hurricup
Bump org.jetbrains.kotlin.jvm from 2.1.21 to 2.2.0

Bumps [org.jetbrains.kotlin.jvm](https://github.com/JetBrains/kotlin) from 2.1.21 to 2.2.0.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/v2.2.0/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/compare/v2.1.21...v2.2.0)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin.jvm
  dependency-version: 2.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

30869 of 37477 relevant lines covered (82.37%)

0.82 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

85.0
/mason/mason2/core/src/main/java/com/perl5/lang/mason2/elementType/MasonNamespaceElementType.java
1
/*
2
 * Copyright 2015-2025 Alexandr Evstigneev
3
 *
4
 * Licensed under the Apache License, Version 2.0 (the "License");
5
 * you may not use this file except in compliance with the License.
6
 * You may obtain a copy of the License at
7
 *
8
 * http://www.apache.org/licenses/LICENSE-2.0
9
 *
10
 * Unless required by applicable law or agreed to in writing, software
11
 * distributed under the License is distributed on an "AS IS" BASIS,
12
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
 * See the License for the specific language governing permissions and
14
 * limitations under the License.
15
 */
16

17
package com.perl5.lang.mason2.elementType;
18

19
import com.intellij.lang.ASTNode;
20
import com.intellij.openapi.util.text.StringUtil;
21
import com.intellij.psi.PsiElement;
22
import com.intellij.psi.stubs.IndexSink;
23
import com.intellij.psi.stubs.StubElement;
24
import com.perl5.lang.mason2.Mason2Language;
25
import com.perl5.lang.mason2.Mason2Util;
26
import com.perl5.lang.mason2.psi.MasonNamespaceDefinition;
27
import com.perl5.lang.mason2.psi.impl.MasonNamespaceDefinitionImpl;
28
import com.perl5.lang.mason2.psi.stubs.MasonNamespaceDefitnitionsStubIndex;
29
import com.perl5.lang.mason2.psi.stubs.MasonParentNamespacesStubIndex;
30
import com.perl5.lang.perl.parser.elementTypes.PsiElementProvider;
31
import com.perl5.lang.perl.psi.PerlNamespaceDefinitionElement;
32
import com.perl5.lang.perl.psi.stubs.namespaces.PerlNamespaceDefinitionData;
33
import com.perl5.lang.perl.psi.stubs.namespaces.PerlNamespaceDefinitionElementType;
34
import com.perl5.lang.perl.psi.stubs.namespaces.PerlNamespaceDefinitionStub;
35
import org.jetbrains.annotations.NotNull;
36

37
import static com.perl5.lang.perl.psi.stubs.namespaces.PerlNamespaceIndex.NAMESPACE_KEY;
38

39

40
public class MasonNamespaceElementType extends PerlNamespaceDefinitionElementType implements PsiElementProvider {
1✔
41
  public MasonNamespaceElementType(String name) {
42
    super(name, Mason2Language.INSTANCE);
1✔
43
  }
1✔
44

45
  @Override
46
  public PerlNamespaceDefinitionElement createPsi(@NotNull PerlNamespaceDefinitionStub stub) {
47
    return new MasonNamespaceDefinitionImpl(stub, this);
1✔
48
  }
49

50
  @Override
51
  public @NotNull PerlNamespaceDefinitionStub createStub(@NotNull PerlNamespaceDefinitionElement psi, StubElement parentStub) {
52
    assert psi instanceof MasonNamespaceDefinitionImpl;
1✔
53
    return new PerlNamespaceDefinitionStub(parentStub, this, new PerlNamespaceDefinitionData(
1✔
54
      StringUtil.notNullize(((MasonNamespaceDefinitionImpl)psi).getAbsoluteComponentPath()), psi));
1✔
55
  }
56

57
  @Override
58
  public void indexStub(@NotNull PerlNamespaceDefinitionStub stub, @NotNull IndexSink sink) {
59
    String name = stub.getNamespaceName();
1✔
60
    sink.occurrence(MasonNamespaceDefitnitionsStubIndex.KEY, name);
1✔
61

62
    // fixme this is kinda hack to make MRO work. But, it should be smarter
63
    sink.occurrence(NAMESPACE_KEY, Mason2Util.getClassnameFromPath(name));
1✔
64

65
    for (String parent : stub.getParentNamespacesNames()) {
1✔
66
      if (parent != null && !parent.isEmpty()) {
×
67
        sink.occurrence(MasonParentNamespacesStubIndex.KEY, parent);
×
68
      }
69
    }
×
70
  }
1✔
71

72
  @Override
73
  public boolean shouldCreateStub(ASTNode node) {
74
    PsiElement psi = node.getPsi();
1✔
75
    return psi instanceof MasonNamespaceDefinition namespaceDefinition &&
1✔
76
           psi.isValid() &&
1✔
77
           StringUtil.isNotEmpty(namespaceDefinition.getAbsoluteComponentPath());
1✔
78
  }
79

80
  @Override
81
  public @NotNull PsiElement getPsiElement(@NotNull ASTNode node) {
82
    return new MasonNamespaceDefinitionImpl(node);
1✔
83
  }
84
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc