Skip to content

Commit 6cba535

Browse files
author
Yui T
committed
Fix spelling
1 parent ed224ca commit 6cba535

File tree

4 files changed

+33
-33
lines changed

4 files changed

+33
-33
lines changed

src/compiler/types.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -569,7 +569,7 @@ module ts {
569569
export interface SourceMapData {
570570
/** Where the sourcemap file is written */
571571
sourceMapFilePath: string;
572-
/** source map url written in the js file */
572+
/** source map URL written in the js file */
573573
jsSourceMappingURL: string;
574574
/** Source map's file field - js file name*/
575575
sourceMapFile: string;
@@ -594,7 +594,7 @@ module ts {
594594
AllOutputGenerationSkipped = 1, // No .js generated because of syntax errors, or compiler options errors, nothing generated
595595
JSGeneratedWithSemanticErrors = 2, // .js and .map generated with semantic errors
596596
DeclarationGenerationSkipped = 3, // .d.ts generation skipped because of semantic errors or declaration emitter specific errors; Output .js with semantic errors
597-
EmitErrorsEncountered = 4 // Emitter errors occured during emitting process
597+
EmitErrorsEncountered = 4 // Emitter errors occurred during emitting process
598598
}
599599

600600
export interface EmitResult {

src/harness/harness.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -826,7 +826,7 @@ module Harness {
826826
totalErrorsReported++;
827827
}
828828

829-
// Report glovbal errors:
829+
// Report global errors:
830830
var globalErrors = diagnostics.filter(err => !err.filename);
831831
globalErrors.forEach(err => outputErrorText(err));
832832

@@ -1016,7 +1016,7 @@ module Harness {
10161016
}
10171017

10181018
export module TestCaseParser {
1019-
/** all the necesarry information to set the right compiler settings */
1019+
/** all the necessary information to set the right compiler settings */
10201020
export interface CompilerSetting {
10211021
flag: string;
10221022
value: string;

src/services/services.ts

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ module ts {
362362
public update(scriptSnapshot: TypeScript.IScriptSnapshot, version: string, isOpen: boolean, textChangeRange: TypeScript.TextChangeRange): SourceFile {
363363
// See if we are currently holding onto a syntax tree. We may not be because we're
364364
// either a closed file, or we've just been lazy and haven't had to create the syntax
365-
// tree yet. Access the field instead of the method so we don't accidently realize
365+
// tree yet. Access the field instead of the method so we don't accidentally realize
366366
// the old syntax tree.
367367
var oldSyntaxTree = this.syntaxTree;
368368

@@ -1378,7 +1378,7 @@ module ts {
13781378
var program: Program;
13791379
// this checker is used to answer all LS questions except errors
13801380
var typeInfoResolver: TypeChecker;
1381-
// the sole purpose of this checkes is to reutrn semantic diagnostics
1381+
// the sole purpose of this checker is to return semantic diagnostics
13821382
// creation is deferred - use getFullTypeCheckChecker to get instance
13831383
var fullTypeCheckChecker_doNotAccessDirectly: TypeChecker;
13841384
var useCaseSensitivefilenames = false;
@@ -1524,7 +1524,7 @@ module ts {
15241524
sourceFile = documentRegistry.acquireDocument(filename, compilationSettings, scriptSnapshot, version, isOpen);
15251525
}
15261526

1527-
// Remeber the new sourceFile
1527+
// Remember the new sourceFile
15281528
sourceFilesByName[filename] = sourceFile;
15291529
}
15301530

@@ -1579,7 +1579,7 @@ module ts {
15791579
var firstChar = displayName.charCodeAt(0);
15801580
if (firstChar === TypeScript.CharacterCodes.singleQuote || firstChar === TypeScript.CharacterCodes.doubleQuote) {
15811581
// If the user entered name for the symbol was quoted, removing the quotes is not enough, as the name could be an
1582-
// invalid identifer name. We need to check if whatever was inside the quotes is actually a valid identifier name.
1582+
// invalid identifier name. We need to check if whatever was inside the quotes is actually a valid identifier name.
15831583
displayName = TypeScript.stripStartAndEndQuotes(displayName);
15841584
}
15851585

@@ -1621,9 +1621,9 @@ module ts {
16211621
}
16221622

16231623
function isCompletionListBlocker(sourceUnit: TypeScript.SourceUnitSyntax, position: number): boolean {
1624-
// We shouldn't be getting a possition that is outside the file because
1624+
// We shouldn't be getting a position that is outside the file because
16251625
// isEntirelyInsideComment can't handle when the position is out of bounds,
1626-
// callers should be fixed, however we should be resiliant to bad inputs
1626+
// callers should be fixed, however we should be resilient to bad inputs
16271627
// so we return true (this position is a blocker for getting completions)
16281628
if (position < 0 || position > TypeScript.fullWidth(sourceUnit)) {
16291629
return true;
@@ -1713,7 +1713,7 @@ module ts {
17131713
var positionedToken = TypeScript.Syntax.findCompleteTokenOnLeft(sourceUnit, position, /*includeSkippedTokens*/true);
17141714

17151715
if (positionedToken && position === TypeScript.end(positionedToken) && positionedToken.kind() == TypeScript.SyntaxKind.EndOfFileToken) {
1716-
// EndOfFile token is not intresting, get the one before it
1716+
// EndOfFile token is not interesting, get the one before it
17171717
positionedToken = TypeScript. previousToken(positionedToken, /*includeSkippedTokens*/true);
17181718
}
17191719

@@ -1848,14 +1848,14 @@ module ts {
18481848
// // get existing members
18491849
// var existingMembers = compiler.getVisibleMemberSymbolsFromAST(node, document);
18501850

1851-
// // Add filtterd items to the completion list
1851+
// // Add filtered items to the completion list
18521852
// getCompletionEntriesFromSymbols({
18531853
// symbols: filterContextualMembersList(contextualMembers.symbols, existingMembers, filename, position),
18541854
// enclosingScopeSymbol: contextualMembers.enclosingScopeSymbol
18551855
// }, entries);
18561856
//}
18571857
}
1858-
// Get scope memebers
1858+
// Get scope members
18591859
else {
18601860
isMemberCompletion = false;
18611861
/// TODO filter meaning based on the current context
@@ -2333,7 +2333,7 @@ module ts {
23332333

23342334
// Could not find a symbol e.g. unknown identifier
23352335
if (!symbol) {
2336-
// Even if we did not find a symbol, we have an identifer, so there is at least
2336+
// Even if we did not find a symbol, we have an identifier, so there is at least
23372337
// one reference that we know of. return than instead of undefined.
23382338
return [getReferenceEntry(node)];
23392339
}
@@ -2599,15 +2599,15 @@ module ts {
25992599
var propertySymbol = typeReferenceSymbol.members[propertyName];
26002600
if (propertySymbol) result.push(typeReferenceSymbol.members[propertyName]);
26012601

2602-
// Visit the typeReference as well to see if it directelly or indirectelly use that property
2602+
// Visit the typeReference as well to see if it directly or indirectly use that property
26032603
getPropertySymbolsFromBaseTypes(typeReferenceSymbol, propertyName, result);
26042604
}
26052605
}
26062606
}
26072607
}
26082608

26092609
function isRelatableToSearchSet(searchSymbols: Symbol[], referenceSymbol: Symbol, referenceLocation: Node): boolean {
2610-
// Unwrap symbols to get to the root (e.g. triansient symbols as a result of widenning)
2610+
// Unwrap symbols to get to the root (e.g. transient symbols as a result of widening)
26112611
var referenceSymbolTarget = typeInfoResolver.getRootSymbol(referenceSymbol);
26122612

26132613
// if it is in the list, then we are done
@@ -2625,7 +2625,7 @@ module ts {
26252625
}
26262626
}
26272627

2628-
// Finally, try all properties with the same name in any type the containing type extened or implemented, and
2628+
// Finally, try all properties with the same name in any type the containing type extended or implemented, and
26292629
// see if any is in the list
26302630
if (referenceSymbol.parent && referenceSymbol.parent.flags & (SymbolFlags.Class | SymbolFlags.Interface)) {
26312631
var result: Symbol[] = [];
@@ -2781,7 +2781,7 @@ module ts {
27812781
// intersects with the class in the value space.
27822782
// To achieve that we will keep iterating until the result stabilizes.
27832783

2784-
// Remeber the last meaning
2784+
// Remember the last meaning
27852785
var lastIterationMeaning = meaning;
27862786

27872787
for (var i = 0, n = declarations.length; i < n; i++) {
@@ -2796,7 +2796,7 @@ module ts {
27962796
return meaning;
27972797
}
27982798

2799-
/// A node is considedered a writeAccess iff it is a name of a declaration or a target of an assignment
2799+
/// A node is considered a writeAccess iff it is a name of a declaration or a target of an assignment
28002800
function isWriteAccess(node: Node): boolean {
28012801
if (node.kind === SyntaxKind.Identifier && isDeclarationOrFunctionExpressionOrCatchVariableName(node)) {
28022802
return true;
@@ -2873,7 +2873,7 @@ module ts {
28732873
var emitFilesResult = getFullTypeCheckChecker().emitFiles();
28742874
emitOutput.emitOutputStatus = emitFilesResult.emitResultStatus;
28752875

2876-
// Reset writer back to underfined to make sure that we produce an error message if CompilerHost.writeFile method is called when we are not in getEmitOutput
2876+
// Reset writer back to undefined to make sure that we produce an error message if CompilerHost.writeFile method is called when we are not in getEmitOutput
28772877
this.writer = undefined;
28782878
return emitOutput;
28792879
}
@@ -3154,7 +3154,7 @@ module ts {
31543154
continue;
31553155
}
31563156

3157-
// Looks to be within the trivia. See if we can find hte comment containing it.
3157+
// Looks to be within the trivia. See if we can find the comment containing it.
31583158
var triviaList = matchPosition < TypeScript.start(token) ? token.leadingTrivia(syntaxTree.text) : token.trailingTrivia(syntaxTree.text);
31593159
var trivia = findContainingComment(triviaList, matchPosition);
31603160
if (trivia === null) {
@@ -3362,7 +3362,7 @@ module ts {
33623362
addResult(start - lastTokenOrCommentEnd, TokenClass.Whitespace);
33633363
}
33643364

3365-
// Remeber the end of the last token
3365+
// Remember the end of the last token
33663366
lastTokenOrCommentEnd = end;
33673367
}
33683368

src/services/shims.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -147,13 +147,13 @@ module ts {
147147
getDefaultCompilationSettings(): string;
148148
}
149149

150-
/// TODO: delete this, it is only needed untill the VS interface is updated
150+
/// TODO: delete this, it is only needed until the VS interface is updated
151151
enum LanguageVersion {
152152
EcmaScript3 = 0,
153153
EcmaScript5 = 1,
154154
}
155155

156-
enum ModuleGenTarget {
156+
export enum ModuleGenTarget {
157157
Unspecified = 0,
158158
Synchronous = 1,
159159
Asynchronous = 2,
@@ -188,9 +188,9 @@ module ts {
188188
if (typeof languageVersion === "undefined") return undefined;
189189

190190
switch (languageVersion) {
191-
case LanguageVersion.EcmaScript3: return ScriptTarget.ES3;
191+
case LanguageVersion.EcmaScript3: return ScriptTarget.ES3
192192
case LanguageVersion.EcmaScript5: return ScriptTarget.ES5;
193-
default: throw Error("unsuported LanguageVersion value: " + languageVersion);
193+
default: throw Error("unsupported LanguageVersion value: " + languageVersion);
194194
}
195195
}
196196

@@ -201,7 +201,7 @@ module ts {
201201
case ModuleGenTarget.Asynchronous: return ModuleKind.AMD;
202202
case ModuleGenTarget.Synchronous: return ModuleKind.CommonJS;
203203
case ModuleGenTarget.Unspecified: return ModuleKind.None;
204-
default: throw Error("unsuported ModuleGenTarget value: " + moduleGenTarget);
204+
default: throw Error("unsupported ModuleGenTarget value: " + moduleGenTarget);
205205
}
206206
}
207207

@@ -211,7 +211,7 @@ module ts {
211211
switch (scriptTarget) {
212212
case ScriptTarget.ES3: return LanguageVersion.EcmaScript3;
213213
case ScriptTarget.ES5: return LanguageVersion.EcmaScript5;
214-
default: throw Error("unsuported ScriptTarget value: " + scriptTarget);
214+
default: throw Error("unsupported ScriptTarget value: " + scriptTarget);
215215
}
216216
}
217217

@@ -222,7 +222,7 @@ module ts {
222222
case ModuleKind.AMD: return ModuleGenTarget.Asynchronous;
223223
case ModuleKind.CommonJS: return ModuleGenTarget.Synchronous;
224224
case ModuleKind.None: return ModuleGenTarget.Unspecified;
225-
default: throw Error("unsuported ModuleKind value: " + moduleKind);
225+
default: throw Error("unsupported ModuleKind value: " + moduleKind);
226226
}
227227
}
228228

@@ -326,8 +326,8 @@ module ts {
326326

327327
/// TODO: this should be pushed into VS.
328328
/// We can not ask the LS instance to resolve, as this will lead to asking the host about files it does not know about,
329-
/// something it is not desinged to handle. for now make sure we never get a "noresolve == false".
330-
/// This value should not matter, as the host runs resolution logic independentlly
329+
/// something it is not designed to handle. for now make sure we never get a "noresolve == false".
330+
/// This value should not matter, as the host runs resolution logic independently
331331
options.noResolve = true;
332332

333333
return options;
@@ -432,7 +432,7 @@ module ts {
432432
}
433433

434434
// DISPOSE
435-
// Ensure (almost) determinstic release of internal Javascript resources when
435+
// Ensure (almost) deterministic release of internal Javascript resources when
436436
// some external native objects holds onto us (e.g. Com/Interop).
437437
public dispose(dummy: any): void {
438438
this.logger.log("dispose()");
@@ -859,7 +859,7 @@ module ts {
859859
}
860860

861861

862-
/// TODO: this is used by VS, clean this up on both sides of the interfrace
862+
/// TODO: this is used by VS, clean this up on both sides of the interface
863863
module TypeScript.Services {
864864
export var TypeScriptServicesFactory = ts.TypeScriptServicesFactory;
865865
}

0 commit comments

Comments
 (0)