Repository navigation
Conversation
…ion-json to v1.7.0
…ion-json to v1.7.1
| mutableSetOf<Int>() | ||
| .apply { | ||
| // PUA | ||
| addAll(0xE000..0xF8FF) |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
| // PUA | ||
| addAll(0xE000..0xF8FF) | ||
| // PUA_EXT_A | ||
| addAll(0xF0000..0xFFFFF) |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
| // PUA | ||
| addAll(0xE000..0xF8FF) | ||
| // PUA_EXT_A | ||
| addAll(0xF0000..0xFFFFF) |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
| // PUA_EXT_A | ||
| addAll(0xF0000..0xFFFFF) | ||
| // PUA_EXT_B | ||
| addAll(0x100000..0x10FFFF) |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
| // PUA_EXT_A | ||
| addAll(0xF0000..0xFFFFF) | ||
| // PUA_EXT_B | ||
| addAll(0x100000..0x10FFFF) |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
| fun Double.ieee754HexLE() = ieee754Hex().chunked(2).reversed().joinToString("") | ||
|
|
||
| fun Double.ieee754Readable() = | ||
| with(ieee754().replace(" ", "")) { "${first()} ${substring(1..11)} ${substring(12)}" } |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
| .filter { it.first.code > 32 } | ||
| .sortedByDescending { it.second } | ||
| .joinToString(System.lineSeparator()) { "${it.first}: ${it.second}" } | ||
| .filter { it.first.unicodeCharToInt() > 32 } |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
| val unicode = it.first.unicodeCharToInt() | ||
| val unicodeStr = | ||
| if (PUA_RANGE.contains(unicode)) { | ||
| "\tU+${unicode.toString(16).uppercase()}" |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
|
|
||
| fun String.winEscape() = replace("^\\^\"", "\"").replace(winEscapeReg, "$1") | ||
|
|
||
| fun String.parseCurl(): Request { |
Check warning
Code scanning / detekt
Prefer splitting up complex methods into smaller, easier to understand methods. Warning
| s.startsWith("curl ") -> | ||
| with(s.removeFirstAndEndQuotes(startIndex)) { | ||
| if (startsWith("-X")) { | ||
| val str = substring(3) |
Check warning
Code scanning / detekt
Report magic numbers. Magic number is a numeric literal that is not defined as a constant and hence it's unclear what the purpose of this number is. It's better to declare such numbers as constants and give them a proper name. By default, -1, 0, 1, and 2 are not considered to be magic numbers. Warning
No description provided.