tarao / record4s

Extensible records for Scala
https://tarao.orezdnu.org/record4s/
Apache License 2.0
64 stars 4 forks source link

Allow unnamed construction if all arguments are identifiers #61

Closed tarao closed 10 months ago

tarao commented 10 months ago
val name = "tarao"
val age = 3
val r = %(name, age)
// val r: com.github.tarao.record4s.%{val name: String; val age: Int} = %(name = tarao, age = 3)

Use + or ++ to mix with named construction.

val name = "tarao"
val r = %(name) + (age = 3)
// val r: com.github.tarao.record4s.%{val name: String; val age: Int} = %(name = tarao, age = 3)
codecov[bot] commented 10 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (91711e6) 91.16% compared to head (f7e2d7b) 91.26%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #61 +/- ## ========================================== + Coverage 91.16% 91.26% +0.10% ========================================== Files 13 13 Lines 498 504 +6 Branches 8 10 +2 ========================================== + Hits 454 460 +6 Misses 44 44 ``` | [Flag](https://app.codecov.io/gh/tarao/record4s/pull/61/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=INA+Lintaro) | Coverage Δ | | |---|---|---| | [3](https://app.codecov.io/gh/tarao/record4s/pull/61/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=INA+Lintaro) | `91.26% <100.00%> (+0.10%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=INA+Lintaro#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.