Skip to content

Commit 84abc3a

Browse files
authored
Handle .txx/tpp headers. (#13811)
* Handle .txx headers. * Add tpp too.
1 parent b65fc9f commit 84abc3a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Extension/src/LanguageServer/client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2655,7 +2655,7 @@ export class DefaultClient implements Client {
26552655
});
26562656

26572657
// TODO: Handle new associations without a reload.
2658-
this.associations_for_did_change = new Set<string>(["cu", "cuh", "c", "i", "cpp", "cc", "cxx", "c++", "cp", "hpp", "hh", "hxx", "h++", "hp", "h", "ii", "ino", "inl", "ipp", "tcc", "idl"]);
2658+
this.associations_for_did_change = new Set<string>(["cu", "cuh", "c", "i", "cpp", "cc", "cxx", "c++", "cp", "hpp", "hh", "hxx", "h++", "hp", "h", "ii", "ino", "inl", "ipp", "tcc", "txx", "tpp", "idl"]);
26592659
const assocs: any = new OtherSettings().filesAssociations;
26602660
for (const assoc in assocs) {
26612661
const dotIndex: number = assoc.lastIndexOf('.');

Extension/src/common.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ export function getVcpkgRoot(): string {
165165
export function isHeaderFile(uri: vscode.Uri): boolean {
166166
const fileExt: string = path.extname(uri.fsPath);
167167
const fileExtLower: string = fileExt.toLowerCase();
168-
return !fileExt || [".cuh", ".hpp", ".hh", ".hxx", ".h++", ".hp", ".h", ".inl", ".ipp", ".tcc", ".tlh", ".tli", ""].some(ext => fileExtLower === ext);
168+
return !fileExt || [".cuh", ".hpp", ".hh", ".hxx", ".h++", ".hp", ".h", ".inl", ".ipp", ".tcc", ".txx", ".tpp", ".tlh", ".tli", ""].some(ext => fileExtLower === ext);
169169
}
170170

171171
export function isCppFile(uri: vscode.Uri): boolean {

0 commit comments

Comments
 (0)