Switch converter test to new directive scheme

This commit is contained in:
Mikhail Bogdanov
2020-03-17 18:44:00 +01:00
parent d793fea8d2
commit 3f87899014
60 changed files with 88 additions and 89 deletions
@@ -1,5 +1,5 @@
//method
// !specifyLocalVariableTypeByDefault: true
// !SPECIFY_LOCAL_VARIABLE_TYPE_BY_DEFAULT: true
void foo(boolean b) {
String s = "abc";
if (b) {
@@ -1,4 +1,4 @@
// !specifyLocalVariableTypeByDefault: true
// !SPECIFY_LOCAL_VARIABLE_TYPE_BY_DEFAULT: true
fun foo(b: Boolean) {
var s: String? = "abc"
if (b) {
@@ -1,5 +1,5 @@
//method
// !specifyLocalVariableTypeByDefault: true
// !SPECIFY_LOCAL_VARIABLE_TYPE_BY_DEFAULT: true
void foo() {
String s = bar();
if (s != null) {
@@ -1,4 +1,4 @@
// !specifyLocalVariableTypeByDefault: true
// !SPECIFY_LOCAL_VARIABLE_TYPE_BY_DEFAULT: true
fun foo() {
val s: String? = bar()
if (s != null) {
@@ -1,5 +1,5 @@
//method
// !specifyLocalVariableTypeByDefault: true
// !SPECIFY_LOCAL_VARIABLE_TYPE_BY_DEFAULT: true
void foo(boolean b) {
String s = null;
if (b) {
@@ -1,4 +1,4 @@
// !specifyLocalVariableTypeByDefault: true
// !SPECIFY_LOCAL_VARIABLE_TYPE_BY_DEFAULT: true
fun foo(b: Boolean) {
var s: String? = null
if (b) {
@@ -1,5 +1,5 @@
//method
// !specifyLocalVariableTypeByDefault: true
// !SPECIFY_LOCAL_VARIABLE_TYPE_BY_DEFAULT: true
void foo(boolean b) {
String s = (b ? "abc" : null);
}
@@ -1,4 +1,4 @@
// !specifyLocalVariableTypeByDefault: true
// !SPECIFY_LOCAL_VARIABLE_TYPE_BY_DEFAULT: true
fun foo(b: Boolean) {
val s: String? = if (b) "abc" else null
}