-
Notifications
You must be signed in to change notification settings - Fork 415
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Don't remove 'val' from case classes' parameters with names (#2634)
* Fix codegen for case classes with field named value * Add test
- Loading branch information
Showing
4 changed files
with
36 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package test.component | ||
|
||
import zio.schema._ | ||
|
||
case class Values( | ||
value1: Int, | ||
value2: String, | ||
) | ||
object Values { | ||
|
||
implicit val codec: Schema[Values] = DeriveSchema.gen[Values] | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package zio.http.gen.model | ||
|
||
import zio.schema.{DeriveSchema, Schema} | ||
|
||
case class Values(value1: Int, value2: String) | ||
object Values { | ||
implicit val codec: Schema[Values] = DeriveSchema.gen[Values] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters