File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed
benchmark/src/jmh/kotlin/kotlinx/benchmarks Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -23,5 +23,5 @@ open class TwitterBenchmark {
23
23
24
24
// Order of magnitude: 4-7 op/ms
25
25
@Benchmark
26
- fun parseTwitter () = Json .decodeFromString(MacroTwitterFeed .serializer(), input)
26
+ fun parseTwitter () = Json .decodeFromString(Twitter .serializer(), input)
27
27
}
Original file line number Diff line number Diff line change @@ -19,9 +19,9 @@ data class TwitterStatus(
19
19
val source : String ,
20
20
val truncated : Boolean ,
21
21
val in_reply_to_status_id : Long? ,
22
- val in_reply_to_status_id_str : Long ? ,
22
+ val in_reply_to_status_id_str : String ? ,
23
23
val in_reply_to_user_id : Long? ,
24
- val in_reply_to_user_id_str : Long ? ,
24
+ val in_reply_to_user_id_str : String ? ,
25
25
val in_reply_to_screen_name : String? ,
26
26
val user : TwitterUser ,
27
27
val geo : String? ,
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ import kotlinx.serialization.*
4
4
import kotlinx.serialization.json.*
5
5
6
6
fun main () {
7
- val s = MacroTwitterFeed ::class .java.getResource(" /twitter .json" ).readBytes().decodeToString()
7
+ val s = MacroTwitterFeed ::class .java.getResource(" /twitter_macro .json" ).readBytes().decodeToString()
8
8
println (Json .decodeFromString<MacroTwitterFeed >(s))
9
9
}
10
10
You can’t perform that action at this time.
0 commit comments