From 537db53a8d2776c56d07bf031ec7f78cb1c4d985 Mon Sep 17 00:00:00 2001 From: Robert Marsh Date: Fri, 1 May 2020 14:12:44 -0700 Subject: [PATCH 1/2] C++/C#: improve qldoc on IR get*ResultExpression --- .../code/cpp/ir/implementation/aliased_ssa/Instruction.qll | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/Instruction.qll b/cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/Instruction.qll index 38216872f2b8..780f636ff101 100644 --- a/cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/Instruction.qll +++ b/cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/Instruction.qll @@ -190,14 +190,15 @@ class Instruction extends Construction::TInstruction { final Language::Location getLocation() { result = getAST().getLocation() } /** - * Gets the `Expr` whose result is computed by this instruction, if any. + * Gets the `Expr` whose result is computed by this instruction, if any. The `Expr` may be a + * conversion. */ final Language::Expr getConvertedResultExpression() { result = Construction::getInstructionConvertedResultExpression(this) } /** - * Gets the unconverted `Expr` whose result is computed by this instruction, if any. + * Gets the unconverted form of the `Expr` whose result is computed by this instruction, if any. */ final Language::Expr getUnconvertedResultExpression() { result = Construction::getInstructionUnconvertedResultExpression(this) From 83e222e5bd71d24795d040eeb36b6c5c2855424c Mon Sep 17 00:00:00 2001 From: Robert Marsh Date: Fri, 1 May 2020 14:17:43 -0700 Subject: [PATCH 2/2] C++/C#: sync files --- .../semmle/code/cpp/ir/implementation/raw/Instruction.qll | 5 +++-- .../code/cpp/ir/implementation/unaliased_ssa/Instruction.qll | 5 +++-- .../semmle/code/csharp/ir/implementation/raw/Instruction.qll | 5 +++-- .../csharp/ir/implementation/unaliased_ssa/Instruction.qll | 5 +++-- 4 files changed, 12 insertions(+), 8 deletions(-) diff --git a/cpp/ql/src/semmle/code/cpp/ir/implementation/raw/Instruction.qll b/cpp/ql/src/semmle/code/cpp/ir/implementation/raw/Instruction.qll index 38216872f2b8..780f636ff101 100644 --- a/cpp/ql/src/semmle/code/cpp/ir/implementation/raw/Instruction.qll +++ b/cpp/ql/src/semmle/code/cpp/ir/implementation/raw/Instruction.qll @@ -190,14 +190,15 @@ class Instruction extends Construction::TInstruction { final Language::Location getLocation() { result = getAST().getLocation() } /** - * Gets the `Expr` whose result is computed by this instruction, if any. + * Gets the `Expr` whose result is computed by this instruction, if any. The `Expr` may be a + * conversion. */ final Language::Expr getConvertedResultExpression() { result = Construction::getInstructionConvertedResultExpression(this) } /** - * Gets the unconverted `Expr` whose result is computed by this instruction, if any. + * Gets the unconverted form of the `Expr` whose result is computed by this instruction, if any. */ final Language::Expr getUnconvertedResultExpression() { result = Construction::getInstructionUnconvertedResultExpression(this) diff --git a/cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/Instruction.qll b/cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/Instruction.qll index 38216872f2b8..780f636ff101 100644 --- a/cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/Instruction.qll +++ b/cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/Instruction.qll @@ -190,14 +190,15 @@ class Instruction extends Construction::TInstruction { final Language::Location getLocation() { result = getAST().getLocation() } /** - * Gets the `Expr` whose result is computed by this instruction, if any. + * Gets the `Expr` whose result is computed by this instruction, if any. The `Expr` may be a + * conversion. */ final Language::Expr getConvertedResultExpression() { result = Construction::getInstructionConvertedResultExpression(this) } /** - * Gets the unconverted `Expr` whose result is computed by this instruction, if any. + * Gets the unconverted form of the `Expr` whose result is computed by this instruction, if any. */ final Language::Expr getUnconvertedResultExpression() { result = Construction::getInstructionUnconvertedResultExpression(this) diff --git a/csharp/ql/src/semmle/code/csharp/ir/implementation/raw/Instruction.qll b/csharp/ql/src/semmle/code/csharp/ir/implementation/raw/Instruction.qll index 38216872f2b8..780f636ff101 100644 --- a/csharp/ql/src/semmle/code/csharp/ir/implementation/raw/Instruction.qll +++ b/csharp/ql/src/semmle/code/csharp/ir/implementation/raw/Instruction.qll @@ -190,14 +190,15 @@ class Instruction extends Construction::TInstruction { final Language::Location getLocation() { result = getAST().getLocation() } /** - * Gets the `Expr` whose result is computed by this instruction, if any. + * Gets the `Expr` whose result is computed by this instruction, if any. The `Expr` may be a + * conversion. */ final Language::Expr getConvertedResultExpression() { result = Construction::getInstructionConvertedResultExpression(this) } /** - * Gets the unconverted `Expr` whose result is computed by this instruction, if any. + * Gets the unconverted form of the `Expr` whose result is computed by this instruction, if any. */ final Language::Expr getUnconvertedResultExpression() { result = Construction::getInstructionUnconvertedResultExpression(this) diff --git a/csharp/ql/src/semmle/code/csharp/ir/implementation/unaliased_ssa/Instruction.qll b/csharp/ql/src/semmle/code/csharp/ir/implementation/unaliased_ssa/Instruction.qll index 38216872f2b8..780f636ff101 100644 --- a/csharp/ql/src/semmle/code/csharp/ir/implementation/unaliased_ssa/Instruction.qll +++ b/csharp/ql/src/semmle/code/csharp/ir/implementation/unaliased_ssa/Instruction.qll @@ -190,14 +190,15 @@ class Instruction extends Construction::TInstruction { final Language::Location getLocation() { result = getAST().getLocation() } /** - * Gets the `Expr` whose result is computed by this instruction, if any. + * Gets the `Expr` whose result is computed by this instruction, if any. The `Expr` may be a + * conversion. */ final Language::Expr getConvertedResultExpression() { result = Construction::getInstructionConvertedResultExpression(this) } /** - * Gets the unconverted `Expr` whose result is computed by this instruction, if any. + * Gets the unconverted form of the `Expr` whose result is computed by this instruction, if any. */ final Language::Expr getUnconvertedResultExpression() { result = Construction::getInstructionUnconvertedResultExpression(this)