C++: Autoformat five files

These files have come out of autoformat since the big commit that
autoformatted everything.
This commit is contained in:
Jonas Jensen
2019-09-18 11:55:19 +02:00
parent e7d8fa4251
commit 571c96bb2f
5 changed files with 36 additions and 25 deletions

View File

@@ -315,7 +315,7 @@ class ParameterDeclarationEntry extends VariableDeclarationEntry {
* static int c;
* }
* ```
*
*
* Local variables can be static; use the `isStatic` member predicate to
* detect those.
*/
@@ -343,7 +343,7 @@ deprecated class StackVariable extends Variable {
* static int c;
* }
* ```
*
*
* Local variables can be static; use the `isStatic` member predicate to detect
* those.
*
@@ -512,9 +512,9 @@ class TemplateVariable extends Variable {
* void myTemplateFunction() {
* T b;
* }
*
*
* ...
*
*
* myTemplateFunction<int>();
* ```
*/

View File

@@ -174,9 +174,7 @@ class MicrosoftInt64Type extends IntegralType {
* `__builtin_va_copy` and `__builtin_va_arg` expressions.
*/
class BuiltInVarArgsList extends Type {
BuiltInVarArgsList() {
this.hasName("__builtin_va_list")
}
BuiltInVarArgsList() { this.hasName("__builtin_va_list") }
override string getCanonicalQLClass() { result = "BuiltInVarArgsList" }
}

View File

@@ -1,15 +1,28 @@
class LambdaCapture extends @lambdacapture {
string toString() { none() }
}
class LambdaCapture extends @lambdacapture { string toString() { none() } }
class Lambda extends @lambdaexpr { string toString() { none() } }
class Field extends @membervariable { string toString() { none() } }
class Location extends @location_default { string toString() { none() } }
class Type extends @usertype { string toString() { none() } }
class Lambda extends @lambdaexpr {
string toString() { none() }
}
class Field extends @membervariable {
string toString() { none() }
}
class Location extends @location_default {
string toString() { none() }
}
class Type extends @usertype {
string toString() { none() }
}
pragma[noopt]
predicate lambda_capture_new(LambdaCapture lc, Lambda l, int i, Field f,
boolean captured_by_reference, boolean is_implicit,
Location loc)
{
predicate lambda_capture_new(
LambdaCapture lc, Lambda l, int i, Field f, boolean captured_by_reference, boolean is_implicit,
Location loc
) {
exists(Type t |
lambda_capture(lc, l, i, captured_by_reference, is_implicit, loc) and
expr_types(l, t, _) and
@@ -19,8 +32,8 @@ predicate lambda_capture_new(LambdaCapture lc, Lambda l, int i, Field f,
)
}
from LambdaCapture lc, Lambda l, int i, Field f,
boolean captured_by_reference, boolean is_implicit,
Location loc
from
LambdaCapture lc, Lambda l, int i, Field f, boolean captured_by_reference, boolean is_implicit,
Location loc
where lambda_capture_new(lc, l, i, f, captured_by_reference, is_implicit, loc)
select lc, l, i, f, captured_by_reference, is_implicit, loc

View File

@@ -1,7 +1,7 @@
class Value extends @value { string toString() { none() } }
class Value extends @value {
string toString() { none() }
}
from Value v, string s
where values(v, s, _)
select v, s

View File

@@ -1,7 +1,7 @@
class Value extends @value { string toString() { none() } }
class Value extends @value {
string toString() { none() }
}
from Value v, string s
where values(v, _, s)
select v, s