Skip to content

Commit ce6be1f

Browse files
committed
Dataflow: Instantiate stage 1 access paths with proper unit type
1 parent 71c37db commit ce6be1f

File tree

8 files changed

+8
-40
lines changed

8 files changed

+8
-40
lines changed

cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -445,11 +445,7 @@ module Impl<FullStateConfigSig Config> {
445445
}
446446

447447
private module Stage1 implements StageSig {
448-
class Ap extends int {
449-
// workaround for bad functionality-induced joins (happens when using `Unit`)
450-
pragma[nomagic]
451-
Ap() { this in [0 .. 1] and this < 1 }
452-
}
448+
class Ap = Unit;
453449

454450
private class Cc = boolean;
455451

cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -445,11 +445,7 @@ module Impl<FullStateConfigSig Config> {
445445
}
446446

447447
private module Stage1 implements StageSig {
448-
class Ap extends int {
449-
// workaround for bad functionality-induced joins (happens when using `Unit`)
450-
pragma[nomagic]
451-
Ap() { this in [0 .. 1] and this < 1 }
452-
}
448+
class Ap = Unit;
453449

454450
private class Cc = boolean;
455451

csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlowImpl.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -445,11 +445,7 @@ module Impl<FullStateConfigSig Config> {
445445
}
446446

447447
private module Stage1 implements StageSig {
448-
class Ap extends int {
449-
// workaround for bad functionality-induced joins (happens when using `Unit`)
450-
pragma[nomagic]
451-
Ap() { this in [0 .. 1] and this < 1 }
452-
}
448+
class Ap = Unit;
453449

454450
private class Cc = boolean;
455451

go/ql/lib/semmle/go/dataflow/internal/DataFlowImpl.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -445,11 +445,7 @@ module Impl<FullStateConfigSig Config> {
445445
}
446446

447447
private module Stage1 implements StageSig {
448-
class Ap extends int {
449-
// workaround for bad functionality-induced joins (happens when using `Unit`)
450-
pragma[nomagic]
451-
Ap() { this in [0 .. 1] and this < 1 }
452-
}
448+
class Ap = Unit;
453449

454450
private class Cc = boolean;
455451

java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImpl.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -445,11 +445,7 @@ module Impl<FullStateConfigSig Config> {
445445
}
446446

447447
private module Stage1 implements StageSig {
448-
class Ap extends int {
449-
// workaround for bad functionality-induced joins (happens when using `Unit`)
450-
pragma[nomagic]
451-
Ap() { this in [0 .. 1] and this < 1 }
452-
}
448+
class Ap = Unit;
453449

454450
private class Cc = boolean;
455451

python/ql/lib/semmle/python/dataflow/new/internal/DataFlowImpl.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -445,11 +445,7 @@ module Impl<FullStateConfigSig Config> {
445445
}
446446

447447
private module Stage1 implements StageSig {
448-
class Ap extends int {
449-
// workaround for bad functionality-induced joins (happens when using `Unit`)
450-
pragma[nomagic]
451-
Ap() { this in [0 .. 1] and this < 1 }
452-
}
448+
class Ap = Unit;
453449

454450
private class Cc = boolean;
455451

ruby/ql/lib/codeql/ruby/dataflow/internal/DataFlowImpl.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -445,11 +445,7 @@ module Impl<FullStateConfigSig Config> {
445445
}
446446

447447
private module Stage1 implements StageSig {
448-
class Ap extends int {
449-
// workaround for bad functionality-induced joins (happens when using `Unit`)
450-
pragma[nomagic]
451-
Ap() { this in [0 .. 1] and this < 1 }
452-
}
448+
class Ap = Unit;
453449

454450
private class Cc = boolean;
455451

swift/ql/lib/codeql/swift/dataflow/internal/DataFlowImpl.qll

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -445,11 +445,7 @@ module Impl<FullStateConfigSig Config> {
445445
}
446446

447447
private module Stage1 implements StageSig {
448-
class Ap extends int {
449-
// workaround for bad functionality-induced joins (happens when using `Unit`)
450-
pragma[nomagic]
451-
Ap() { this in [0 .. 1] and this < 1 }
452-
}
448+
class Ap = Unit;
453449

454450
private class Cc = boolean;
455451

0 commit comments

Comments
 (0)