# Bug Report <!-- Please fill in each section completely. Thank you! --> ### 🔎 Search Terms infer conditional type intersection <!-- What search terms did you use when trying to find an existing bug report? List them here so people in the future can find this one more easily. --> ### 🕗 Version & Regression Information 4.3.0-dev.20210224 <!-- When did you start seeing this bug occur? "Bugs" that have existed in TS for a long time are very likely to be FAQs; refer to https://github.com/Microsoft/TypeScript/wiki/FAQ#common-bugs-that-arent-bugs If possible, please try testing the nightly version of TS to see if it's already been fixed. For npm: `typescript@next` This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly Note: The TypeScript Playground can be used to try older versions of TypeScript. Please keep and fill in the line that best applies: - This is the behavior in every version I tried, and I reviewed the FAQ for entries about `infer` ### ⏯ Playground Link <!-- A link to a TypeScript Playground "Share" link which shows this behavior The TypeScript Workbench can be used for more complex setups, try https://www.typescriptlang.org/dev/bug-workbench/ As a last resort, you can link to a repo, but these will be slower for us to investigate. --> [Playground link with relevant code](https://www.typescriptlang.org/play?ts=4.3.0-dev.20210224#code/C4TwDgpgBAKg9gOQK4FsBGEBOAeGUIAewEAdgCYDOUFwmAliQOYB8UAvLPkaZVAAYASAN4lUGTFABkUBgDMsUAEoBfPgH4lALigkIANywAoQwGM4JGlFlw42+MnRZsAcgCMz1h1dQA9D5jg0M6ijpjOMlQkcMBQAIYUFHSMJLFoADbQwHBQoJBQwfpYzgB0QA) ### 💻 Code <!-- Please post the relevant code sample here as well--> ```ts type ToNumber<T extends string> = T extends `${number & infer R}`? R: never const foo: ToNumber<'1'> = 1 //Type 'number' is not assignable to type 'never'. ``` ### 🙁 Actual behavior `T` doesn't extend `${number & infer R}`, even though it does extend `${number & any}` <!-- What happened, and why it was wrong --> ### 🙂 Expected behavior `T` should extend `${number & infer R}` and (if my understanding of `infer` is correct) `R` should be `1` <!-- What you expected to happen instead, and why -->