fixed dummy keywods to mnemonics only
This commit is contained in:
parent
8d112cb558
commit
2d10500316
|
|
@ -2,7 +2,7 @@
|
||||||
"name": "x86-assembly-syntax",
|
"name": "x86-assembly-syntax",
|
||||||
"displayName": "Universal Assembly Syntax Highlighting",
|
"displayName": "Universal Assembly Syntax Highlighting",
|
||||||
"description": "Syntax highlighting extension for x86, x64 and ARM assembly both for Intel and AT&T syntax",
|
"description": "Syntax highlighting extension for x86, x64 and ARM assembly both for Intel and AT&T syntax",
|
||||||
"version": "1.0.7",
|
"version": "1.0.8",
|
||||||
"engines": {
|
"engines": {
|
||||||
"vscode": "^1.60.0"
|
"vscode": "^1.60.0"
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -18,11 +18,12 @@ function activate(context) {
|
||||||
return new vscode.Hover(instructionInfo);
|
return new vscode.Hover(instructionInfo);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
return new vscode.Hover(`Unrecognized mnemonic: ${word}`);
|
// Only show hover for recognized mnemonics
|
||||||
|
return undefined; // Return undefined if not a valid mnemonic
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return undefined;
|
return undefined; // Return undefined if no word found
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -82,7 +83,7 @@ async function fetchInstructionInfo(instruction) {
|
||||||
|
|
||||||
async function findDefinition(word) {
|
async function findDefinition(word) {
|
||||||
// Get all x86 assembly files in the workspace
|
// Get all x86 assembly files in the workspace
|
||||||
const files = await vscode.workspace.findFiles('**/*.s', '**/node_modules/**');
|
const files = await vscode.workspace.findFiles('**/*.s', '**/*.asm', '**/*.nasm', '**/*.S', "**/*.asmx", "**/*.inc");
|
||||||
|
|
||||||
for (const file of files) {
|
for (const file of files) {
|
||||||
const document = await vscode.workspace.openTextDocument(file);
|
const document = await vscode.workspace.openTextDocument(file);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue