Type has multiple definitions when reused in union
See original GitHub issueexport type s = string
export type n = number
export type sn = s | n
Type "s" has multiple definitions.
I don’t think this schema has name conflict. sn
should only create a new name sn
and get compiled into something like this
...
"sn": {"anyOf": [{"$ref": "#definitions/s"}, {"$ref": "#definitions/n"}]}
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:13 (5 by maintainers)
Top Results From Across the Web
symbol 'Flags' has multiple definitions using union/struct
Error - symbol 'Flags' has multiple definitions. I placed a union/struct in my main.h desiring to access the Flags.bit.xx from various c ...
Read more >Mypy errors with variable reuse with different types · Issue #1174
Sounds like a common theme is that if variables are defined and redefined at the same indentation level ("in the same block") and...
Read more >multiple definitions error in c++ and solution to solve this issue
I have declared a class in the header file and I have defined the class in each of the .cpp files but the...
Read more >Performance Tips · The Julia Language
It leads to more reusable code and clarifies what the inputs and outputs are. ... If items[i+1] has a different type than item[i]...
Read more >C++ Core Guidelines - GitHub Pages
The C++ Core Guidelines are a set of tried-and-true guidelines, rules, and best practices about coding in C++.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Think it’s the same issue as this: https://github.com/vega/ts-json-schema-generator/issues/161
The original test case now works.