-
Notifications
You must be signed in to change notification settings - Fork 116
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #233 from Aleph-Alpha/bug/flatten-generic-enum
Bug: Flattening generic type also flattens all generic parameters
- Loading branch information
Showing
32 changed files
with
495 additions
and
486 deletions.
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 |
---|---|---|
@@ -1,10 +1,14 @@ | ||
use ts_rs::TS; | ||
use dependency1::LibraryType; | ||
use dependency1::*; | ||
|
||
#[derive(TS)] | ||
#[ts(export)] | ||
struct ConsumerType { | ||
pub ty: LibraryType | ||
pub ty1: LibraryType1, | ||
pub ty2_1: LibraryType2<i32>, | ||
pub ty2_2: LibraryType2<&'static Self>, | ||
pub ty2_3: LibraryType2<LibraryType2<Box<ConsumerType>>>, | ||
pub ty2_4: LibraryType2<LibraryType2<LibraryType1>>, | ||
} | ||
|
||
fn main() {} |
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 |
---|---|---|
@@ -1,6 +1,11 @@ | ||
use ts_rs::TS; | ||
|
||
#[derive(TS)] | ||
pub struct LibraryType { | ||
pub struct LibraryType1 { | ||
pub a: i32 | ||
} | ||
} | ||
|
||
#[derive(TS)] | ||
pub struct LibraryType2<T> { | ||
pub t: T | ||
} |
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
Oops, something went wrong.