Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

C#/Java: Content based model generation improvements. #17363

Merged
merged 10 commits into from
Sep 19, 2024
Prev Previous commit
Next Next commit
Java: Add content based example with multiple paths.
  • Loading branch information
michaelnebel committed Sep 10, 2024
commit 0fbeca14ada61483465b0b3528485bc816a4a929
13 changes: 13 additions & 0 deletions java/ql/test/utils/modelgenerator/dataflow/p/MultiPaths.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package p;

public class MultiPaths {

// summary=p;MultiPaths;true;cond;(String,String);;Argument[0];ReturnValue;taint;df-generated
// contentbased-summary=p;MultiPaths;true;cond;(String,String);;Argument[0];ReturnValue;value;df-generated
public String cond(String x, String other) {
if (x == other) {
return x.substring(0, 100);
}
return x;
}
}