Skip to content

Conversation

@DanielRosenwasser
Copy link
Member

Addresses #5510.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i do not think you need "compilerOptions.noLib" check. having a file with the NoDefaultLib comment is equivalent to --noLib.

I propose we simplify this whole thing, and remove sourceFile.isDefaultLib, as it is not clear why we have it. we should have one concept, is this file a default lib, and that is determined by the flag, the lib.d.ts we add has the flag anyways, so things should just work without the additional flag we are passing through.

we can change our test, to not include the /// comment. and just pass --noLib instead, this way it still type checks, but does not trigger this condition.

@mhegazy
Copy link
Contributor

mhegazy commented Nov 7, 2015

@DanielRosenwasser can you update please. i think this is blocking @alexeagle

@alexeagle
Copy link
Contributor

No, not blocking, we have a workaround (return the ES5 stdlib from CompilerHost#getDefaultLibFilename)

@DanielRosenwasser
Copy link
Member Author

@mhegazy check out my recent changes.

@mhegazy
Copy link
Contributor

mhegazy commented Nov 9, 2015

👍

DanielRosenwasser added a commit that referenced this pull request Nov 9, 2015
…ultLib

Skip files with no-default-lib when '--skipDefaultLibCheck' and '--noLib' are used
@DanielRosenwasser DanielRosenwasser merged commit 92d37c3 into master Nov 9, 2015
@DanielRosenwasser DanielRosenwasser deleted the skipDefaultLibCheckWithNoDefaultLib branch November 9, 2015 23:43
@DanielRosenwasser DanielRosenwasser changed the title Skip files with no-default-lib when '--skipDefaultLibCheck' and '--noLib' are used Skip files with no-default-lib when '--skipDefaultLibCheck' are used Nov 10, 2015
@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants