Skip to content

Commit a4cd913

Browse files
authored
Merge pull request #10312 from erik-krogh/fix-caseDiff
ensure consistent casing of names
2 parents b488087 + 03a325c commit a4cd913

File tree

234 files changed

+727
-654
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

234 files changed

+727
-654
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
category: deprecated
3+
---
4+
* Some classes/modules with upper-case acronyms in their name have been renamed to follow our style-guide.
5+
The old name still exists as a deprecated alias.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
private import SSAConstruction as SSA
2-
import SSA::SsaConsistency
1+
private import SSAConstruction as Ssa
2+
import Ssa::SsaConsistency

cpp/ql/lib/semmle/code/cpp/ir/implementation/aliased_ssa/internal/SSAConstruction.qll

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1135,7 +1135,7 @@ deprecated module SSAConsistency = SsaConsistency;
11351135
* These predicates are all just aliases for predicates defined in the `Cached` module. This ensures
11361136
* that all of SSA construction will be evaluated in the same stage.
11371137
*/
1138-
module SSA {
1138+
module Ssa {
11391139
class MemoryLocation = Alias::MemoryLocation;
11401140

11411141
predicate hasPhiInstruction = Cached::hasPhiInstructionCached/2;
@@ -1144,3 +1144,6 @@ module SSA {
11441144

11451145
predicate hasUnreachedInstruction = Cached::hasUnreachedInstructionCached/1;
11461146
}
1147+
1148+
/** DEPRECATED: Alias for Ssa */
1149+
deprecated module SSA = Ssa;

cpp/ql/lib/semmle/code/cpp/ir/implementation/internal/TInstruction.qll

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,24 +20,24 @@ newtype TInstruction =
2020
IRConstruction::Raw::hasInstruction(tag1, tag2)
2121
} or
2222
TUnaliasedSsaPhiInstruction(
23-
TRawInstruction blockStartInstr, UnaliasedSsa::SSA::MemoryLocation memoryLocation
23+
TRawInstruction blockStartInstr, UnaliasedSsa::Ssa::MemoryLocation memoryLocation
2424
) {
25-
UnaliasedSsa::SSA::hasPhiInstruction(blockStartInstr, memoryLocation)
25+
UnaliasedSsa::Ssa::hasPhiInstruction(blockStartInstr, memoryLocation)
2626
} or
2727
TUnaliasedSsaChiInstruction(TRawInstruction primaryInstruction) { none() } or
2828
TUnaliasedSsaUnreachedInstruction(IRFunctionBase irFunc) {
29-
UnaliasedSsa::SSA::hasUnreachedInstruction(irFunc)
29+
UnaliasedSsa::Ssa::hasUnreachedInstruction(irFunc)
3030
} or
3131
TAliasedSsaPhiInstruction(
32-
TRawInstruction blockStartInstr, AliasedSsa::SSA::MemoryLocation memoryLocation
32+
TRawInstruction blockStartInstr, AliasedSsa::Ssa::MemoryLocation memoryLocation
3333
) {
34-
AliasedSsa::SSA::hasPhiInstruction(blockStartInstr, memoryLocation)
34+
AliasedSsa::Ssa::hasPhiInstruction(blockStartInstr, memoryLocation)
3535
} or
3636
TAliasedSsaChiInstruction(TRawInstruction primaryInstruction) {
37-
AliasedSsa::SSA::hasChiInstruction(primaryInstruction)
37+
AliasedSsa::Ssa::hasChiInstruction(primaryInstruction)
3838
} or
3939
TAliasedSsaUnreachedInstruction(IRFunctionBase irFunc) {
40-
AliasedSsa::SSA::hasUnreachedInstruction(irFunc)
40+
AliasedSsa::Ssa::hasUnreachedInstruction(irFunc)
4141
}
4242

4343
/**
@@ -50,7 +50,7 @@ module UnaliasedSsaInstructions {
5050
class TPhiInstruction = TUnaliasedSsaPhiInstruction;
5151

5252
TPhiInstruction phiInstruction(
53-
TRawInstruction blockStartInstr, UnaliasedSsa::SSA::MemoryLocation memoryLocation
53+
TRawInstruction blockStartInstr, UnaliasedSsa::Ssa::MemoryLocation memoryLocation
5454
) {
5555
result = TUnaliasedSsaPhiInstruction(blockStartInstr, memoryLocation)
5656
}
@@ -83,7 +83,7 @@ module AliasedSsaInstructions {
8383
class TPhiInstruction = TAliasedSsaPhiInstruction or TUnaliasedSsaPhiInstruction;
8484

8585
TPhiInstruction phiInstruction(
86-
TRawInstruction blockStartInstr, AliasedSsa::SSA::MemoryLocation memoryLocation
86+
TRawInstruction blockStartInstr, AliasedSsa::Ssa::MemoryLocation memoryLocation
8787
) {
8888
result = TAliasedSsaPhiInstruction(blockStartInstr, memoryLocation)
8989
}
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
private import SSAConstruction as SSA
2-
import SSA::SsaConsistency
1+
private import SSAConstruction as Ssa
2+
import Ssa::SsaConsistency

cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/SSAConstruction.qll

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1135,7 +1135,7 @@ deprecated module SSAConsistency = SsaConsistency;
11351135
* These predicates are all just aliases for predicates defined in the `Cached` module. This ensures
11361136
* that all of SSA construction will be evaluated in the same stage.
11371137
*/
1138-
module SSA {
1138+
module Ssa {
11391139
class MemoryLocation = Alias::MemoryLocation;
11401140

11411141
predicate hasPhiInstruction = Cached::hasPhiInstructionCached/2;
@@ -1144,3 +1144,6 @@ module SSA {
11441144

11451145
predicate hasUnreachedInstruction = Cached::hasUnreachedInstructionCached/1;
11461146
}
1147+
1148+
/** DEPRECATED: Alias for Ssa */
1149+
deprecated module SSA = Ssa;
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
category: deprecated
3+
---
4+
* Some classes/modules with upper-case acronyms in their name have been renamed to follow our style-guide.
5+
The old name still exists as a deprecated alias.

csharp/ql/lib/semmle/code/cil/CallableReturns.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ private predicate alwaysNotNullVariableUpdate(VariableUpdate vu) {
5656

5757
/** Holds if expression `expr` always evaluates to non-null. */
5858
private predicate alwaysNotNullExpr(Expr expr) {
59-
expr instanceof Opcodes::Newobj
59+
expr instanceof Opcodes::NewObj
6060
or
6161
expr instanceof Literal and not expr instanceof NullLiteral
6262
or

csharp/ql/lib/semmle/code/cil/Instructions.qll

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -766,7 +766,7 @@ module Opcodes {
766766
}
767767

768768
/** A `newobj` instruction. */
769-
class Newobj extends Call, @cil_newobj {
769+
class NewObj extends Call, @cil_newobj {
770770
override string getOpcodeName() { result = "newobj" }
771771

772772
override int getPushCount() { result = 1 }
@@ -788,6 +788,9 @@ module Opcodes {
788788
}
789789
}
790790

791+
/** DEPRECATED: Alias for NewObj */
792+
deprecated class Newobj = NewObj;
793+
791794
/** An `initobj` instruction. */
792795
class Initobj extends Instruction, @cil_initobj {
793796
override string getOpcodeName() { result = "initobj" }
@@ -847,10 +850,13 @@ module Opcodes {
847850
}
848851

849852
/** A `rethrow` instruction. */
850-
class Rethrow extends Throw, @cil_rethrow {
853+
class ReThrow extends Throw, @cil_rethrow {
851854
override string getOpcodeName() { result = "rethrow" }
852855
}
853856

857+
/** DEPRECATED: Alias for ReThrow */
858+
deprecated class Rethrow = ReThrow;
859+
854860
/** A `ldlen` instruction. */
855861
class Ldlen extends UnaryExpr, @cil_ldlen {
856862
override string getOpcodeName() { result = "ldlen" }

csharp/ql/src/experimental/ir/implementation/internal/AliasedSSAStub.qll

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
private import IRFunctionBase
77
private import TInstruction
88

9-
module SSA {
9+
module Ssa {
1010
class MemoryLocation = boolean;
1111

1212
predicate hasPhiInstruction(TRawInstruction blockStartInstr, MemoryLocation memoryLocation) {
@@ -17,3 +17,6 @@ module SSA {
1717

1818
predicate hasUnreachedInstruction(IRFunctionBase irFunc) { none() }
1919
}
20+
21+
/** DEPRECATED: Alias for Ssa */
22+
deprecated module SSA = Ssa;

0 commit comments

Comments
 (0)