Skip to content

Commit

Permalink
isValidScopeToInspect types
Browse files Browse the repository at this point in the history
  • Loading branch information
aminya committed Apr 13, 2020
1 parent 92c426a commit b98e124
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib_src/misc/scopes.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/** @babel */

import {Point, Range, RangeCompatible, TextEditor} from "atom"
import { Point, Range, RangeCompatible, TextEditor, PointCompatible } from "atom"

const juliaScopes = ["source.julia", "source.embedded.julia"]
const openers = [
Expand Down Expand Up @@ -109,7 +109,7 @@ export function isCommentScope(scopes: readonly string[]) {
* Supposed to be used within Atom-IDE integrations, whose `grammarScopes` setting doesn't support
* embedded scopes by default.
*/
export function isValidScopeToInspect(editor, bufferPosition) {
export function isValidScopeToInspect(editor: TextEditor, bufferPosition: PointCompatible) {
const scopes = editor.scopeDescriptorForBufferPosition(bufferPosition).getScopesArray()
return scopes.some(scope => {
return juliaScopes.includes(scope)
Expand Down

0 comments on commit b98e124

Please sign in to comment.